Vim Tips Wiki
(Move categories to tip template)
Line 22: Line 22:
 
</pre>
 
</pre>
   
  +
====How to create an undo registry file====
==Comments==
 
 
I'd suggest, if the text above is copied into a file "caps2ctrl.reg", also making a file "un-caps2ctrl.reg" in which you place the following:
 
I'd suggest, if the text above is copied into a file "caps2ctrl.reg", also making a file "un-caps2ctrl.reg" in which you place the following:
   
Line 30: Line 30:
 
</pre>
 
</pre>
   
  +
Or you can simply delete the key using the registry editor.
This gives you a way to reverse things if you don't like it. ;)
 
   
  +
====Swapping keys rather than replacing CAPS====
----
 
 
The registry entry above sets the caps to ctrl. The following registry entry actually swaps the caps-lock and registry keys on your keyboard. Useful if you like using caps-lock from time to time.
This site has an explanation on what's going on here:
 
http://www.annoyances.org/exec/forum/winxp/t1004806455
 
 
----
 
Quick addendum to my tip. The registry entry above sets the caps to ctrl. The following registry entry actually swaps the caps-lock and registry keys on your keyboard. Useful if you like using caps-lock from time to time.
 
Remember, to undo this, just delete this entry and your system will revert to the default behavior.
 
   
 
<pre>
 
<pre>
Line 46: Line 41:
 
</pre>
 
</pre>
   
  +
====Setting the key layout for the current user====
----
 
  +
This is useful if the machine has multiple users who might not like this new layout.
 
 
Instead of using [HKEY_LOCAL_MACHINE\....], you can also use [HKEY_CURRENT_USER\Keyboard Layout] to make changes for one user account only.
 
Instead of using [HKEY_LOCAL_MACHINE\....], you can also use [HKEY_CURRENT_USER\Keyboard Layout] to make changes for one user account only.
  +
  +
 
'''This site has an explanation on what's going on here:'''
  +
 
http://www.annoyances.org/exec/forum/winxp/t1004806455

Revision as of 14:20, 24 March 2009

Tip 353 Printable Monobook Previous Next

created October 29, 2002 · complexity basic · author Jacques Petit · version 5.7


This will allow you to use the caps-lock key as a control key. Makes using vim in win32 much nicer in my opinion.

Place the following text into a text file with the extension *.reg and update your registry by double-clicking the file:

REGEDIT4
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00

How to create an undo registry file

I'd suggest, if the text above is copied into a file "caps2ctrl.reg", also making a file "un-caps2ctrl.reg" in which you place the following:

REGEDIT4
[-HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]

Or you can simply delete the key using the registry editor.

Swapping keys rather than replacing CAPS

The registry entry above sets the caps to ctrl. The following registry entry actually swaps the caps-lock and registry keys on your keyboard. Useful if you like using caps-lock from time to time.

REGEDIT4
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,03,00,00,00,1d,00,3a,00,3a,00,1d,00,00,00,00,00

Setting the key layout for the current user

This is useful if the machine has multiple users who might not like this new layout. Instead of using [HKEY_LOCAL_MACHINE\....], you can also use [HKEY_CURRENT_USER\Keyboard Layout] to make changes for one user account only.


This site has an explanation on what's going on here:

http://www.annoyances.org/exec/forum/winxp/t1004806455