Disabling f keys in certain applications

Discussion in 'macOS' started by Colecf, Mar 22, 2011.

  1. Colecf macrumors newbie

    Oct 11, 2010
    I was wondering if I could disable the special function for f11 when in a certain application. (minecraft specifically) F11 is the key for Minecraft to enter full-screen mode which I like to do, but the volume down takes presidence so I have to hold down fn and press f11.

    Is there a way to disable this only when in minecraft? Volume controls are still valuable to me when doing other things.
  2. GGJstudios macrumors Westmere


    May 16, 2008
    System Preferences > Keyboard
    ScreenCap 1.png
    It's system-wide, but easy to toggle on and off, as you need it.
  3. Colecf, Mar 22, 2011
    Last edited: Mar 22, 2011

    Colecf thread starter macrumors newbie

    Oct 11, 2010
    I guess that works. I knew about this, but was wondering if there was a way for it to auto-toggle in certain applications.

    EDIT: I guess my next question would be, can I run an applescript or something similar when a particular application gets opened, closed, selected, or deselected?
  4. larkost macrumors 6502a

    Oct 13, 2007
    You have not looked at the Keyboard panel enough, look in the Keyboard Shortcuts" section. There is a "+" button. Click on it, and you should be able to figure it out from there. It can be a bit of a pain, but it works.
  5. c1phr macrumors 6502

    Jan 8, 2011
    There is indeed an Apple Script! I use it all the time for Photoshop.

    The below code might not copy and paste over properly, so I've included a download link as well.

    http://dl.dropbox.com/u/3760856/Toggle Function Keys.scpt

    tell application "System Preferences"
    	set current pane to pane "com.apple.preference.keyboard"
    	tell application "System Events"
    		tell application process "System Preferences"
    			get properties
    			click radio button "Keyboard" of tab group 1 of window "Keyboard"
    			click checkbox "Use all F1, F2, etc. keys as standard function keys" of tab group 1 of window "Keyboard"
    		end tell
    	end tell
    end tell

Share This Page