Desktop Tools and Development Environment Previous page   Next Page

Keyboard Shortcuts (Accelerators) and Mnemonics

You can access many of the menu items using shortcut keys (sometimes called accelerators or hot keys) for your platform. For example, use the Ctrl+X shortcut to perform a cut on Windows platforms. Many of the menu items show the shortcuts. Additional standard shortcuts for your platform usually work but only one is listed with each menu item.

The keyboard shortcuts for the Command Window and Editor/Debugger also depend on settings for key bindings that you specify using preferences. For details, see Command Line Key Bindings, and Key Bindings for the Editor/Debugger in the online documentation. Instructions in the documentation specify shortcuts using the Windows Ctrl+ key convention, but with Macintosh key bindings selected, you can use the Command key instead.

You can also use mnemonics to access menu items and buttons, such as Alt+F to open the File menu. Mnemonics are listed with the menu item or button. For example, on the File menu, the F in File is underlined, which indicates that Alt+F opens the menu. In the Profiler, the R in the Run this code toolbar field is underlined, indicating that Alt+R moves the cursor to this field. Note that some versions of Windows do not automatically show the mnemonics on the menu. For example, you might need to hold down the Alt key while the tool is selected in order to see the mnemonics on the menus and buttons.

In Windows 2000, go to the Display Control Panel, select Effects, and clear the item Hide keyboard navigation indicators until I use the Alt key. See your Windows documentation for details.

Following are some general shortcuts that are not listed on menu items.

Key
Result 
Enter
The equivalent of double-clicking, Enter performs the default action for a selection. For example, press Enter while a statement in the Command History window is selected to run that statement in the Command Window.
For buttons in tools and dialog boxes, Enter executes the default button (the button with a border around it). If there is no default button, press the space bar to execute the active button (the button with a dotted outline inside it). See Default Button and Active Button (Button with Focus) for an illustration.
Escape
Cancels the current action. For example, if you select the Edit menu, the menu items display. Pressing Escape retracts the menu items. Pressing Escape in a dialog box is the same as selecting the Cancel button.
Tab
Advances to the next button or field in a tool or dialog box.
In the Command Window, completes a statement if the tab completion preference is selected.
Space bar
For buttons in tools and dialog boxes, activates the active button. See Default Button and Active Button (Button with Focus) for an illustration of selecting default and active buttons using keys.
+ or - or *
on numeric keypad
Use these keys on the numeric keypad to expand and collapse items in tree views. The Help browser Help Navigator pane and the Command History window use tree views. Use + to expand the selected item, use - to collapse the selected item, and use * to recursively expand it, meaning open all items contained in the selected item.
Alt+S
Displays the Start button menu (except on Macintosh platforms).
Alt+Y
Provides access to the current directory field in the toolbar.
Ctrl+Tab
Moves to the next open tool in the desktop, or to the next open group of tools tabbed together.
Ctrl+Shift+Tab
Moves to the previous open tool or group of tabbed tools in the desktop.
Ctrl+Page Down
Moves to the next tool within a group of tools. In a group of documents, moves to next document.
Ctrl+Page Up
Moves to the previous tool within a group of tools tabbed together. In a group of documents, moves to previous document.
Ctrl+F6
Moves to the next tool or document (only for Windows and Solaris platforms).
Ctrl+Shift+F6
Moves to the previous tool or document (only for Windows and Solaris platforms).
Alt+F4
Closes the desktop, thereby quitting MATLAB, or outside the desktop, closes the active window.

For additional shortcuts available in the various desktop tools, see the documentation for each tool. For example, see Keyboard Shortcuts in the Command Window and Keyboard and Mouse Shortcuts in the Editor/Debugger.

Go To First Letter Feature in Desktop Tool Lists

In the Current Directory browser and Command History window, you can type a letter to move directly to the next item in the list that starts with the letter you typed.

Default Button and Active Button (Button with Focus)

These illustrations demonstrate the default versus active button in a dialog box.

Image of Save and Cancel button, where the Save button has a border around it and therefore, is the default. Press the Enter key to execute the default button.

Image of OK and Cancel button, where the active button (or button with focus) is indicated by a dotted outline inside it. Press the space bar to execute the active button.

Image of OK, Cancel, and Help button, where the Help button is both the active button and the default button. In some cases, the default always changes to match the active button. Press either Enter or the space bar to execute the Help button.


Previous page  Sizing, Arranging, and Sorting Columns in Tools Selecting Multiple Items Next page

© 1994-2005 The MathWorks, Inc.