Plugin for Sublime Text 3 - toggle words with support for user defined arrays.
true -> false
yes -> no
on -> off
0 -> 1
left -> right
top -> bottom
up -> down
width -> height
and this automatically understand original words and ->
false <-> true
False <-> True
FALSE <-> TRUE
Set cursor on word or select word and press: alt+w, alt+t
- Download & Install
Sublime Text 3(https://www.sublimetext.com/3) - Go to the menu
Tools -> Install Package Control, then, wait few seconds until the installation finishes up - Now,
Go to the menu
Preferences -> Package Control - Type
Add Channelon the opened quick panel and press Enter - Then,
input the following address and press Enter
https://raw.githubusercontent.com/evandrocoan/StudioChannel/master/channel.json - Go to the menu
Tools -> Command Palette... (Ctrl+Shift+P) - Type
Preferences: Package Control Settings – Useron the opened quick panel and press Enter - Then,
find the following setting on your
Package Control.sublime-settingsfile:"channels": [ "https://packagecontrol.io/channel_v3.json", "https://raw.githubusercontent.com/evandrocoan/StudioChannel/master/channel.json", ],
- And,
change it to the following, i.e.,
put the
https://raw.githubusercontent...line as first:"channels": [ "https://raw.githubusercontent.com/evandrocoan/StudioChannel/master/channel.json", "https://packagecontrol.io/channel_v3.json", ],
- The
https://raw.githubusercontent...line must to be added before thehttps://packagecontrol.io...one, otherwise, you will not install this forked version of the package, but the original available on the Package Control default channelhttps://packagecontrol.io...
[!WARNING] Placing this custom channel before the default channel changes Package Control's resolution globally. Packages from this channel with the same name will override versions from the default channel.
You can review the channel contents here: https://raw.githubusercontent.com/evandrocoan/StudioChannel/master/channel.json
- The
- Now,
go to the menu
Preferences -> Package Control - Type
Install Packageon the opened quick panel and press Enter - Then,
search for
ToggleWordsand press Enter
See also:
- ITE - Integrated Toolset Environment
- Package control docs for details.
You may redefine the key bindings in your sublime-keymap with command toggle_word.
You can define lists of words, which will be cycled through in order.
Example file ToggleWords.sublime-settings:
{
// User defined words
"toggle_words_dict": [
["left", "right"],
["up", "down"],
["top", "bottom"],
["width", "height"],
["red","orange","yellow","green","blue","purple"],
["true", "false"],
["yes", "no"],
["on", "off"],
["0", "1"]
]
}
If installed using Package Control dictionary file should be located in <data_path>/Packages. To get there select Preferences -> Browse Packages... in Sublime menu. Create one if it does not exist.