How to increase the key repetition rate outside the OS?

I have a bad habit of using the arrow keys on my keyboard to go to the source code. This is what I have been doing for 15 years, and this, of course, means that my navigation speed is limited by keyboard speed. Both on Vista and OS X (I download the MacBook twice), I have my key repeat rate, which has completely changed. But in Visual Studio and other applications, the speed is still much slower than I would prefer.

How to speed up key repetition speed in Visual Studio and other text editors?

+46
windows visual-studio keyboard macos
Oct 05 '08 at 1:33
source share
15 answers

On Mac OS X, open the Global Settings tab.

open ~/Library/Preferences/.GlobalPreferences.plist 

Then change the KeyRepeat field. Smaller numbers will speed up your cursor speed. At least 2 will be set in the settings dialog box, so if you go to 0 or 1, you will get a faster cursor.

I had to reboot for this to take effect.

+26
Jan 9 '09 at 19:54
source share

On Windows, you can set this using a system call ( SystemParametersInfo(SPI_SETFILTERKEYS,...) ).

I wrote a utility program for myself: keyrate <delay> <repeat> .

Github repository .

Full source in case the link goes away:

 #include <windows.h> #include <stdlib.h> #include <stdio.h> BOOL parseDword(const char* in, DWORD* out) { char* end; long result = strtol(in, &end, 10); BOOL success = (errno == 0 && end != in); if (success) { *out = result; } return success; } int main(int argc, char* argv[]) { FILTERKEYS keys = { sizeof(FILTERKEYS) }; if (argc == 1) { puts ("No parameters given: disabling."); } else if (argc != 3) { puts ("Usage: keyrate <delay ms> <repeat ms>\nCall with no parameters to disable."); return 0; } else if (parseDword(argv[1], &keys.iDelayMSec) && parseDword(argv[2], &keys.iRepeatMSec)) { printf("Setting keyrate: delay: %d, rate: %d\n", (int) keys.iDelayMSec, (int) keys.iRepeatMSec); keys.dwFlags = FKF_FILTERKEYSON|FKF_AVAILABLE; } if (!SystemParametersInfo (SPI_SETFILTERKEYS, 0, (LPVOID) &keys, 0)) { fprintf (stderr, "System call failed.\nUnable to set keyrate."); } return 0; } 
+65
Jun 15 2018-12-18T00:
source share

