ColorPicker
A multi-platform color picker plugin
Details
Installs
- Total 1.49M
- Win 1.09M
- Mac 215K
- Linux 189K
May 9 | May 8 | May 7 | May 6 | May 5 | May 4 | May 3 | May 2 | May 1 | Apr 30 | Apr 29 | Apr 28 | Apr 27 | Apr 26 | Apr 25 | Apr 24 | Apr 23 | Apr 22 | Apr 21 | Apr 20 | Apr 19 | Apr 18 | Apr 17 | Apr 16 | Apr 15 | Apr 14 | Apr 13 | Apr 12 | Apr 11 | Apr 10 | Apr 9 | Apr 8 | Apr 7 | Apr 6 | Apr 5 | Apr 4 | Apr 3 | Apr 2 | Apr 1 | Mar 31 | Mar 30 | Mar 29 | Mar 28 | Mar 27 | Mar 26 | Mar 25 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 10 | 62 | 29 | 23 | 29 | 17 | 28 | 52 | 35 | 24 | 24 | 36 | 20 | 28 | 35 | 50 | 43 | 38 | 37 | 23 | 30 | 20 | 34 | 30 | 56 | 23 | 25 | 16 | 68 | 52 | 32 | 28 | 48 | 28 | 47 | 92 | 65 | 44 | 39 | 29 | 25 | 19 | 61 | 24 | 31 | 20 |
Mac | 3 | 8 | 7 | 3 | 2 | 4 | 6 | 8 | 4 | 0 | 2 | 1 | 3 | 1 | 6 | 19 | 6 | 5 | 9 | 2 | 1 | 4 | 5 | 2 | 7 | 4 | 1 | 3 | 10 | 6 | 4 | 6 | 5 | 4 | 3 | 7 | 6 | 5 | 7 | 0 | 0 | 1 | 2 | 4 | 3 | 6 |
Linux | 0 | 4 | 7 | 8 | 6 | 1 | 7 | 8 | 4 | 5 | 5 | 1 | 1 | 7 | 8 | 5 | 2 | 7 | 3 | 1 | 3 | 6 | 4 | 7 | 7 | 7 | 2 | 5 | 5 | 4 | 5 | 6 | 6 | 2 | 8 | 3 | 5 | 6 | 2 | 7 | 5 | 4 | 7 | 3 | 3 | 3 |
Readme
- Source
- raw.githubusercontent.com
Mac OSX
Linux
Windows
Installation
Install this repository via Package Control.
Usage
To insert or change a selected color, use:
- Linux:
ctrl+shift+c
- Windows:
ctrl+shift+c
- OS X:
cmd+shift+c
or use menu action
Tools
** -> **ColorPicker
By default, the hex color code is inserted using uppercase letters. To use lowercase letters instead, copy the contents of **Preferences -> Package Settings -> ColorPicker -> Settings-Default
** to the empty file created by selecting **Preferences -> Package Settings -> ColorPicker -> Settings-User
**, then change "color_upper_case"
to false
.
Calling from Other Plugins
To commands are provided to assist in calling a color picker from other plugins. Info is shared between the plugins via a settings file. It does not have to exist on disk; it can exist only in memory for the sole purpose of sharing the return. It is advised to use a unique name for the settings file. The data is returned in the settings key color_pick_return
. It is advised to set color_pick_return
to None
in your settings file before calling any of the commands. So you can tell if it set teh variable or not.
ColorPickApiIsAvailableCommand
This command is used to test if ColorPicker is installed.
>> settings = sublime.load_settings('my_shared.sublime-settings')
>> settings.set('color_pick_return', None)
>> sublime.run_command('color_pick_api_is_available', {'settings': 'my_shared.sublime-settings'})
>> print(settings.get('color_pick_return'))
True
ColorPickApiGetColorCommand
This command is used to call a color picker and get the selected value. It takes a setings file and an optional default_color
.
>> settings = sublime.load_settings('my_shared.sublime-settings')
>> settings.set('color_pick_return', None)
>> sublime.run_command('color_pick_api_get_color', {'settings': 'my_shared.sublime-settings', 'default_color': '#ff0000'})
>> print(settings.get('color_pick_return'))
#23af44