Illustrator Scripting :: Convert To Grayscale For Selected Item

Feb 4, 2014

It is possible to apply the Convert to Grayscale(Edit->Edit Colors->Convert to Grayscale) for the selected items in illustrator cs3 in script (javascript)?

View 12 Replies


ADVERTISEMENT

Illustrator Scripting :: Simple / Direct Method To Identify Index Of Selected Item In List Box

Jul 16, 2013

I can't seem to figure out a simple/direct method to identify the index of the selected item in a list box.

I feel like I'm missing something, but I can't seem to figure which (if any) property returns an index number if you use it with the .onChange callback for a ListBox.

The following code accomplishes what I need but isn't particularly efficient or elegant and can get muddled if you introduce multiple lists to check.

Any way to duplicate this same behavior with better code
 
var res = "palette {text: 'Example List', properties:{resizeable:true}
pnl: Panel{orientation: 'row',preferredSize: [400,600],
list1: ListBox{preferredSize: [400,550], properties:{multiselect:true,numberOfColumns:2, showHeaders:true,columnTitles: ['List 1', 'Subitem 0']}},
}}"

[Code]...

View 4 Replies View Related

Illustrator Scripting :: Is It Possible To Access And Run A Menu Item

Feb 6, 2013

When writting scripts to Photoshop I can use the app.runMenuItem() method to acess commands in the menus. For example: app.runMenuItem (charIDToTypeID("ZoomIn")) will run the Zoom In command.
 
Does Illustrator have any such method (or accepts anything like action description) to enable us to acess it´s menu items? For example acess Expand comnand, or Object > Live Paint > Make..

View 2 Replies View Related

Illustrator Scripting :: Page Item Name Property In UI

Jan 14, 2013

Does name property of a page item appear anywhere in the user interface in Illustratpr CS6? I thought it would be the name you assign to it in the Layers palette, but it does not appear to be.

View 2 Replies View Related

Illustrator Scripting :: Move Anchor On Path Item

Jun 21, 2013

All I am trying to do is move an anchor from one location to another using vbscript.  I have searched everywhere and scoured the scripting references but I have not been able to figure this out as of yet.
 
I am able to select anchor points without an issue....moving those points seems to be a problem. 

View 5 Replies View Related

Illustrator Scripting :: Raster-item Didn't Get Color

Mar 22, 2012

I have written a small application in .NET that gives color to Illustrator files.I have a layer with 100 color items (paths with a fillcolor). Each one has a unique name. Through that name my program looks them up, takes the fill color and applies that color to another path.Recently there was a change in Design, the drawings that I had to provide of a Fillcolor were no no longer pathitems but rasteritems (imported from photoshop). I thought ok no problem instead of setting the Fillcolor property I'll use the Colorize method on the rasteritems. It worked fine but now and then I came across a situation where raster-item didn't get the color. After digging in to it I saw that it was because some colors are Pantone colors and the colorize method on rasteritems only takes RGBColor or CMYKcolor objects. How to do it with the pantone colors?

View 1 Replies View Related

Illustrator Scripting :: Accessing Elements Of A Page Item

Jan 6, 2014

I am working on a script that performs a series of things on all of the artwork in a document.  At one point, it needs to compare the fill color of every item to a sample color.  The problem is, the artwork is a collection of compound path items and path items.  When I look for pathItems[x]. fillColor, it works fine.  When I look for compoundPathItem[x].fillColor, it comes back undefined.  So, I've moved to looking at page items, but I seem to be unable to get to the internals on the page items.  If I have a compound path item, how would I address its properties from its parent page item?  I tried:
 
pageItem[x].compoundPathItem.pathItems[0].fillColor,
pageItems[x].fillColor,   & 
pageItems[x].compoundPathItem.fillColor. 

View 9 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 :: Feasible To Disable A Menu Item

Apr 10, 2012

illustrator scripting but have some knowledge in indesign scripting using javascript.In Indesign we can disable menu item thru menuActions.. Is there any object available like that to disable a existing menu (eg. File>Save).

View 1 Replies View Related

Illustrator Scripting :: Get Only Paths Of Embedded Placed Item (without Clipping)

Sep 23, 2012

I use my script to embeding a placed graphic (MyImage.embed();). Then I always get a group with the correct paths and two clipping paths in a grouped grouped groupItem.
 
My question is: I want to delete the two clipping paths to get only the correct paths of the graphic.

This is, what I always have:

and this is, what i want:

View 8 Replies View Related

Illustrator Scripting :: How To Change Colors Of Path Item

Nov 26, 2013

I'm trying to change the colors of a pathItem corresponding to the string value of several text fields in my document. I've been successful in changing the fill and stroke color of the pathItem, but I can not find any reference in the Illustrator Javascript Guide for accessing additional strokes and/or fills that have been applied to the object in the Appearance panel.

View 1 Replies View Related

Illustrator Scripting :: Biggest Path-item In A Document?

Sep 17, 2013

is there a way to determine the biggest item in a document using javascript?

View 4 Replies View Related

Illustrator Scripting :: Open Any Menu Item By Script

Jun 21, 2012

if there is a way to open any menu item by script (Javascript) in illustrator CS5/5.1? perhaps something like this:

"app.menuActions.itemByID(0123).invoke()".

I looked at the scripting reference, but i didn't found it.

View 4 Replies View Related

Illustrator Scripting :: How To Add Script To Actions Via Insert Menu Item

Jan 14, 2013

