Highlighted

How to render image without blue border using script?

Participant ,
Aug 22, 2020

Copy link to clipboard

Copied

Hello,

 

I'm wondering are there any wat that i can render/place an image without the blue borders?

img0.png

To change the color or i dont know if there is a way to make it disappear becuase when the designers work on the images and change the postions of the image via the anchore, become very hard!

I tried to use textftame and rectangulr and still having the borders.

This is my code:

		var rect = doc.pages[pageIdx].textFrames.add({
											geometricBounds: a
										});
										
										rect.place(xTest)
										rect.fit(FitOptions.PROPORTIONALLY)
										rect.fit(FitOptions.FRAME_TO_CONTENT)
										rect.select(SelectionOptions.ADD_TO)

I'm using JS,

THANKS ALL.

Adobe Community Professional
Correct answer by Charu Rajput | Adobe Community Professional

Hi,

You can find out all list of colors from following link. 

https://www.indesignjs.de/extendscriptAPI/indesign-latest/#UIColors.html

 

What you can do, you can create separate layer for placed items and assign color WHITE. In that case all placed images in the document will have WHITE, so white will not be visible. This is a workaround to your problem.

 

app.activeDocument.activeLayer.layerColor = UIColors.WHITE;

 Let us know if this helps you.

Topics

Activation billing and install, Bug, EPUB, Feature request, How to, Import and export, InCopy workflow, Performance, Print, Publish online, Scripting, SDK, Server developers, Sync and storage, Type

Views

124

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

How to render image without blue border using script?

Participant ,
Aug 22, 2020

Copy link to clipboard

Copied

Hello,

 

I'm wondering are there any wat that i can render/place an image without the blue borders?

img0.png

To change the color or i dont know if there is a way to make it disappear becuase when the designers work on the images and change the postions of the image via the anchore, become very hard!

I tried to use textftame and rectangulr and still having the borders.

This is my code:

		var rect = doc.pages[pageIdx].textFrames.add({
											geometricBounds: a
										});
										
										rect.place(xTest)
										rect.fit(FitOptions.PROPORTIONALLY)
										rect.fit(FitOptions.FRAME_TO_CONTENT)
										rect.select(SelectionOptions.ADD_TO)

I'm using JS,

THANKS ALL.

Adobe Community Professional
Correct answer by Charu Rajput | Adobe Community Professional

Hi,

You can find out all list of colors from following link. 

https://www.indesignjs.de/extendscriptAPI/indesign-latest/#UIColors.html

 

What you can do, you can create separate layer for placed items and assign color WHITE. In that case all placed images in the document will have WHITE, so white will not be visible. This is a workaround to your problem.

 

app.activeDocument.activeLayer.layerColor = UIColors.WHITE;

 Let us know if this helps you.

Topics

Activation billing and install, Bug, EPUB, Feature request, How to, Import and export, InCopy workflow, Performance, Print, Publish online, Scripting, SDK, Server developers, Sync and storage, Type

Views

125

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Aug 22, 2020 0
Adobe Community Professional ,
Aug 22, 2020

Copy link to clipboard

Copied

Hi,

As far as I know, it is not possible to hide this border around the image. And the color is depends on the layer color. If the layer color is pink then box color will also be pink.  See screnshot

Screenshot 2020-08-23 at 12.12.45 PM.png

If you know in which layer are you placeing the image, then you can change color of layer via script. For an example, below line will change color of active layer to RED

app.activeDocument.activeLayer.layerColor = UIColors.RED;

 

Best regards

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 22, 2020 1
Participant ,
Aug 23, 2020

Copy link to clipboard

Copied

I understand that. It's possiple to make it transparency?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 0
Adobe Community Professional ,
Aug 23, 2020

Copy link to clipboard

Copied

Hi,

You can find out all list of colors from following link. 

https://www.indesignjs.de/extendscriptAPI/indesign-latest/#UIColors.html

 

What you can do, you can create separate layer for placed items and assign color WHITE. In that case all placed images in the document will have WHITE, so white will not be visible. This is a workaround to your problem.

 

app.activeDocument.activeLayer.layerColor = UIColors.WHITE;

 Let us know if this helps you.

Best regards

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 0
Adobe Community Professional ,
Aug 23, 2020

Copy link to clipboard

Copied

I am not sure how this is affecting you? This color is just a visual que for the person working on the document. It is a non-printing thing, so the final pdf would not have this color shown. If it is still bothering, then you can switch these borders off by selecting View>Extras>Hide Frame Edges menu

-Manan

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 1
Participant ,
Aug 23, 2020

Copy link to clipboard

Copied

THANKS it wokrs! The designers botherd not me at all!  

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 0
Adobe Community Professional ,
Aug 23, 2020

Copy link to clipboard

Copied

Is there a reason that the designers can't just hide their frame using the hide frame edges option in the view menu;

Screen Shot 2020-08-23 at 23.30.30.png

or go to overprint preview or separation preview?

Perhaps I've misunderstood the question.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 3
Participant ,
Aug 23, 2020

Copy link to clipboard

Copied

Nope you didn't misundertstood it. I don't know why the designers are botherd or don't like it, maybe they want to work and see the reasult at the same time without exporting. THANKS it works!

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 23, 2020 0
rob day LATEST
Adobe Community Professional ,
Aug 24, 2020

Copy link to clipboard

Copied

You can toggle Hide Frame Edges on and off using the invoke method, most menu items have an invoke ID, so this should work to hide edges:

 

 

app.menuActions.itemByID(24331).invoke(); 

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 24, 2020 1
Adobe Community Professional ,
Aug 24, 2020

Copy link to clipboard

Copied

becuase when the designers work on the images and change the postions of the image via the anchore, become very hard

 

Could you clarify what you mean by anchor? Your script is placing the image in a text frame, which converts the frame into a graphic frame. To anchor an image in the text frame’s text, your code would need to be something like this, which anchors the image at the beginning of first line:

 

rect.parentStory.insertionPoints[0].place

 

When the image is selected with the black selection tool there is a link icon to the upper left, which simply indicates that the image is linked, and not embedded.

 

The anchor icon to the right indicates the image and its frame are anchored into a textflow and would move with the text—it is a solid square when the image is not anchored. Neither icon is used for manually moving the image:

 

Screen Shot.png

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Aug 24, 2020 1