Preferences for the Command Window

See also:

Text, Display, Accessibility, and Tab Size Preferences

To set these preferences for the Command Window, select File > Preferences and then select Command Window in the left pane of the Preferences dialog box.

Image of Preferences dialog box showing Command Window panel.

Text Display

Specify the format, that is, how output appears in the Command Window.

Numeric format.   Specify the output format of numeric values displayed in the Command Window. This affects only how numbers are displayed, not how the MATLAB software computes or saves them. The format reference page includes the list of available formats, with examples.

Numeric display.   Specify spacing of output in the Command Window. To suppress blank lines, use compact. To display blank lines, use loose. For more information, see the reference page for format.

Display

Wrap lines.   Select to make a single line of input or output in the Command Window break into multiple lines in order to fit within the current width of the Command Window. This is useful for console mode. With this option selected, an entire line is visible without scrolling, and the horizontal scroll bar does not appear because it is not needed. With this option cleared, use the horizontal scroll bar to view the entire contents of the line.

Set matrix display width to eighty columns.   When selected, MATLAB displays 80 characters of matrix output in a single row, and then continues displaying output in a new row, regardless of the width of the Command Window. Use the horizontal scroll bar if the width of the Command Window is less than 80 characters.

With the check box cleared, a row of matrix output fills the width of the Command Window, and then continues displaying output in a new row. Note that if the Wrap lines preference is also selected, and the width of the Command Window is less than 80 characters, each row of 80 characters of matrix output wraps to fit within the width of the Command Window.

To determine the number of characters and lines that will display in the Command Window, given its current size, use

get(0,'CommandWindowSize')

When the matrix display width preference is not selected, the number of characters for the width is based on the current width of the Command Window. For example, a result of 50, 25 means 50 characters will display across the Command Window, and 25 lines will display. However, with the preference selected, the result for that same size Command Window is 80, 25.

Show getting started message bar.   The message bar in the Command Window includes links to a video, demos, and information on getting started with MATLAB. If you want to remove the message bar in the Command Window, click the Close box in the right corner of the bar. If you close the message bar, you can still access the documentation and demos it linked to—for more information, see Help and Related Resources.

If you closed the message bar and want to show it again, select the Show getting started message bar check box in the Command Window Display preferences.

Image of empty MATLAB command window with getting started message bar open.

Show Function Browser button.   The Function Browser button appears to the left of the prompt in the Command Window. You use it to access the Function Browser. If you do not want the button to appear because of the space it requires, you can hide it by clearing the Show Function Browser button check box. When the button is not shown, you access the Function Browser by pressing Shift+F1 or by right-clicking in the Command Window and selecting Function Browser from the context menu. For more information about the Function Browser, see Finding Functions Using the Function Browser.

Number of lines in command window scroll buffer.   Set the number of lines maintained in the Command Window, from 1,000 to 25,000. This is the number of lines you can see when you scroll vertically. A larger buffer means you can view more lines and it provides a larger base for search features, but requires more memory.

This preference setting does not impact the number of lines you can recall when you use the up arrow key in the Command Window. Using the up arrow key, you can recall all lines shown in the Command History window, regardless of how many lines you can see in the Command Window.

Accessibility

Select this option to use the up and down arrow keys to move the cursor when it is above the command line. With this preference selected, use the Ctrl+ up arrow or down arrow key to recall statements using key bindings for Microsoft Windows and Apple Macintosh platforms, or Ctrl+P and Ctrl+N for MATLAB standard (Emacs) key bindings.

Clear this preference to use the up and down arrow keys to recall statements. Use the mouse and other features to move the cursor when above the command line.

Tab key

Tab size.   Number of spaces assigned to a tab stop when displaying output. The default is four spaces, except on UNIX[1] platforms where the default is eight spaces. This does not apply when the tab completion preference is selected.


[1] UNIX is a registered trademark of The Open Group in the United States and other countries.

  


 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS