Illustrator Scripting :: How To Iterate Story To Find If Characterstyle Is Applied To Its Textranges

Apr 18, 2013

Does source like below work?
 
characterStyle.parent == theStory.textRanges[i]
 
One more questions is if there might be a CharacterAttribute who belongs no characterstyle? Can I iterate charaterstyles to know all the font, bold .. information for all teh textranges?

View 5 Replies


ADVERTISEMENT

Illustrator Scripting :: Iterate Through Selected Characters

May 3, 2012

Code snippet to show me how to iterate through the selected text (not the frame!, not the words, only the selected chars) and make any change on the characterAttributes (size, color, etc.)?
 
In the property "app.activeDocument.selection" usually the selected objects are stored as an array. Now when I select characters in a textframe (or TextPath, whatever) there is a [Textrange] in it. I already tried some combinations like this snippet underneath but I still get errors, that selectedChars[i] is undefined.I'm on Illustrator CS4, Mac OS X, Javascript
 
var selectedChars = app.activeDocument.selection.characters;
for (i = 0; i < selectedChars.length; i++ ){                           
selectedChars[i].characterAttributes.fillColor = myNewCMYKColor;

View 14 Replies View Related

Illustrator Scripting :: Iterate And Remove Objects In A Layer

Apr 9, 2013

I am trying to iterate through objects in a layer and if the object satisfy a condition, I want to remove it.
 
Problem is that from what I suspect, if I use a "for loop" then when I remove an element, the initial length of the loop becomes invalid by removing the element. So what I would need is to iterate through objects in another matter and I am clueless.

View 3 Replies View Related

Illustrator Scripting :: Can Tint Be Adjusted For Items On Page That Have Spot Color Applied

Sep 27, 2012

I have been trying to mess with and target "tints" via javascript but either I am not understanding something or it cant be targeted as I had hoped, so I am looking for direction and guidance. I have a spot color assigned in the color swatches palette, and have drawn a few boxes on the page using this spot swatch. I then try to alter the tint using JS code.
 
sel[i].tint = // whatever number
alert(sel[i].tint) // This alerts fine
 
The alert shows a change taking place but it never gets applied to the item, the actual item never gets changed. I know things are properly targeted as I can change other attributes fine. When I look in the JS documentation it just shows for when creating a new spot, not for ones that already exist on items, I cant seem to find an example otherwise.
 
Can tint be adjusted for items on the page that have a spot color applied?

View 8 Replies View Related

Illustrator Scripting :: Find And Replace Artboard Name

Mar 26, 2013

Is it possible to use a JS script to find/replace artboard names?  For example if I have artboards that are currently named 39 and 42...can I use a script to change the name of the art boards to 39E and 42C etc?
 
Also part of the script a simple find/replace of text on locked layers.

View 4 Replies View Related

Illustrator Scripting :: How To Find A Way To Loop Through All Items

Apr 6, 2012

I'm trying to find a way to loop thru all items in an Illustrator document and get their stroke and fill color.  Sometimes items are spots, sometimes documents are set to RGB or CMYK, etc, so swatches can be a mixture of things.  Is there an easy way to get the swatch name for each item?
 
For example, I can check if an item is a spot, and get it's color like so:
 
var c = app.activeDocument.pageItems[0];
if (c.strokeColor.typename === 'SpotColor') {
    var s = c.strokeColor.spot.name;
}
 
But if I try to get the name from an item colored 'Black' (which is set to Process Color, CMYK), then I'll need to do something else like:
 
var c = app.activeDocument.pageItems[0];
if (c.strokeColor.typename === 'CMYKColor') {
    var s = c.strokeColor.name;  // This returns undefined - not sure what I'm doing!!!
}
 
Is there an easier way to achieve this, other than getting the typename of each item, and then trying to figure out it's color name?  I was hoping something like this would work:
 
var c = app.activeDocument.pageItems[0].strokeColor.name;

View 3 Replies View Related

Illustrator Scripting :: How To Easily Find A Character If Its Attribute Different From Others

Apr 22, 2013

How can I easily find a character if its attribute is different from others? There might be some easier way than compare it one by one.

View 2 Replies View Related

Illustrator Scripting :: Find A Way To Get The Links And Link Statuses?

Jan 24, 2013

I'm trying to find a way to get the links and link statuses in Adobe Illustrator. It doesn't seem to be at all similar to InDesign DOM.
 
What I'd like to be able to do is check whether a file has a missing link. I have been able to trace it to a "placedItem" which is inherently a "pageItem". So is it possible to find the link status? Been going through the DOM for about a half hour now and still can't find it.
 
 app.documents[0].placedItems[0]  <--- How to get link status?

View 2 Replies View Related

Illustrator Scripting :: Find And Replace Month Names?

Sep 4, 2013

I have a few eps files in which month-year format is written like May-12, June-13 etc. I want to change May to Mai, June to Juin etc.
 
Virender 
var myDoc = app.activeDocument;
for (i = 0; i < myDoc.textFrames.length; i++ )
{

[Code]....

View 4 Replies View Related

Illustrator Scripting :: How To Find Out That Art Item Has Spot Color

Jul 4, 2012

I have a number of art items on a document, some of them are filled with spot colors and some of them are with process color.Is there any method by which I can find out which color type(spot or process) is applied to the selected art item?

View 4 Replies View Related

Illustrator Scripting :: Find And Replace Layer Names

Mar 19, 2013

Are there any scripts to find and replace layer names?
 
There is an excellent script available for Photoshop which allows you to not only replace words in layer names, but also insert words as Prefixes, Suffixes and Sequential Numbers. The illustrator version of this script only allows sequential numbering: It doesn't offer find and replacing of words.
 
Ideally, it would be great if there was something that could do multiple find and replaces in one go:

(E.g.
You have layers like this Car, Dog, Bat
You enter: car(Option1), dog(Option2), Bat(Option3)
Your layers then become: Option1, Option2, Option3).
)

View 12 Replies View Related

Illustrator Scripting :: Find And Replace Symbol Content

Nov 18, 2013

I have multiple documents using text as symbols. I need to change a ® 2013 to  a ® 2014 within the symbols. Without having to go into each document and double click on the symbol or break the link, is there a way to do a batch find and replace that will search within symbols to change text?

View 2 Replies View Related

Illustrator Scripting :: How To Find Out Textframe Contains Stroke Color (or) Fillcolor

Jul 5, 2011

How to find out the textframe contains "stroke color" (or) "fillcolor" via javascript. Any sample.

View 5 Replies View Related

Illustrator Scripting :: How To Find Darkest Color In Document Swatches

Oct 15, 2012

Is it possible to find out how bright is an color? I need to find the darkest color in document's swatches. My solution would be to convert (script internally, without actually making any changes in document) swatches to grayscale, compare them and pick the darkest. But how to convert  swatch defined in undefined mode (they might be in lab or cmyk) to grayscale?
 
I found in 'js scriping reference' a method "convertSampleColor", but I have no idea how to use it. Any examples?

View 2 Replies View Related

Illustrator Scripting :: Find And Replace Script With Values Via Excel

Feb 18, 2013

I am searching for a simple automated Find and Replace script, the idea is that in Excel the Find and Replace with texts are located. The script finds the textblock in Illustrator and replaces it with the value from Excel "New number".
 
Example Illustrator:

Example Excel Find and Replace:

View 1 Replies View Related

Illustrator Scripting :: Find And Replace Script Using Info From File Name?

Jun 11, 2012

Is it possible to write an Illustrator (CS4) script that would find and replace 2 instances of text using the actual file name to supply the changing text?
 
Our current file naming system uses a Part Number, Catalog Number and Run Date. (example: 123456_ABCDEF_2014 JN)We are currently saving a master file as the new Part Number and simply doing 2 separate find and replace functions for the Catalog Number and Run Date. Unfortunately we have over 500 parts to change and thought we could narrow down the 1000 find and replace to just 500. Although this may not appear like such a time saver, the key factor would mean entering the changing data just once per file, minimizing errors and eliminating proof reading the actual file.
 
Here is what I have used for a simple find and replace script, but I cannot seem to find any information to connect the file name data.
 
[code]

var active_doc = app.activeDocument;
 var search_string = /ABCDEF/gi; // g for global search, remove i to make a case sensitive search
var replace_string = "GHIJKL";
 var text_frames = active_doc.textFrames; 
var search_string2 = /1234 XX/gi; // g for global search, remove i to make a case sensitive search
var replace_string2 = "5678 YY";

[code]....

View 1 Replies View Related

Illustrator Scripting :: How To Automate Importing Variable And Datasets Into Graphs Via Scripting

Dec 18, 2012

I'm try to automate the importing of the Varaible and datasets into my graphs via Scripting, but the ImportVaraibles() function doesn't seem to work.  Here is my Script, mostly copied from the example script provided with Illustrator (CS5).  And, this works manually, using the file names in the script, via Load Variable Library
 
    Set appRef = CreateObject(strIllistratorVersion)
   
       'Open the file and import the datasets
        Set docRef = appRef.Open(strTemplate & "200-500.ai")
        'docRef.Datasets.RemoveAll
        docRef.Variables("Yearbook").Delete
 
Here is the problem, after I delete the previous library, then this next line, right from the example, does nothing
The script then exits with 'No Datasets in this document'
       
docRef.ImportVariables (strXMLFolder & "Lumber_200-500.xml")
'appRef.DoJavaScript "alert('Template:" & strTemplate & strRange & ".ai  |  XML file:" & strXMLFolder & ""  & objFile.Name & "^')"
        If (appRef.Documents.Count > 0) Then
            Set docRef = appRef.Documents(1)

 [Code]....
 
If I remove that delete line, the script runs, but just uses whatever Variables I had last loaded, not the XML file.
 
It's simply not loading.  What do I need to do to get it to load?

View 8 Replies View Related

Photoshop :: Story Book

Apr 15, 2006

I am making a children's book for a school project.

I want to use one picture per page, but I want this effect for the background of the one picture.

Essentially, I want to imitate the design that the link uses with the effect covering different colors on different pages.

I also want a darkened area with the same dark color used in the outline of the pictures as a block for my text to be put on to.

View 4 Replies View Related

Illustrator Scripting :: Access Graph Data Through Scripting DOM?

May 6, 2012

Can you access graph data through the scripting DOM?

View 3 Replies View Related

Lightroom :: Placing Photos In A Story Telling Sequence

Jul 30, 2013

I need to know how to place my photos in a story telling sequence in Lightroom instead of the order the photos were taken.

View 1 Replies View Related

InDesign :: Extract The Data From Tracking / Story Editor Outside?

Feb 20, 2014

Can you extract the data from tracking/story editor outside of InDesign?  I do a large catalogue and want a way to identify which product sets had changes made to them or not, but not just within story editor, but download the data to say a txt file or excel, etc.

View 4 Replies View Related

Illustrator :: How To Use Pathfinder On Objects That Have Effects Applied

Aug 15, 2013

I outlined a bit of text, and then applied Effect > Warp > Arch. What I'd like to do is cut apart parts of the now outlined letters. I tried to use the pathfinder palette, but it applies the pathfinder to old, non-arched shape.

View 2 Replies View Related

Illustrator :: Stroke Is Not Applied Consistently To All Elements

Aug 26, 2013

Why do some elements allow an inside stroke (not centered on vector line) and others do not?

View 5 Replies View Related

Illustrator :: Font Style Cannot Applied With Eye Dropper?

Feb 2, 2013

I am working with font "not a free one" and it has a problem that I can not take its style with the eye dropper,
 
it only gives the same font name but the shape of font did not applied

View 7 Replies View Related

Illustrator :: How To Remove Applied Brush From A Path

Aug 26, 2012

Mac ox lion

cs5
 
I have a crown I'm working on and I applied grunge brushes to the diamonds and shines. I would like to remove the grunge and keep the lines as they were before, smooth and clean. Is there an option or quick fix to do this? I created these diamonds and shines a long long time ago or I would just cmd+z. I have not expanded the paths, I have kept them them the same .25 stroke and no fill

View 2 Replies View Related

Illustrator :: Filled Path When There's No Fill Applied?

Jan 17, 2013

I have this path that I got from Shutterstock. No matter what I do with it, it's got this green fill on it. So if I apply a grey fill to it, the grey fill is put on top of the green. If I remove the fill completely, the green fill is still there.
  
Maybe the person who made it applied some kind of magical unremovable fill color to it or someting?
 
I've ungrouped it, checked that there's no effects in the appearance panel, and of course checked that there's no outline on the path. I've also tried releasing compund paths. There's no opacity mask or transparency modes. Nothing worked.

View 9 Replies View Related

Illustrator :: Opacity Mask Applied To Multiple Layers?

Feb 14, 2013

I'm trying to apply an opacity mask to multiple layers (which happen to be contained within a Layer Mask). When I make the Opacity Mask, it takes all of the stuff on different layers and compresses them to a single layer (see attached images). I would like to keep the data on their assigned layers for later editing. I've done this before, but I have a feeling I have a setting or pref de-selected somewhere. Could the layer mask be the culprit?

View 6 Replies View Related

Illustrator :: Copying Element Which Has Graphic Style Applied

Mar 28, 2013

Copying an element  which has a graphic style applied  now breaks apart the style into individual elements if the style is applied to text, the text is outlined too. This never use to happen. Have tried changing the  paste board setting  but this changes nothing.

View 8 Replies View Related

Illustrator :: Cs6 - Adding Color To Type After Effect Is Applied?

Jun 25, 2013

Using Illustrator CS6.  Created type and applied an effect (Graphic Pen) and the yet I could not get it to do anything but come out as black.  How do you apply color to the effect?

View 2 Replies View Related

Illustrator :: Colors Become Pale When Colored Background Is Applied To Logo?

Oct 23, 2012

I am working with a vector file that was created by someone else and am unable to get a hold of that person. It is of a logo and when I applied a colored background to the logo or import it into another file, the color of some objects of the log becomes very pale and "desaturated."

View 5 Replies View Related

Illustrator :: Graphic Styles Applied To Layers - Attributes Do Not Scale?

Feb 18, 2014

When I use a numeric scale from the scale dialog box, Illustrator will not scale the the strokes and patterns attibutes applied to the layer via a graphic style. Has this always been the case, or is this a new CC feature? You know the ones that keep popping up as I'm trying to get my work done. I have to calculate the scale of all my patterns and strokes MANUALLY?

View 6 Replies View Related







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