문제

Many user interface (UI) elements or dialog boxes have buttons. I would like to be able to activate a button with just the keyboard, without the mouse. How can I do this?

도움이 되었습니까?

해결책

For many dialog boxes you can select the option you want by pressing +firstletter where firstletter is the first letter of the option you want to select

다른 팁

Enable Keyboard Control of the UI

System Prefs > Keyboard > Shortcuts

Then select "All Controls" radio button at the bottom, rather than just "Text boxes and lists only".

enter image description here

Keyboard Shortcuts

  • (TAB) will move between buttons.
  • esc (ESC) is cancel.
  • space (SPACE) selects the active button (blue, outline).
  • (RETURN) is OK or the default button (blue, pulsing, filled).
  • For some dialog boxes, +first_letter will select the button with a certain first letter in the text (as pointed out by @Griffo).

To elaborate on the answers above, many (most?) dialogue boxes will have the default option in blue. Hitting will cycle between options, with a blue outline around the other button, but the default will remain blue. Hitting will always select the default, space will select whichever button is highlighted.

In this example, pressing will 'Keep .txt' and pressing space will 'Use .bak.'

Dialogue Box

+. also works for Cancel. And in some applications just pressing the initial letters works. Photoshop is one, but it's pretty common for other cross-platform applications too.

Typing +W+D is a quick way to do something like Close and don't save.

See full Keyboard Access at the bottom of the following screenshot:

Keyboard Preferences When a prompt window like the one you included appears, the selected button will be highlighted in blue.
Screenshot:

Copy dialog

Then you press the space to action that button.

Tab to move to the next dialog box. Space to select

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 apple.stackexchange
scroll top