3 ms·
I found this issue when using all kinds of programs, so here's a little trick using AppleScript. Put the following into a file in your home directory (I call mi
by DontGiveTwoFlux 13y ago
I found this issue when using all kinds of programs, so here's a little trick using AppleScript. Put the following into a file in your home directory (I call mine .f12Keys)
tell application "System Preferences"
activate
set current pane to pane "com.apple.preference.keyboard"
end tell
tell application "System Events"
tell application process "System Preferences"
click checkbox 1 of tab group 1 of window "Keyboard"
end tell
tell application "System Preferences" to quit
end tell
Then, put the following line into your .bash_profile.
alias f12="osascript .f12Keys"
Now whenever you need to switch the default behavior of function keys, simply open a new terminal window and type "f12". It takes my computer about half a second to execute. That's kind of the brilliance of Apple products and Cocoa. If there's something you do frequently, if it's in a GUI or otherwise, so long as it's written in Cocoa you can automate it. Yeah, most Apple users have never heard of AppleScript, but for those who use it for the little things every day, it's quite helpful.