This has been an issue since at least CS4. If you add a script to your actions via "Insert Menu Iitem" (not sure if it's for all items or just scripts) and close Illustrator, those actions disappear. Apparently, in CS6, Adobe has completely ignored improving including scripts to Actions, which really makes automation powerful. As awesome as CS6 is, that part is pretty lame.

View 1 Replies View Related

Illustrator Scripting :: How To Read Swatch Used For Fill Color Of A Page Item

Mar 21, 2012

Is there a way to read the swatch used for fill color of a page item?
 
I can read the fill color but I can't read if the color is a global swatch.

View 2 Replies View Related

Illustrator :: Possible To Convert Color To Grayscale Using Recolor Artwork?

May 25, 2012

Is it possible.

View 11 Replies View Related

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 :: Get Position Of Selected Object

Oct 4, 2012

is there a way to get position of any selected object? It seems like normally you have to dive into specific item like textFrames to get position, but was curious if there was a generic way of doing this for selected objects.

View 5 Replies View Related

Illustrator Scripting :: How To Determine The Size Of Selected Text

Sep 6, 2012

I'd like to draw a box around some selected text (a textRange), however I can't figure out how to detemine the size or position of the text.  The overall size of a textFrame is possible to find (not sure about position), but when you've got just a few characters selected I don't see any way to get the size or position. 

View 6 Replies View Related

Illustrator Scripting :: Align Selected Objects To Artboard

Nov 15, 2013

Simple solution to aligning selected items to the artboard. I was going to create an action but then realized it would be more convenient for me to include it in my script file....I have a script to align objects with each other but they dont align to the artboard.

View 11 Replies View Related

Illustrator Scripting :: How To Set Color For Each Selected Object Via Eyedropper

May 30, 2013

When I run the script for an object selection, I want each object to have its color set to the underlying color as if I had used the eyedropper tool.  Is this something that can be scripted?

View 1 Replies View Related

Illustrator Scripting :: Get Width That Multiple Selected Items?

Apr 23, 2013

How can I get width that multiple selected items? (Not grouped.)
 
//---------- source code ----------
 var mm = 2.83464566929134 //unit conversion. (point->milimeter)
var W = docRef.selection[0].width/mm;
alert(W); 
//---------- source code ----------

View 3 Replies View Related

Illustrator Scripting :: Turn Selected Sublayers Into Top Level Layers

Jun 5, 2008

I wanted to ask if by chance any of the scripting gurus here happen to have written an AI script that will take a number of selected sublayers/sub-sublayers and move them so they become top-level layers?

I am really needing this very badly, given that After Effects can only handle AI layers as separate entities. So I find myself moving tens, even hundreds of nested sublayers to the top level all the time.

Is it possible this script exists already?

View 16 Replies View Related

Illustrator Scripting :: How To Return Array Of Paths In The Order They Were Selected

Feb 1, 2013

Is there a method to return an array of paths in the order they were selected, instead of their descending z-index (default behaviour)?
 
I'm writing a script that "connects" the centers of currently selected objects through a stroked path, and I want it to follow the order in which I select the objects, regardless of the stacking order.

View 13 Replies View Related

Illustrator Scripting :: Replace Layer Names In Selected Layers Only?

Jan 22, 2014

I am using this script to find and replace words in layers. (The script only targets particualr words, rather than the whole layer name).
 
I would like to make it so it targets selected layers only.
 
I have found this script which loops through selected layers only, but I am not sure how to add the find and replace layer name functioality.

View 7 Replies View Related

Illustrator Scripting :: Changing Selected Text Color With JavaScript

Feb 25, 2013

I want to change my selected text to a different cmyk color using javascript. I have tried and I do not know what is missing or what I am doing wrong.
 
if ( app.documents.length > 0 ) {
newCMYKColor = new CMYKColor();
newCMYKColor.black = 0;

[Code]...

View 4 Replies View Related

Illustrator Scripting :: Export Selected Artboards PNG24 JavaScript?

Mar 1, 2013

I'm trying to do some workflow enhancements. For our games we need to export to PNG at different resolutions for different mobile devices. I use a artboard per asset and currently manually export 3 times (using file/export/png with use artboards option), at 72 dpi, 144 dpi and 33.75 dpi.
 
I've been modifying a simple Javascript I downlaoded and have got it save to different fixed locations at different scales. All good. However exporting every artboard each time will cause issues with our version control system and take too long. It's not really a solution.
 
So I need a way to either only export the current selected artboards (which I believe can't be done) or somewho show the artboard range dialog that the system uses. Either of those would be a good solution.
 
var docRef = app.activeDocument;
var num_artboards = docRef.artboards.length;
var getName = app.activeDocument.name;
var fileName = getName.slice(0, -3);
[code]...

View 7 Replies View Related

Illustrator Scripting :: Allow To Select Image To Replace Any Number Of Selected Files

Apr 18, 2013

I've written a script to allow you to select an image to replace any number of selected files.  Each file starts out as an embeded image with a .note to determine where the basis of alignment for the new file should be (i.e. "top," "bottom," "left," "right").  You'll find the code below:
 
#target illustrator
 
if (app.documents.length > 0) {
    var docRef=app.activeDocument;
    var docSelection = docRef.selection;
    // ** Get new file
   
[Code]...
 
For some reason, the ".note" added at the end of the script gets erased once the script is complete.  I can even get it to confirm that it applied the note to the image, but once it's complete, it's gone. 

View 6 Replies View Related

Illustrator Scripting :: JavaScript To Send Selected TextFrame To Current Layer?

Feb 20, 2013

Is there a way to send a selected textFrame item to a layer using javascript?
 
I don't mind if it is send to current layer or some other way to accomplish the task.
 
(Using Adobe Illustrator CS4)

View 5 Replies View Related

Illustrator Scripting :: CS5 - Change Fill Color Of Selected Path Items

Apr 2, 2013

I'm trying to create a script in CS5 mac os10.6.8 that will change the fill color of selected pathItems. I need a simple script that will change a selected pathItem to cmyk values 2,3,15,0. I will then select this script and implement the action in a batch of 600 files.
 
I wish this process could be recorded as an action but when I record the action "add new swatch" I have to manually input the cmyk values, which will take forever for a batch of over 600 files.

View 15 Replies View Related

Illustrator Scripting :: How To Convert EPS File To SVG

Sep 11, 2012

I added CS6 COM reference in my VB.NET application and after that I have the following basic object creation in order to convert a eps file to svg. But for some reason when I create this COM object it is launching the Adobe Illustrator application. Why it is doing like this? It’s a simple COM object why it is interacting with Illustrator Editor?

View 9 Replies View Related







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