MacBook Caps Lock Delay

Faulty by design.
Full speed typing is not supported on the MacBook caps lock key. You have to hold it down longer than other keys, thus reducing overall typing speed.

Is there any way to fix this?

[Edit: 29th December 2011]

I’ve continued to be bothered by this problem, and it seems that very many other people have also too.

Apple has another official announcement, confirming that this behaviour is intentional.

I was hacking around with Capster to see if I could modify it to display a ghosted icon in the centre of the screen indicating the state of the caps lock key. This is a bit of overkill for a workaround, so I figured there must be an easier solution.

The community has a couple of solutions, the first of which involves updating your keyboard firmware. I haven’t tried this as the following System Preferences solution works for me:

  1. Open System Preferences
  2. Click Keyboard
  3. Click Modifier Keys…
  4. Select your keyboard from the Select keyboard: list.
  5. Set the Caps Lock Key: to No Action.
  6. Press OK.
  7. Ensure your Caps Lock no longer works on your keyboard.
  8. Click Modifier Keys… again.
  9. Set the Caps Lock Key: to Caps Lock.
  10. Press OK.

Unfortunately this doesn’t survive a log out / in.

I used fseventer to monitor what changes when using System Preferences, and it’s a file in the following location,

~/Library/Preferences/ByHost

The file name includes some kind of long hex ID, using this format, where the numbers in 8-4- etc. indicate how many hex characters there are,

.GlobalPreferences.8-4-4-4-12.plist

We can see the differences between when the plist file is saved with Caps Lock turned to nothing and turned to its default state:

< <key>com.apple.keyboard.modifiermapping.1452-567-0</key>
< <array>
< <dict>
< <key>HIDKeyboardModifierMappingDst</key>
< <integer>-1</integer>
< <key>HIDKeyboardModifierMappingSrc</key>
< <integer>0</integer>
< </dict>
< </array>

This should be possible to automate by

$ defaults -currentHost read -g

$ defaults -currentHost find com.apple.keyboard.modifiermapping
Found 1 keys in domain ‘Apple Global Domain’: {
“com.apple.keyboard.modifiermapping.1452-567-0” = (
{
HIDKeyboardModifierMappingDst = “-1”;
HIDKeyboardModifierMappingSrc = 0;
}
);
}

$ defaults -currentHost read “Apple Global Domain” “com.apple.keyboard.modifiermapping.1452-567-0”
(
{
HIDKeyboardModifierMappingDst = “-1”;
HIDKeyboardModifierMappingSrc = 0;
}
)

$ defaults -currentHost write “Apple Global Domain” “com.apple.keyboard.modifiermapping.1452-567-0” -dict HIDKeyboardModifierMappingDst -1 HIDKeyboardModifierMappingSrc 0

defaults write com.companyname.appname ‘{ “Default Color” = (255, 0, 0);
“Default Font” = Helvetica; }’;

defaults write somedomain preferenceKey -array element1 element2 element3

-array-add Allows the user to add new elements to the end of an array for a key which has an array as its value. Usage is
the same as -array above. If the key was not present, it is created with the specified array as its value.

defaults write somedomain preferenceKey -dict key1 value1 key2 value2

I’m able to see the setting by running,

defaults -currentHost read -g

I’m able to delete the setting by running,

$ defaults -currentHost delete “Apple Global Domain” com.apple.keyboard.modifiermapping.1452-567-0

However, this doesn’t actually change the system behaviour.

[Edit: 9th January 2012]

My current solution appears to survive logout.

System Preferences > Keyboard > Modifier Keys…” -> Caps Lock Key: No Action.

KeyRemap4MacBook V7.5.0:

Change Key -> For PC Users -> Change PC Application Key -> Application Key to Caps Lock

PCKeyboardHack V7.2.0:

Settings -> Caps Lock -> Change Caps Lock -> Keycode 110

Advertisements

3 thoughts on “MacBook Caps Lock Delay

  1. heh never noticed that until I saw that post since I don’t use caps lock often, you must have an amazing type speed 🙂

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s