About this article
This article introduces the main functions of Capslock+ and how to use these functions, with no detailed instructions. if you are interested in Capslock+ after reading, you may read the Capslock+ document that is in detail.
What is Capslock+
Capslock+ is a portable efficiency tool with a small size. It turns the Capslock
key into a modifier key similar
to Shift
and Ctrl
, use different functions in combination with other keys. It can save you a lot of time.
The main functions
The functions of Capslock+ mainly includes 4 parts
- A series of hotkeys for text operations. Using them proficiently allows you to operate texts (codes) more efficiently.
- Qbar: For quickly search, open files (folders), applications or page.
- WinBind: Bind windows to quickly activate / minimize.
- TabScript: To quickly output commonly used strings to reduce repeated typing, and to calculate mathematical expressions, or even perform complex operations on text.
Hotkeys for text operations
Most of the hotkeys of Capslock+ are simple and basic text operation hotkeys, there are commonly used:
Capslock+E / D / S / F
: Move Up / Down / Backward / ForwardCapslock+I / K / J / L
: Select Up / Down / Backward / ForwardCapslock+W / R
: Delete / Forward DeleteCapslock+; / P
: Move to the Beginning / End of the LineCapslock+Backspace
: Delete Line- ...
They are the most commonly used functions, that can reduce your frequency of using the mouse or touching the far arrow keys and the distance your hands moving during text editing if you use them proficiently.
For more details, see here.
Capslock+ supports hotkey settings, but it is recommended to use the default hotkey layout. A big reason why shortcuts are convenient is that they are consistent no matter which computer you use. If you are used to the default layout, on other computers, you only need to download Capslock+ and you can use it skillfully. Otherwise, you need to set the hotkeys again.
In addition, the hotkey layout of Capslock+ is based on factors such as frequency and handy of use, and ease of remembering.
It has been repeatedly changed in years of actual use. It should be quite reasonable. For example, some people may think Up / Down / Left / Right
should be placed on W / S / A / D
buttons, but note that these hotkeys are designed for text editing, not playing games. You can
always put your hand in the position of W / S / A / D
when playing games, but if you use W / S / A / D
to move the cursor
during text editing, you will have to put it back on A / D / S / F
. You must move your hand every time you move the cursor, that's unwise.
Qbar
Qbar is this thing, you press Capslock+Q
to pop it up. If you don't like this color, you can set in Capslock+settings.ini
, there are many other options can be set in it.
For more details, see here.
Quick Search
You can use Qbar to quickly search:
The default search engine is Google, you can change it to any other you like.
Other built-in search commands are:
- s(or g): Google
- m: MDN
- tb: Taobao
- wk: Wiki
Press Capslock+Q
with selected text to fill them in:
You can add or modify search commands in Capslock+settings.ini
. Capslock+ will generate Capslock+settings.ini
and Capslock+settingsDemo.ini
when it is run for the first time.
Take a look at Capslock+settingsDemo.ini
, there are setting options and examples in it. Write the settings to Capslock+settings.ini
and it will take effect after saving.
For example, to add Bing search, you can do like this:
- Open bing.com
- Search a keyword, such as
capslockplus
- Find
capslockplus
on the address bar of the results page - Replace
capslockplus
and all charaters after with{q}
- Add a setting under
[Search]
inCapslock+settings.ini
, save - You can search with Bing now
You may need to open Capslock+settings.ini
often, you can use this command to do this job: cl set
To quickly add a search command: key ->search value
Quickly open file (folder)
Enter a path in Qbar, it will show all the files and folders under the path, press Capslock+E
or Capslock+D
to select,
\
to fill the filename into the input box. Press Capslock+-
to go back, Capslock+=
to go forward.
Files or folders you often use, you can set them to Capslock+settings.ini
, and open them with a abbreviation:
To add a setting to quickly open file, just add a setting xxx=c:\the\file\path
under [QRun]
in Capslock+settings.ini
.
You can also use a command: key -> file path
. Just enter anyname
space
->
space
file path
then enter to quickly add a setting. Moreover, you don't need to copy the file path, just select a file (folder), and press Capslock+Q
to get the file path of it.
Then add something before:
You can quickly output a folder path by entering the abbreviation of it, to view the files in that folder, and quickly open:
Quickly open website
Enter a website in Qbar to quickly open it. Same as a file path, you can set an abbreviation of a website to open it quickly. The operations are similar to a file path. Let's skip the operations here.
WinBind
Window binding, after binding a window with to a hotkey, you are able to activate / minimize the window quickly with a hotkey
For more details, see here.
Mode 1
Bind a single window with a hotkey, then activate / minimize this window with that hotkey:
- Activate the window you want to bind to
- Press
Capslock + Win + 0~9
- Press
Capslock + 0~9
to activate / minimize the window
With mode 1 binding, after you close the binding window, Capslock+ will automatically find another window of the same program and bind it. If the program is not open, Capslock+ will start the program.
Mode 2
Bind multiple windows with a hotkey, and use it to switch between them:
- Activate a window you want to bind to
- Press
Capslock + Win
+ double-tap0~9
- Repeat actions 1 and 2
- Press
Capslock + 0~9
to switch between these binding windows
Mode 3
Mode 3 is similar to Mode 2, bind multiple windows with a hotkey, but mode 3 is to bind all windows of a program, including the windows that are opened after the binding operation.
- Activate a window of the program you want to bing to
- Press
Capslock + Win
+ triple-tap0~9
- Press
Capslock + 0~9
to switch between all windows of this program
When the program has only one window, the hotkey will activate / minimize the window. The program will be runned if it is not running,
TabScript
TabScript is the function of Capslock + Tab
, it can do 3 types of tasks:
- Quickly output a string you've recorded
- Evaluate mathematical expressions
- If you are similar with JavaScript, it can also perform more complex calculations and string operations
For more details, see here.
Hotstring
If you have settings under [TabHotString]
in Capslock+settings.ini
, pressing Capslock + Tab
will replace key
with value
.
For example, there is setting: email=123456789@abc.com
, then, if there is a word email
on the left of the cursor, Capslock + Tab
will replace email
with 123456789@abc.com
:
Multiple lines of text:
Because each setting of ini
file only allows one line, multiple lines of text must be replaced newline characters with \n
, to convert the multiple lines into one line.
You can also use Qbar to record, it will automatically do this job for you:
The hotstring function is effective not only for the settings under [TabHotString]
, but also for the settings under [QRun]
and [QWeb]
,
so if you have a setting of a folder under [QRun]
, you can quickly fill the folder path when you are selecting a file:
Calculation
You can enter mathematical expressions wherever you can enter text, and Capslock + Tab
to calculate it:
Using JavaScript
If you are not familiar with JavaScript, you can ignore this section.
The calculation function of TabScript is actually running JavaScript, so you are not only allowed to calculate mathematical expressions, you can run JavaScript code:
For example, to calculate the sum from 1 to 100: var i=0,j=101;while(j--)i+=j;
TabScript allows you to call functions like this:
any text any text any text any text .functionX()
Use the method of the String Object on the last line of any text. The above code is equivalent to execute:
1
2
2
// Note that special symbols will be escaped,
// and newline characters will be replaced with '\n'
'any text any text\nany text any text'.functionX()
So, you can do something like this:
You can also add your own js file, just put them in loadScript
folder, and add the file name in the loadScript
setting
under [Global]
in Capslock+settings.ini
, Capslock+ will load them at startup. Capslock+ has a built-in scriptDemo.js
file:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
// On April 23, 2016, it had the following codes
function stepNum(){
var arr = [],
init = arguments[0]||1,
count = arguments[1]||10,
step = arguments[2]||1;
while(count--){
arr.push(init);
init+=step;
}
return arr;
}
function roll(){
return Math.round(Math.random()*(arguments[0]||100));
}
//String.prototype
var sp=String.prototype;
sp.alignment = function(){
var arr = this.replace(/\n$/,'').split('\n'),
sign = arguments[0]||'=',
sort = arguments[1]||false, //sort by name?
regex = new RegExp(sign+'\\s*');
//sort by the length of variable name
var arr2 = arr.slice(0).sort(function(a,b){
return a.indexOf(sign) - b.indexOf(sign);
}),
eqIndex = arr2[arr2.length-1].indexOf(sign);
if(sort)arr=arr2;
arr.forEach(function(item,i){
var iIndex=item.indexOf(sign),
s=Array(eqIndex-iIndex+2).join(' ');
arr[i]=item.replace(regex,s+sign+' ');
})
return arr.join('\n');
}
sp.repeat = function(){
return Array((arguments[0]||2)+1).join(this);
}
By default, the Global
section has setting loadScript=scriptDemo.js
, that means Capslock+ has loaded it.
So you can use the method inside:
Other functions
Pin / unpin windows, modify window transparency
Capslock+F6
to pin / unpin a window, Capslock+F4
to modify the transparency of a window.
For me, a front end, I sometimes use it like this
- Open the design draft, pin the window
- Set it to translucent, overlay it on the browser
- Use
Capslock+LAlt
to slow down the mouse speed and adjust the position of the picture, align elements - F12, adjust the size the position of the elements until they are aligned
- Done
Extra clipboards
Two extra clipboards independent of the ststem clipboard, Capslock+X / C / V
and Capslock+LAlt+X / C / V
.
Translation
Capslock+F3
, translation function implemented by calling Youdao API:
End
This article ends here. If you are interested in Capslock+, see Capslock+ document for more details.