0

I'm using Cmd-Option-1 .. Cmd-Option-5 to go to different desktops, on Moutain Lion.

Besides changing my global defaults, how else could I enable the google doc shortcuts for Cmd-Option- to set a paragraph style?

I want some sort of program that will take Ctrl-Option- in chrome and send chrome Cmd-Option-num (and not change desktops).

1 Answer 1

1

The only option I can think of would be to change the default shortcuts to something like ⌃⌥⇧⌘+numbers and save this as private.xml in KeyRemap4MacBook.

<?xml version="1.0"?>
<root>
<item>
<name>test</name>
<identifier>private.test</identifier>
<autogen>--KeyToKey-- KeyCode::KEY_1, VK_OPTION | VK_COMMAND, KeyCode::KEY_1, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_2, VK_OPTION | VK_COMMAND, KeyCode::KEY_2, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_3, VK_OPTION | VK_COMMAND, KeyCode::KEY_3, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_4, VK_OPTION | VK_COMMAND, KeyCode::KEY_4, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_5, VK_OPTION | VK_COMMAND, KeyCode::KEY_5, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_6, VK_OPTION | VK_COMMAND, KeyCode::KEY_6, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_7, VK_OPTION | VK_COMMAND, KeyCode::KEY_7, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_8, VK_OPTION | VK_COMMAND, KeyCode::KEY_8, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_9, VK_OPTION | VK_COMMAND, KeyCode::KEY_9, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_0, VK_OPTION | VK_COMMAND, KeyCode::KEY_0, VK_CONTROL | VK_OPTION | VK_SHIFT | VK_COMMAND</autogen>
</item>
<item>
<name>test2</name>
<identifier>private.test2</identifier>
<only>GOOGLE_CHROME</only>
<autogen>--KeyToKey-- KeyCode::KEY_1, VK_CONTROL | VK_OPTION, KeyCode::KEY_1, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_2, VK_CONTROL | VK_OPTION, KeyCode::KEY_2, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_3, VK_CONTROL | VK_OPTION, KeyCode::KEY_3, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_4, VK_CONTROL | VK_OPTION, KeyCode::KEY_4, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_5, VK_CONTROL | VK_OPTION, KeyCode::KEY_5, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_6, VK_CONTROL | VK_OPTION, KeyCode::KEY_6, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_7, VK_CONTROL | VK_OPTION, KeyCode::KEY_7, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_8, VK_CONTROL | VK_OPTION, KeyCode::KEY_8, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_9, VK_CONTROL | VK_OPTION, KeyCode::KEY_9, VK_OPTION | VK_COMMAND</autogen>
<autogen>--KeyToKey-- KeyCode::KEY_0, VK_CONTROL | VK_OPTION, KeyCode::KEY_0, VK_OPTION | VK_COMMAND</autogen>
</item>
</root>

See the source for the keycode constants and predefined settings.

2
  • If this is done, will the Cmd-Opt-Num key still work to switch desktops? Commented Jan 15, 2013 at 10:41
  • Yeah, that's what the first group is for.
    – Lri
    Commented Jan 15, 2013 at 10:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .