Search code examples
eclipsemacosintellij-ideakeyboard-shortcuts

How to use directly function key (F1 - F9) instead of pressing fn + function key in IDE in OSX?


When I use shortcuts in any IDE (IntelliJ or Eclipse) in Mac OSX, I have to press fn + function key (F1 - F12). Is there a way avoid it so that I only have to press the function key (F1 - F12)? Meanwhile, when I'm not in IDE, I want to use my function keys as app control as usual.


Solution

  • With the new MacBook Pro touchbar, we can use simply the function key F1 - F12 in IntelliJ or Eclipse, without having to press fn + (F1 - F12).

    We can add IntelliJ or Eclipse in the following configuration: System Preferences - Keyboard

    After adding IntelliJ or Eclipse in the configuration: enter image description here

    With that configured, we can now press simply F8 to do step over when in debugger in IntelliJ, instead of pressing fn + F8.