Skip to main content
Participating Frequently
February 22, 2014
Answered

Show color picker dialog JSX / CSAW

  • February 22, 2014
  • 3 replies
  • 11203 views

Can someone guide me on how to show the color picker dialog in Illustrator programmatically?

In photoshop that's really easy, just:

     app.showColorPicker(true);

In Illustrator I couldn't find any reference to such a method or other possibility to show the dialog programmatically, that you would normally get when double clicking on the fill color square within Illustrator.

Is that possible by using app.executeMenuCommand or some other method?

I am writing a script that opens the color picker dialog in reaction to a click on a button. I want to be able to get the chosen color and use it within the script.

thanks for the help!

Dominik

This topic has been closed for replies.
Correct answer CarlosCanto

I'm not sure if you can bring up Illustrator's color picker, in the mean time you can play with JS color picker

alert($.colorPicker ());

3 replies

Inventsable
Legend
June 15, 2020

In case any one is reading this in the future like I was earlier today, you can indeed use the native color picker:

var startColor = new CMYKColor();
var result = app.showColorPicker(startColor);

alert(result)
schroef
Inspiring
May 11, 2020

It does show the picker, issue is. When I link this to a button for say a dialog window. Closing the colorpicker also closes the dialog window. I wanted to use this method to let user refine a color. 


CarlosCanto
Community Expert
CarlosCantoCommunity ExpertCorrect answer
Community Expert
February 22, 2014

I'm not sure if you can bring up Illustrator's color picker, in the mean time you can play with JS color picker

alert($.colorPicker ());

Participating Frequently
February 22, 2014

Hey Carlos, thanks for the fast answer!

Yeah I already saw that it's possible to bring up the native color picker via JSX, is there an easy way to execute the same from an ActionScript environment / or can I execute a jsx script function and get the result from AS?

Inspiring
March 6, 2014

Whoa, that is awesome indeed.

Dominik Guzei wrote:

I am still fleshing out the infrastructure for my own extensions and will gradually improve it to a point where you don't need to touch the ActionScript part of the extension

As far as the Actionscript portion, does that aspect of this framework get effected by the looming depreciation later this year of Flash based extension Support?

Few references about it being mid 2014:

http://forums.adobe.com/message/6107511

http://forums.adobe.com/thread/1298733

Or is that irrelevant to this framework?

Dominik Guzei wrote:

A possible future might be a online service where you can configure your basic extension information like the name, icons etc. and download a complete build, based on the opinionated infrastructure mentioned above!

If someone would take this framework to the point of a turnkey front-end GUI to build and develop HTML based extensions based upon complete user input, etc, that would be incredible, if possible.


This is pretty sweet as well, have you seen this Dominik Guzei ?

Creative Cloud Extension Builder for Brackets

http://davidderaedt.github.io/CC-Extension-Builder-for-Brackets/

http://davidderaedt.github.io/ccext-website/

http://brackets.io/