Fonts Preferences for Desktop Tools

Setting Desktop Fonts

Use desktop font preferences to specify the font characteristics for MATLAB® desktop tools. The font characteristics are

Select File > Preferences > Fonts to set fonts for desktop tools. You can specify the font to be used by all tools that primarily display code such as the Command Window, and specify the font to be used by all other desktop tools. Or you can separately specify the font for any desktop tool.

Select the font characteristics from the lists shown. For font size, not all entries are shown. You can type in a size, including one not shown.

You can set some font options differently for printing — see Printing and Page Setup Options for Desktop Tools.

For information about making additional fonts available to MATLAB, see Making Fonts Available to MATLAB® Tools.

Image of Preferences dialog box, showing Fonts panel. Use the desktop code font and desktop text font to easily apply the same font to all tools that display code or text, respectively.

Desktop Code Font and Desktop Text Font

You specify separate font characteristics for tools that primarily display code (Desktop code font), such as the Command Window, and tools that primarily display text (Desktop text font), such as the Current Directory browser. Many users prefer that code display in a monospace font to provide better alignment, and prefer a more narrow font style for text information. With the desktop code font preference, you set just one preference to apply a monospace style to all tools that display code (except the Help and Web Browsers). Similarly, you can set just one preference to apply a text font to all desktop tools that display text.

The following illustrations show how the Editor would look using a monospace font and a proportional font. Note that a monospace font is useful when you care about alignment, but a proportional font uses less space.

Image of Editor with three lines of text in 10 point Monospaced font.

Image of Editor with three lines of text in 10 point San Serif, a proportional font.

Default Font Settings

Default settings are listed in the following table. Note that Lucida Console approximates the fixedsys font available in earlier versions of MATLAB.

Font Type

Default Characteristics and Sample

Tools Using Font Type by Default

Desktop code font

Monospaced, Plain, 10 point

Image of Monospaced font.

  • Command History

  • Command Window

  • Editor (which also applies to the Shortcuts Editor)

Desktop text font

SansSerif, Plain, 10 point

Image of proportional font.

  • Variable Editor

  • Current Directory browser (which also applies to the Path browser)

  • Help Navigator

  • HTML Proportional Text. This is the font used for noncode text in the Web browser (including, for example, HTML reports generated from cell publishing), Profiler, and Help browser display pane. While you can select the font name, you cannot change the font style (for example, to bold or italic) for HTML Proportional Text. Changes to size affect noncode and code text.

  • Workspace browser

When you change a font characteristic for Desktop code font, the characteristic takes effect for all tools that use the desktop code font. The same is true when you change a font characteristic for Desktop text font.

After changing a characteristic, a sample in the dialog box shows how it will look. Click Apply or OK to make the change take effect in the desktop tools.

See Also

Preferences

Custom Fonts Preferences

If you do not want to use the current settings for Desktop Code Font and Desktop Text Font, you can specify that a tool use the code font, the text font, or a different font. Select File > Preferences > Fonts. Click + and select Custom. The Fonts Custom Preferences pane appears.

Image of Preferences dialog box showing Custom Fonts panel.

Select a tool from the Desktop tools list. The type of font it uses, code or text, appears under Font to Use. In the illustration shown, the Command Window uses the Desktop code font, which is defined in the Fonts pane as described in the previous section.

To change the font characteristics the selected tool uses, select a different radio button. For Custom, you then specify the font characteristics for that tool.

Changing the Font — Example

This example changes the default settings (see Default Font Settings) for the desktop code font, changes the Command History font preference so that it uses the desktop text font instead of the code font, and specifies a custom font for the Current Directory browser:

  1. Change the characteristics for the desktop code font. On the Fonts pane, set the Desktop code font to Times New Roman, Plain, 14 point. Use the default for the Desktop text font, SansSerif, Plain, 10 point. Click Apply.

  2. Make the Command History window use the desktop text font. Select Fonts, click +, select Custom, and then select Command History from Desktop tools. Select the Desktop text radio button.

  3. Apply a custom font to the Current Directory browser. Select Current Directory from Desktop tools. Select the Custom radio button. Select Arial Narrow and Plain, and type 11 in the size field. Click OK.

The following table details the results of the changes.

Tool

Font Type

Font Characteristics

Command Window

Desktop code

Monotype Imaging Times New Roman® font, Plain, 14 point

Command History

Desktop text

SansSerif, Plain, 10 point

Editor

Desktop code

Times New Roman font, Plain, 14 point

Help Navigator

Desktop text

SansSerif, Plain, 10 point

HTML Proportional Text

Desktop text

SansSerif, Plain, 10 point

Current Directory

Custom

Monotype Corporation Arial® font, Plain, 11 point

Workspace

Desktop text

SansSerif, Plain, 10 point

Variable Editor

Desktop text

SansSerif, Plain, 10 point

See Also

For information about how MATLAB stores preferences and help for other preferences, see Preferences.

Antialiasing for Desktop Fonts on Linux® and UNIX® Platforms

To give the desktop a smoother appearance on Linus Torvalds Linux® and The Open Group UNIX® platforms, select the antialiasing preference on the Preference > Fonts pane. The preference apply to all fonts.

Making Fonts Available to MATLAB® Tools

On Windows platforms, desktop components (such as the Command Window and Workspace browser), figure windows, and uicontrols support only Apple TrueType® and Microsoft OpenType® fonts. Some graphics objects can render bitmapped fonts as well, such as xlabel, ylabel, title, and text.

To make a new compatible font available to MATLAB, install the font by selecting Start > Control Panel > Fonts in the Windows desktop, and then selecting File > Install New Font. Restart MATLAB so that it can use the font.

  


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