Many times I want to center a function in my window. Scrolling is the only way. In addition, Ctrl-left / right can still be slow in code where there are many characters other than a word. I also use a keyboard. I have a few questions for me. One, it sometimes uses the default speed instead of the actual value that I set. Another sometimes ignores the initial delay. I still find this very useful. They said that 4 years ago they released the source after 6 months ... :(

Well, at the suggestion of someone that changed the HCU \ ... \ Keyboard Response, this works well for me.

 [HKEY_CURRENT_USER\Control Panel\Accessibility\Keyboard Response] "AutoRepeatDelay"="250" "AutoRepeatRate"="13" "BounceTime"="0" "DelayBeforeAcceptance"="0" "Flags"="59" 

AutoRepeat Windows standard delay. 13 ms (77 char / s). Do flags turn on FilterKeys? These values ​​are read at login. Remember to go out and come back for this to take effect.

+29
Sep 01 '10 at 17:29
source share

On Windows, open regedit.exe and go to HKEY_CURRENT_USER\Control Panel\Keyboard . Change KeyboardSpeed ​​to your liking.

+8
Oct 05 '08 at 4:59
source share

I use KeyboardKing on my PC. This is a free program, and it can increase the repetition rate to 200, which is quite enough. I recommend setting the High process priority to even smoother runs and fewer “re-locks” that occur once and are very annoying. With high priority, it works great.

No one understands why we are moving along the arrows. That's funny.

+8
Apr 11 '09 at 6:44
source share

For what it's worth, Visual Assist has the ability to double the effective key movements in Visual Studio that I use all the time.

+6
07 Feb '09 at 21:46
source share

As mentioned above, on Mac OSX internally there are two parameters regarding the keyboard repetition rate: "KeyRepeat" and "InitialKeyRepeat". Usually they are controlled from the system settings, where they are called “Key Repeat Rate” and “Delay to Repeat”.

The ranges available from the system settings are as follows:

 InitialKeyRepeat |--------------|-----------------| off (30000) long (120) short (25) KeyRepeat |-------------------------------| slow (120) fast (2) 0.5 char/s 33 char/s 

The numerical values ​​are likely to be 15 ms factors. Fortunately, they can be set outside of the predefined limits in "GlobalPreferences.plist". I found the following values ​​convenient for myself:

 InitialKeyRepeat = 15 --> 225 ms KeyRepeat = 1 --> 15 ms or 66 chars/s 
+5
Jun 27 '09 at 7:20
source share

I do not know how to accelerate beyond the limit, but I know how to skip further in one press. My knowledge is only on Windows, since I do not have a Mac for this. Ctrl + Arrow skips a word, and depending on the editor, it may just skip to the next section of spaces. You can also use Ctrl + Shift + Arrow to select a word in any direction.

+3
Oct 05 '08 at 1:38
source share

I like to work only on the keyboard. What for? Because when you use a mouse, you have to grab it. Loss of time.

On the other hand, it sometimes seems that every application has built-in built-in keyboards. Do not talk about BIOS properties or OS settings. Therefore, I put together short keys that can be quite quick (i.e., you type ctrl-right (arrow) directly to the right faster than holding your finger to the right (arrow) :).

Here are some keyboard shortcuts that I consider the most valuable (works on Windows, I'm not sure about OSX):

 ctrl-right: Go to the end of the previous/the next word (stated before) ctrl-left: Go to the beginning of the previous/the word before (stated before) ctrl-up: Go to the beginning of this paragraph (or to the next paragraph over this) ctrl-down: Go to the end of this paragraph (or to the next paragraph after this) ctrl-pos1: Go to the beginning of the file ctrl-end: Go to the end of the file 

All this can be combined with the shift key, so that when you select text, text will be selected. Now let go of the weirder things:

 alt-esc: Get the actual application into the background ctrl-esc: This is like pressing the "start-button" in Windows: You can navigate with arrow keys or shortcuts to start programs from here ctrl-l: While using Firefos this accesses the URL-entry-field to simply type URLs (does not work on stackoverflow :) ctrl-tab, ctrl-pageup ctrl-pagedwn Navigate through tabs (even in your development environment) 

So these are the most used shortcuts that I need during programming.

+3
05 Oct '08 at 2:46
source share

For OSX, the KeyRemap4MacBook kernel extension will allow you to fine-tune all kinds of keyboard parameters, including the key repetition rate (I set minus 15 ms, it works well).

+3
01 Sep '10 at 11:32
source share

On a Mac, this is an arrow option to skip a word and options + shift + arrow to select. The + arrow command is skipped to the end or beginning of a line or the end or beginning of a document. There are also up, down, down, start and end buttons;) shift shift is also held.

+1
Oct 05 '08 at 2:26
source share

It seems you cannot do it easily in Windows 7.

When you press and hold the button, the speed is controlled by the Windows registry key: HCU-> Control Panel-> Keyboard-> Keyboard Delay.

By setting this parameter to 0, you will get the maximum repeat speed. The drama is that you cannot fall below 0 if the repetition rate is still slow for you. 0-delay means that the repeated delay is 250 ms. But the delay of 250 ms is still slow as hell. See this: http://technet.microsoft.com/en-us/library/cc978658.aspx

You can still go to Accessibility, but you should be aware that these options will help people with disabilities use their keyboard, rather than helping them quickly type geeks. They will NOT help. Use Linux, they tell you.

I am using a hardware solution for Windows. Find specific drivers for your keyboards or try modifying existing ones.

+1
Apr 14 '12 at 13:50
source share

Although the question is several years old, I still come across the same question from time to time on several different developer sites. Therefore, I thought that I could introduce an alternative solution that I use for my daily work with developers (since the Windows registry settings never worked for me).

Below is my little Autorepeat-Script (~ 125 lines), which can be launched using AutoHotkey_L (the disadvantage is that it only works under Windows, at least Vista 7, 8.1):

 ; ==================================================================== ; DeveloperTools - Autorepeat Key Script ; ; This script provides a mechanism to do key-autorepeat way faster ; than the Windows OS would allow. There are some registry settings ; in Windows to tweak the key-repeat-rate, but according to widely ; spread user feedback, the registry-solution does not work on all ; systems. ; ; See the "Hotkeys" section below. Currently (Version 1.0), there ; are only the arrow keys mapped for faster autorepeat (including ; the control and shift modifiers). Feel free to add your own ; hotkeys. ; ; You need AutoHotkey (http://www.autohotkey.com) to run this script. ; Tested compatibility: AutoHotkey_L, Version v1.1.08.01 ; ; (AutoHotkey Copyright © 2004 - 2013 Chris Mallet and ; others - not me!) ; ; @author Timo Rumland <timo.rumland ${at} gmail.com>, 2014-01-05 ; @version 1.0 ; @updated 2014-01-05 ; @license The MIT License (MIT) ; (http://opensource.org/licenses/mit-license.php) ; ==================================================================== ; ================ ; Script Settings ; ================ #NoEnv #SingleInstance force SendMode Input SetWorkingDir %A_ScriptDir% ; Instantiate the DeveloperTools defined below the hotkey definitions developerTools := new DeveloperTools() ; ======== ; Hotkeys ; ======== ; ------------------- ; AutoRepeat Hotkeys ; ------------------- ~$UP:: ~$DOWN:: ~$LEFT:: ~$RIGHT:: DeveloperTools.startAutorepeatKeyTimer( "" ) return ~$+UP:: ~$+DOWN:: ~$+LEFT:: ~$+RIGHT:: DeveloperTools.startAutorepeatKeyTimer( "+" ) return ~$^UP:: ~$^DOWN:: ~$^LEFT:: ~$^RIGHT:: DeveloperTools.startAutorepeatKeyTimer( "^" ) return ; ------------------------------------------------------- ; Jump label used by the hotkeys above. This is how ; AutoHotkey provides "threads" or thread-like behavior. ; ------------------------------------------------------- DeveloperTools_AutoRepeatKey: SetTimer , , Off DeveloperTools.startAutorepeatKey() return ; ======== ; Classes ; ======== class DeveloperTools { ; Configurable by user autoRepeatDelayMs := 180 autoRepeatRateMs := 40 ; Used internally by the script repeatKey := "" repeatSendString := "" keyModifierBaseLength := 2 ; ------------------------------------------------------------------------------- ; Starts the autorepeat of the current captured hotkey (A_ThisHotKey). The given ; 'keyModifierString' is used for parsing the real key (without hotkey modifiers ; like "~" or "$"). ; ------------------------------------------------------------------------------- startAutorepeatKeyTimer( keyModifierString ) { keyModifierLength := this.keyModifierBaseLength + StrLen( keyModifierString ) this.repeatKey := SubStr( A_ThisHotkey, keyModifierLength + 1 ) this.repeatSendString := keyModifierString . "{" . this.repeatKey . "}" SetTimer DeveloperTools_AutoRepeatKey, % this.autoRepeatDelayMs } ; --------------------------------------------------------------------- ; Starts the loop which repeats the key, resulting in a much faster ; autorepeat rate than Windows provides. Internally used by the script ; --------------------------------------------------------------------- startAutorepeatKey() { while ( GetKeyState( this.repeatKey, "P" ) ) { Send % this.repeatSendString Sleep this.autoRepeatRateMs } } } 
  • Save the above code in a text file (UTF-8), for example, with the name "AutorepeatScript.ahk"
  • Set AutoHotkey_L
  • Double-click "AutorepeatScript.ahk" to enjoy the arrow keys (or put the file in the autorun folder).

(You can adjust the retry delay and speed in the script, see "User Configurable").

Hope this helps!

+1
Jan 05 '14 at 2:54 on
source share

Well, this may be obvious, but:

  • For horizontal navigation, Home (beginning of line), End (end of line), Ctrl-Left (word on the left), Ctrl-Right (word on the right) work in all editors that I know

  • For vertical navigation, also press "Up", "Down", "Ctrl-Home" (beginning of text), Ctrl-End (end of text).

Also (on the side of the note), I would like to prevent my Backspace and Delete keys from repeating, so the only way to delete (or replace) the text is to mark it first and then delete it (or enter the replacement text).

0
Oct 06 '08 at 9:59
source share

Do not move around the symbol.

In Vim (see ViEmu for Visual Studio):

  • bw - previous / next word
  • () - previous / next sentence (text with a full stop)
  • {} - previous / next paragraph (lines with separators in empty lines)
  • /? - move the cursor to the previous / next occurrence of the found text (w / set incsearch )

In addition, each of the movements takes a number as a prefix, which allows you to specify how many times to repeat the command, for example:

  • 20j - jump 20 lines down
  • 3} - three paragraphs down
  • 4w - move 4 words forward
  • 40G - move to (absolute) line number 40

The most likely equivalent ways to navigate the text in your editor. If not, you should consider switching to the best.

-2
05 Oct '08 at 4:35
source share



All Articles