Can I use different keyboard settings for different spaces on OS X

2

I use Microsoft remote desktop app on my Mac. Is it possible to have the keyboard settings different for the app, and for the rest of the OS? As I often put the remote app in a different space, I was wondering if different spaces can have different settings. The trouble is I need the F keys to work for software on one space and for hardware on the other.

Chander

Posted 2013-11-06T15:21:41.127

Reputation: 21

Answers

0

You could use a private.xml like this with KeyRemap4MacBook:

<?xml version="1.0"?>
<root>
  <appdef>
    <appname>RDC</appname>
    <equal>com.microsoft.rdc.mac</equal>
  </appdef>
  <item>
    <name>rdcfkeys</name>
    <identifier>rdcfkeys</identifier>
    <only>RDC</only>
    <autogen>__KeyToKey__ KeyCode::BRIGHTNESS_DOWN, KeyCode::F1</autogen>
    <autogen>__KeyToKey__ KeyCode::BRIGHTNESS_UP, KeyCode::F2</autogen>
    <autogen>__KeyToKey__ KeyCode::EXPOSE_ALL, KeyCode::F3</autogen>
    <autogen>__KeyToKey__ KeyCode::LAUNCHPAD, KeyCode::F4</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::KEYBOARDLIGHT_LOW, KeyCode::F5</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::KEYBOARDLIGHT_HIGH, KeyCode::F6</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::MUSIC_PREV, KeyCode::F7</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::MUSIC_PLAY, KeyCode::F8</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::MUSIC_NEXT, KeyCode::F9</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::VOLUME_MUTE, KeyCode::F10</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::VOLUME_DOWN, KeyCode::F11</autogen>
    <autogen>__ConsumerToKey__ ConsumerKeyCode::VOLUME_UP, KeyCode::F12</autogen>
    <autogen>__KeyToKey__ KeyCode::F1, KeyCode::BRIGHTNESS_DOWN</autogen>
    <autogen>__KeyToKey__ KeyCode::F2, KeyCode::BRIGHTNESS_UP</autogen>
    <autogen>__KeyToKey__ KeyCode::F3, KeyCode::EXPOSE_ALL</autogen>
    <autogen>__KeyToKey__ KeyCode::F4, KeyCode::LAUNCHPAD</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F5, ConsumerKeyCode::KEYBOARDLIGHT_LOW</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F6, ConsumerKeyCode::KEYBOARDLIGHT_HIGH</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F7, ConsumerKeyCode::MUSIC_PREV</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F8, ConsumerKeyCode::MUSIC_PLAY</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F9, ConsumerKeyCode::MUSIC_NEXT</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F10, ConsumerKeyCode::VOLUME_MUTE</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F11, ConsumerKeyCode::VOLUME_DOWN</autogen>
    <autogen>__KeyToConsumer__ KeyCode::F12, ConsumerKeyCode::VOLUME_UP</autogen>
  </item>
</root>

Lri

Posted 2013-11-06T15:21:41.127

Reputation: 34 501

0

You should install and use Karabiner. Karabiner, by default, gives you many options to remap keys on your Mac keyboard by simply checking a checkbox. While the default options are useful, they do not allow for much flexibility.

Karibiner - Standard Remappings

You can also edit a file name private.xml by clicking 'Misc & Uninstall' Tab > Custom Setting > Open private.xml.

Karabiner - Open private.xml

Using your text editor of choice (such as Sublime Text 2) you can then edit private.xml.

Specific Application Example

wynshaft

Posted 2013-11-06T15:21:41.127

Reputation: 114