Illustrator Scripting :: Selecting Text Frames On All Visible Layers

Mar 3, 2013

I want to select all text frames on all visible layers. The script below will select all text frames even in groups but when a layer with text on it is invisible the script will error.(target layer cannot be modified)
 
if (app.documents.length > 0 ) {
var doc = app.activeDocument;
var numTextFrames = 0;
for (  i = 0; i < doc.textFrames.length; i++ ) {
textArtRange = doc.textFrames[i];
textArtRange.selected = true;
}
}
 
So I made this script to select text frames on only the visible layers but it now misses text that is in a group.
 
var layerCount = activeDocument.layers.length;
var docSelected = activeDocument.selection;
for (i = 0; i < layerCount; i++)

[Code] .....

Why it does not selected textframes in a group when done this way and is there a way to get all textframes selected on all visible layers?

View 3 Replies


ADVERTISEMENT

Illustrator Scripting :: Select All Text / Layers Including Locked Or Not Visible Using VBScript?

Feb 1, 2013

I'm looking for the most elegant syntax to loop through a document and select all the text frames.

View 1 Replies View Related

Illustrator Scripting :: Evaluate Text Frames

Mar 23, 2013

I want to evaluate text frames for their x axis and if they are the same shift them slightly because of adobes irritating habit of combining the text frames when it makes a PDF. I have been able to evaluate, but not exactly like I want to but I know it can be done...
 
var mydoc = app.activeDocument;var mytext = mydoc.textFrames;var allX_Vaues = new Array();for (i =0; i < mytext.length; i++) {var mytextFrames = mydoc.textFrames[i];var theMatrix = mytextFrames.matrix;allX_Vaues.push(theMatrix.mValueTX)var firstEval = allX_Vaues//$.writeln(theMatrix.mValueA+"
"+theMatrix.mValueB+"
"+theMatrix.mV alueC+"
"+theMatrix.mValueD+"
"+theMatrix.mValueTX+"
"+theMatrix.mV alueTY);//alert(allX_Vaues);}//alert(allX_Vaues[1]);for (i =0; i < allX_Vaues.length; i++) {if (allX_Vaues[i] == allX_Vaues[i + 1] ) {alert(allX_Vaues[i] + " and " + allX_Vaues[i +1] + " are the same");}else{alert(allX_Vaues[i] + " and " + allX_Vaues[i +1] + " are different");} } 
[code]....

my problem is when I try to move text frames. It flies way of the page. I just want to move the text a slight amount and concatenate is the only way I have been successful. my question is: Is there a better way and why is my text flying so far of the page?

View 11 Replies View Related

Illustrator Scripting :: Text Frames To Be Converted As Flash Text

Oct 17, 2012

I am working on a project which needs..Text frames to be converted as flash text >property changed to dynamic text > writing instance name “_txt”.so how can i write scripting on above process.

View 5 Replies View Related

Illustrator Scripting :: Removing Empty Text Frames

Mar 29, 2013

Trying to remove any text frames with empty content but it doesn't seem to be removing correct textFrame layers?
 
var numberOfEmptyTextBoxes = 0;
var layersWithNoText = new Array();
if ( app.documents.length > 0 ) {
for ( i = 0; i < app.activeDocument.textFrames.length; i++ ) {

[URL] ....

View 3 Replies View Related

Illustrator Scripting :: Change Color Of Text Frames On Active Layer?

Mar 3, 2013

Okay my script to change text frame color changes the color of all text frames hidden or not.

I need it to only change visible text frames.
 
if ( app.documents.length > 0 ) {
newCMYKColor = new CMYKColor();
newCMYKColor.black = 0;
newCMYKColor.cyan = 0;
newCMYKColor.magenta = 0;
newCMYKColor.yellow = 0;
 
[Code]...
 
How to go about making it only change the color of text frames on the active layer? In the final script I will hide all other layers so if it could be done by a visible attribute more easily that would work just as well.

View 4 Replies View Related

Illustrator Scripting :: Clean Up Unpainted Objects And Empty Text Frames?

Feb 27, 2012

Does this script also cleans up unpainted objects and empty text frames? Personally, I don't think so because the check of the script in extendscript and illustrator results negative.

var idoc = app.activeDocument;var straypoints = []; for (i=0; i<idoc.pathItems.length; i++) {   
var ipath = idoc.pathItems[i];    if (ipath.pathPoints.length==1) 
straypoints.push(ipath);} for (j=0; j<idoc.textFrames.length; j++) {
var itext = idoc.textFrames[j];    if (itext.textRange.length==0)
straypoints.push(itext);} for (k=0; k<straypoints.length; k++) 
straypoints[k].remove();

I also want to automatically remove all objects who have a white fill (white background) and no stroke.
 
Problem is a created pdf-file of an html-file of a table that must be cleaned up. There are a lot of stray points, empty text frames, unpainted objects, white "cells" that are also be painted in the pdf.

View 1 Replies View Related

Illustrator Scripting :: Split Text Into Layers?

Jun 30, 2013

script that is able to do the same as this photoshop one [URL] ...., I would use that one in photoshop but its not working in CS6.
 
find a script that will seperate the text into layers ready for export to After Effects to be used in Kinetic Typography  pieces.

View 3 Replies View Related

Illustrator Scripting :: Renaming Layers To Be The Text Inside

Oct 9, 2013

I've got an Illustrator CS6 document that has 500+ layers with individual words on them (a word cloud).  I'm needing to animate this in AE.  When I "Release to Layers (Sequence)", all of the layers become Layer 1, Layer 2, etc.  Is there a script that will rename all of those layers to be the text inside them? 
 
i.e. Layer 1 has the word "Pencil" as a sub-layer, editable text.. I need to rename the Top-Layer Layer 1 to "Pencil".  I'm hoping there is a script that can do this so I don't have to manually rename all of the layers.I have found this script:
 
var idoc = app.activeDocument;
var ilayer = idoc.activeLayer;
for (i=0; i<ilayer.layers.length; i++) {
    var isublayer = ilayer.layers[i];
    isublayer.name = isublayer.pageItems[0].name;
}
 
But is doesn't seem to do what I need.

View 8 Replies View Related

Illustrator Scripting :: Is It Possible To Copy And Duplicate (only) Text To Multiple Layers

Dec 8, 2012

I have an Illustrator document with one layer (named Layer 1).In that layer are lines, rectangles and text.Is it possible (in script) to: make 3 additional layers named NL, EN and GEselect and cut all the text in Layer 1paste that text in the same place in the layers NL, EN and GE 

(Step 2: select all text items and Ctrl-X)
(Step 3: select proper layer and Paste in Place in that layer)
 
I know this can be done with an action (I did that allready) but the reason I want to script this is because I have to combine this with another script which takes care of colorizing stuff.

View 5 Replies View Related

GIMP :: Make Text Visible On All Of Frames Of GIF

Aug 11, 2013

There's this GIF that I'd like to use for a banner and when I open the file in GIMP, add a text and then check the animation in the playback window, I can only see the text once the GIF has ended but also, I can only see the text for like one second.

Is it possible to make the text visible on all of the frames of the GIF without having to duplicate the text 100s of times and merging them onto each frames?

View 14 Replies View Related

Photoshop :: Increase Font Size In Many Text Layers At A Time By Selecting In Layers Panel

May 9, 2013

I would like to increase the font size in many text layers at a time by selecting them in the layers panel. The font increases, but the text boxes don't expand to fit the increased size text. So I am having to make each box bigger manually. Is there a way to have the boxes expand to fit bigger text automatically through the layers panel?

View 2 Replies View Related

Illustrator Scripting :: Making Layer Visible By Its Name?

Mar 3, 2013

How to make a layer visible by using the name of the layer, with javascript?

View 2 Replies View Related

Illustrator Scripting :: How To Get / Determine Visible Bounds

Jun 30, 2013

how to get/determine the visible bounds (top+left coords and width+height or Rect structure) of a group having a clipping mask or several masks? When a script asks for Visible Bounds, Illustrator provides the coords/size of the group like it does not have any clipping mask. So, you see a circle of 10px diameter (and these are the actual visible bounds of this group), but Illustrator says that the visible bounds are 50 px wide and 70 px in height.

And what to do if the group contains multiple clipping masks of different shapes/sizes?

View 3 Replies View Related

Illustrator Scripting :: Selecting Open Paths In CS6

Jul 10, 2012

I have created this script for selecting open paths in illustrator cs6 as the graffix plugin is not working under CS6.
 
Just save the following text in /Applications/Adobe Illustrator CS6/Presets/en_US/Scripts/Select Open Paths.js
 
if (documents.length > 0 && activeDocument.pathItems.length > 0){
var allPaths = activeDocument.pathItems;
var allPathsCount = allPaths.length;
var openPathsAreLocked = false;  

[Code] ........

View 4 Replies View Related

Illustrator Scripting :: Get Actual Visible Width Of Groupitem?

Oct 5, 2012

To get the top, left and width of an groupitem without Clipping mask. Actually the group has Clipping mask. But i need only the width of the selection (without Clipping mask). I got these properties in scripting but including the clipping mask. The GUI itself shows different (i.e. Info -->: X:0 mm, Y:0 mm, W:full width [including clipping mask]. Transform palette -->: X:43.00, Y:22.0, W:64 [excluding clipping mask])
 
How to get the properties without clipping mask?

View 1 Replies View Related

Illustrator Scripting :: EPS JavaScript Saves More Than Visible Object

Oct 28, 2009

In prior versions of illustrator we used a script that basically saved the visible bounds of a masked object as an EPS file. With the upgrade to CS4 and Multiple Artboards this save function (EPSSaveOptions) no longer does the same visible bounds. I have read several post of similar issues, but what I am asking is:
 
In there a way to make the visible bounds of the eps file equal the artboard on the active artboard only? The artboard seems to be driving the crop box. When I manually save the file as EPS the visible bounds are correct. When I save from the script it is not? As with other posts I do not want to go backwards within compatibility...I would like to keep the file at the CS4 level. What command am I missing? We have tried making the crop box = visibleBounds to no avail.

View 5 Replies View Related

Illustrator Scripting :: Create Mirror Text And Stroke Text In AI Scripting

Mar 16, 2013

the Script of creating mirror text and stroke text in Adobe illustrator scripting.

View 4 Replies View Related

Illustrator Scripting :: Selecting Objects By Group Names?

Feb 17, 2012

How to select objects by their group names?
 
I'm working with imported graphics, and the objects appear in the AI layer hierarchy grouped and named according to their object types in the native program (see the attached image). The problem lies with the annotation objects: they are made of different parts for which different graphic styles are needed; however, they all come in one layer and are difficult to access for global operations. I need to do different things with the different object types (delete the POINT's, move the LINE's and LWPOLYLINE's to different layers, etc...). The option of selecting objects individually is ok for small data sets, but you can imagine this becomes untenable in a hurry.
 
Two possible solutions I've considered:

(1) change the output parameters in the source program such that the objects come into illustrator with different graphics allowing them to be accessed through the "Select same ..." tools; it would work, but is problematic for the source program

(2) print the annotation graphics with their desired graphic appearance to pdf rather than importing the source file directly in AI, then open in AI to render the remaining graphics; again, this works but introduces inefficiency in the process. Also, the print process tends to explode closed paths requiring more inefficient path tinkering in AI.
 
I would like to tell AI to select all objects named "POINT" or "LINE" etc... but have found nothing in the documentation or forums on whether this is possible.

View 1 Replies View Related

Illustrator Scripting :: Place / Import File To Visible Layer?

Jul 26, 2013

I have been working on a script to place a psd file onto only one visible layer (document has multiple hidden layers). This java code has worked so far:
 
var doc = app.activeDocument;
var onFile = File("C:/Users/Desktop/Desktop/ExportedArtboard-01.psd");
var mydoc = doc.placedItems.add();
mydoc.file = onFile;
mydoc.embed();
 
however this works with only the top layer visible (eye turned on in Ai). if top most layer isn't visible i get "target layer cannot be modified" error.

For instance say i have 1,2,3 layers. layer 1 (top most) and 3 (bottom most) would be hidden, layer 2 (middle layer) would be visible and then running the script would place the psd file on to layer 2.

View 3 Replies View Related

Illustrator Scripting :: Automate Action Set - Selecting Raster Images

Mar 8, 2013

I would like to automate an action set that selects a raster image (linked file) that has been grouped with vector art and then converts that selected raster image into a vector (live trace)
 
I'm using cs5 on a mac. As far as format goes I have hundreds of eps files that all have at least one raster bitmap tif which was imported as a linked file and then grouped with vector art. So I will like to run a batch script command that will select only that bitmap raster image (because I want to maintain the present vector art in the file) and convert that bitmap tif to vector- and save the file which will hopfully be in vector format.

View 2 Replies View Related

Illustrator Scripting :: Creating Bounding Rectangle And Selecting Particular Objects?

Aug 23, 2012

I'm extremely new to scripting; I managed to create a script to extend the artboard of my documents (which I was extremely proud of given my inexperience!) and another to align a couple of objects alongside each other, but my attempts to script some new code has met with failure.
 
Firstly, I need some Illustrator CS4 Javascript code that will create a bounding rectangle for the selected object(s). The selected object(s) will always be rectangular; no irregularly-shaped objects. I know this should be simple, but I can't work out the variables/attributes involved.
 
Secondly, some code to select the leftmost object in a document. And the equivalent for the rightmost object.
 
If it makes any difference, I'll be stitching these scripts together with an action to achieve the following workflow.

Two EPS files are dragged into an empty document as 'Linked Files'.The two Linked Files are aligned alongside each other. (Using a script I've already written.)The leftmost Linked File is selected and has a bounding rectangle created, which is then used to mask the Linked Object.The rightmost Linked File is then selected and has a bounding rectangle created, which is then used to mask the Linked Object.Both masked Linked Files are selected, and a bounding rectangle is created to mask them into the same Clipping Mask group.The artboard is set to the dimensions of this combined masked pair (I've managed to write that script already).The Linked Files are embedded into the document. 

The reason for this is because we have EPS map files exported from AutoCAD that are left- and right-hand pages. These need to be combined into one file, but when they are brought in they lose their masks as the BBOX element is not recognised by Illustrator. The double-masking in my process above is needed to ensure that content from either map doesn't overlap the other half of the map.

View 9 Replies View Related

Illustrator Scripting :: Selecting Objects In Layer To Copy And Paste Into New Doc?

Jul 23, 2013

How can I select all objects in a layer and copy and paste the objects into a new document? We are having issues with the copy and paste method. Is this because it uses the operating systems clipboard?

View 10 Replies View Related

Photoshop :: Can't Apply Text To All Layers Frames For GIF

Nov 22, 2006

I opened ImageReady--->Import Folder as Frames---->20 jpeg frames come up voila!

Then select all frames, open Text Tool, start typing word into Frame #1 and and now finished go to Optimize tab and only Frame #1 has text.

View 9 Replies View Related

Photoshop :: Selecting Text Layers On Tranparancy

Apr 1, 2006

how to select text layer on transparency? having heck of time with this.

View 3 Replies View Related

Illustrator :: How To Resize Layers Palette When Bottom Not Visible

Dec 23, 2012

The bottom of my layers palette is below the visible part of my computer screen...becasue I am now working away from home on my laptop (and the layers palette is showing up the same size as it was when I last used Illustrator on my large monitor screen).  How do I re-size it, so I can use the items at the bottom of the palette?

View 3 Replies View Related

Illustrator :: Turned Off Layers Visible On PDFs In Mac Products?

Jan 2, 2013

I have several documents with what I call "reference layers" in them that I turn off when making a PDF. When I view the PDF on a Windows based machine, it is fine in both FireFox and IE. When viewing the PDF on a Mac product (iPad, iPhone, Mac desktop), the layers I have turned off are showing up in the PDF.

View 6 Replies View Related

Illustrator Scripting :: Get Layers By Name VBA?

Apr 7, 2012

Is it possible to reference layers or groups by their names instead of their index using VBA? If so, what is the sytax? I know you can do it in Extendscript, but I'm not finding info for VBA.

View 7 Replies View Related

Photoshop :: Selecting Multiple Text Layers - Larger Font Size

Jun 21, 2012

I have found this post from April where the bug was acknowledged in the beta:

[URL].........
 
I now have the official release of CS6, and I am still seeing this issue. And for clarification, here's what the issue is:
 
- I start off creating a text layer with a font size of 20px.
- I then transform this layer to make it larger.
- I copy the layer over so I have identical text layers.
- When I select each individually, I am shown the new, larger font size, we'll just say 40px. But when I select both together, it shows the original font size of 20px in the character palette. When I increase the font size with both selected to say 30px, it actually makes the text more like 60px.
 
Will this bug actually get fixed?

View 5 Replies View Related

Illustrator Scripting :: How To Export Layers To SVG

Feb 13, 2013

I am trying to export layers to SVG, but I need to access the "Use Artboards" option in my ExportType.SVG options.  I do not see it in the Javascript reference: [URL]....

View 8 Replies View Related

Illustrator Scripting :: Can Create Layers With CSV File?

May 9, 2013

Is there a script that can create layers with csv file?

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved