ColorPicker
A multi-platform color picker plugin
Details
Installs
- Total 1.48M
- Win 1.08M
- Mac 214K
- Linux 187K
Jul 27 | Jul 26 | Jul 25 | Jul 24 | Jul 23 | Jul 22 | Jul 21 | Jul 20 | Jul 19 | Jul 18 | Jul 17 | Jul 16 | Jul 15 | Jul 14 | Jul 13 | Jul 12 | Jul 11 | Jul 10 | Jul 9 | Jul 8 | Jul 7 | Jul 6 | Jul 5 | Jul 4 | Jul 3 | Jul 2 | Jul 1 | Jun 30 | Jun 29 | Jun 28 | Jun 27 | Jun 26 | Jun 25 | Jun 24 | Jun 23 | Jun 22 | Jun 21 | Jun 20 | Jun 19 | Jun 18 | Jun 17 | Jun 16 | Jun 15 | Jun 14 | Jun 13 | Jun 12 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 0 | 31 | 44 | 55 | 32 | 48 | 35 | 23 | 33 | 52 | 46 | 32 | 32 | 28 | 31 | 58 | 46 | 44 | 46 | 35 | 31 | 33 | 55 | 42 | 27 | 40 | 33 | 30 | 48 | 44 | 35 | 35 | 48 | 64 | 44 | 27 | 36 | 63 | 61 | 50 | 59 | 31 | 48 | 44 | 72 | 43 |
Mac | 0 | 5 | 8 | 7 | 3 | 4 | 5 | 2 | 4 | 7 | 2 | 5 | 6 | 5 | 4 | 7 | 6 | 4 | 4 | 7 | 3 | 3 | 8 | 3 | 7 | 9 | 6 | 5 | 8 | 3 | 9 | 1 | 3 | 8 | 4 | 2 | 8 | 8 | 7 | 6 | 6 | 4 | 5 | 6 | 8 | 7 |
Linux | 0 | 12 | 6 | 9 | 1 | 7 | 7 | 1 | 2 | 5 | 8 | 6 | 6 | 10 | 5 | 5 | 6 | 7 | 6 | 3 | 11 | 3 | 8 | 7 | 7 | 6 | 6 | 7 | 2 | 6 | 1 | 5 | 4 | 11 | 4 | 0 | 6 | 4 | 9 | 7 | 7 | 8 | 7 | 4 | 3 | 7 |
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