Change Desktop Layout
When you start MATLAB®, the desktop appears in its default layout.
By default, the desktop includes these tools.
|Toolstrip||Top of desktop|
By default, the toolstrip includes three tabs: Home, Plots, and Apps.
|Current Folder toolbar||Top of desktop underneath toolstrip|
View and change the current folder.
|Current Folder browser||Left side of desktop|
Manage files and folders in MATLAB. Actions include viewing, creating, opening, moving, and renaming files and folders in the current folder.
|Workspace browser||Right side of desktop|
View and manage the contents of the workspace in MATLAB.
In MATLAB Online™ and on systems with a lower screen resolution, MATLAB defaults to a two-column layout with the Workspace panel on the left side of the desktop, underneath the Files panel.
|Command Window||Middle of desktop|
Enter individual statements at the command line and view the resulting output.
To change the desktop layout, you can choose from a set of preconfigured desktop layouts or you can create your own layout by hiding, minimizing, and undocking individual tools. You also can change the layout of documents within a tool by undocking, reordering, or tiling them. Then, you can save your layouts and reuse them again at a later time.
MATLAB Online Desktop
In MATLAB Online, you can use the sidebars on either side and on the bottom of the desktop to access desktop tools and change the desktop layout. Each sidebar shows the tools, such as the Workspace panel, Files panel, or Command Window, that are docked in that area of the desktop. If there are no tools docked in an area of the desktop, the sidebar for that area is hidden.
You can use the sidebars to show and hide tools, group them together, and move them from one location to another. To show or hide a tool, click its icon in the sidebar. To show and hide multiple tools together, group them by dragging one of the tool icons next to another tool icon. To move a tool to a different location on the desktop, drag the tool or the icon for the tool to the new location.
Select Preconfigured Layout
MATLAB provides a set of preconfigured desktop layouts that are optimized for certain workflows. To select a preconfigured layout, on the Home tab, in the Environment section, click Layout and select a layout. To restore the MATLAB desktop to its default layout, select Default.
For example, if you work mostly in the Command Window, select the All but Command Window Minimized option (Command Window Only in MATLAB Online) to maximize the Command Window and minimize all other tools in the desktop.
To open or show a tool that is not visible in the desktop, on the
Home tab, in the Environment section,
click Layout. Then, in the Show section,
select the desktop tool that you want to show on the desktop. You also can open some
tools programmatically using a function. For example, to open the Editor, use the
edit function. To open the Workspace browser, use the
In MATLAB Online, to show a tool that is hidden, click its icon in the sidebar. You also can show some tools by going to the Home tab, and in the Environment section, clicking the Layout button. Then, in the Layout Options section, select one or more of the options in the list. To open a tool that is not in any of the sidebars, in a sidebar, click the Open more panels button (). Then, in the Open Panel dialog box, select from the available tools. You also can right-click in a sidebar and select Open more panels.
Minimize tools in the desktop to optimize the layout while still maintaining quick access to tools that you use periodically.
To minimize the toolstrip, at the lower-right corner of the toolstrip, click the button. The toolstrip minimizes but the tabs remain visible. To restore the toolstrip, select one of the tabs to display the toolstrip, and then, in the lower right corner of the toolstrip, click the button.
To minimize other tools including the Current Folder browser, Command Window, Editor, and Live Editor, on the title bar of the tool, click the button and select Minimize. The minimized tool appears along the edge of the desktop indicated by the arrow in the Minimize icon. For example, the Minimize icon indicates that the tool minimizes to the left edge of the desktop by default. To move a minimized tool to a different edge of the desktop, drag the tool to the desired location. To open a minimized tool temporarily on the desktop, click the tool. Then, to restore the tool to its original size, double-click the tool. Alternatively, you can click the button and select Restore.
For example, to minimize the Current Folder browser, at top right of the Current Folder browser, click the button and select Minimize. The Current Folder browser minimizes to the left side of the screen.
In MATLAB Online, to minimize a tool, click its icon in the sidebar. If two or more tools are grouped together, you can minimize each individual tool by clicking the Collapse button on the left side of its title bar.
For example, if the MATLAB Online desktop is in the default layout with the Files panel and Workspace panel open on the left side of the desktop, you can hide both tools by clicking the icon group for the two tools in the left sidebar. You can minimize just the Files panel by clicking the Collapse button on the left side of its title bar.
To minimize tools that open in new windows in MATLAB Online, see Manage Windows in MATLAB Online.
To hide a tool, click the button on the title bar of a tool and select Close. You also can hide some tools by going to the Home tab, and in the Environment section, clicking the Layout button. Then, in the Show section, clear one or more of the options in the list. To hide just the title bar for all tools, clear the Panel Titles option.
In MATLAB Online, to hide a tool, click its icon in the sidebar. You also can hide some tools by going to the Home tab, and in the Environment section, clicking the Layout button. Then, in the Layout Options section, clear one or more of the options in the list.
Undock Tools and Documents
To open a tool in a separate window, undock the tool to move it outside the MATLAB desktop. To undock a tool, on the title bar of the docked tool, click the button and select Undock. Alternatively, drag the tool by its title bar to a new location outside of the MATLAB desktop. To move an undocked tool back into the desktop, at the upper right of the undocked tool, click the button and select Dock.
You also can undock individual documents within a tool, such as an individual
script file open in the Editor. To undock an individual document, right-click the
document tab and select Undock
document. Alternatively, you can click
the button on the title bar of the tool and select
tools and documents appear on the Windows® task bar, or the equivalent for your platform. Click the task bar icon
for a tool or document to make it active.
For example, if you have the file
fact.m open in the Editor, to
undock just that file, on the title bar of the Editor, click the button and select Undock
fact.m. MATLAB opens
fact.m in a separate window and leaves the
Editor docked in the desktop. To move the file back into the desktop, at the top
right of the undocked file, click the button and select Dock
fact.m. If you have multiple undocked documents and want to move
them all back into the desktop, select Dock All in
In MATLAB Online, undocking tools and documents is not supported.
Reorder and Tile Documents
When you open MATLAB documents, they open in the associated tool, such as the Editor, Live Editor, or Variables editor. Individual documents open as separate tabs within the tool. To optimize the layout of multiple documents, you can reorder or tile them.
To reorder individual document tabs within a tool, drag the tabs to a different position. To reorder document tabs alphabetically, on the View tab, in the Document Tabs section, select Alphabetize. In MATLAB Online, to alphabetize document tabs, on the title bar of the tool, click the button and select Alphabetize.
By default, the tabs appear at the top of the document. To change the position of the tabs in a tool, on the View tab, click Tabs Position and select from the available options. For example, to display tabs on the left side of the Editor instead of at the top, with the Editor open, go to the View tab, click Tabs Position, and select Left. In MATLAB Online, to change the position of the tabs in a tool, click the button, select Tabs Position, and select from the available options.
To tile documents in the Editor, Live Editor, and Variables editor, go to the View tab and in the Tiles section, select a tile option. To move a tiled document, drag the document tab to another tile. If you drag it to a tile that already contains a document, the document you are dragging covers up the other document.
For example, to view two files side by side in the Editor, go to the View tab and select the Left/Right button.
To tile documents in the Figures panel, Help browser, or web browser, at the top right of the tool, select the , , , or option button.
In MATLAB Online, to tile documents, on the title bar of the tool, click the button, select Tile All, and then select a tile option.
Save Desktop Layouts
When you end a session, MATLAB saves the current desktop layout. The next time you start MATLAB, the desktop appears as you left it.
If you alternate between two or more customized desktop layouts, you can save them
all to easily switch between them. To save a layout, on the
Home tab, in the Environment section,
click Layout, and select Save
Layout (or Save Current Layout in
Online). MATLAB stores all saved layouts in the preferences folder. MATLAB saves the current desktop layout at the end of a session in the file
To use a saved layout, on the Home tab, click Layout, and select your saved layout. To delete or rename saved layouts, select Organize Layouts. In MATLAB Online, right-click the layout and select Delete or Rename from the context menu.
Some tools, such as the Help browser, web browser, and Variables editor, do not reopen automatically, even if they were open when you ended the last session. You can use startup options to specify tools that you want to open on startup. For more information, see Specify Startup Options.