Sampling colors in an image with the Mac OS X Color Picker

Consider my mind blown. I did not know you could drag and drop an image onto the Mac OS X color picker so you can sample colors from that image (this has been around forever, I just never knew).

This is incredibly useful. Read the article for all the details.

Want to try this yourself? If you happen to have an application installed that uses the standard Apple Color Picker, go for it. But here’s a roll-your-own way to bring up the color picker.

Launch the AppleScript Editor application (it’s in Applications > Utilities). When the editor appears, use File > New to bring up a new script. Enter this text in the script window:

choose color

That’s all you need. Now select File > Save… and change the File Format popup to read Application. Give it a name you like and save that sucker. Now double-click the AppleScript application you just created and you’ve got yourself a little color picker to play with.

[Via iOS Dev Weekly]