Main Content

Access Frequently Used Features and Commands in Simulink

The Simulink® quick access toolbar provides access to frequently used operations and favorite commands. This toolbar is always visible, even when you navigate between different Simulink Toolstrip tabs.

The quick access toolbar has default buttons, such as Save.

To customize the quick access toolbar, you can:

  • Right-click an item in the toolstrip and select Add to Quick Access Toolbar. To remove a toolstrip item you have added, right-click the item and select Remove from Quick Access Toolbar.

  • Drag items to change their position.

  • Show item labels by right-clicking the item icon and selecting Show Label.

  • Show or hide common items by clicking the Common Controls button and selecting or clearing the corresponding check boxes.

To restore default settings for the quick access toolbar, use one of these options:

  • Right-click an item and select Restore Defaults .

  • Click the Common Controls button and select Restore Defaults.

Search for Simulink Toolstrip Actions

To search for Simulink Toolstrip actions, click the Search Toolstrip button . In the search box that appears, start typing the name or description of the toolstrip item, then select it from the quick action search menu.

The search result for "configuration p" is the Model Settings toolstrip item.

If the Search Toolstrip button is not in the quick access toolbar, click the Common Controls button and select the Search Toolstrip check box.

Alternatively, you can open the quick action search menu by double-clicking the Simulink Editor canvas and selecting the Actions tab or by pressing the Ctrl + . (period) keyboard shortcut. For more information, see Keyboard Shortcuts and Mouse Actions for Simulink Modeling.

Rerun Favorite Commands for Simulink

The Simulink quick access toolbar provides you with a place to access your favorite MATLAB® commands. Click the Favorites button to open the Favorite Commands gallery.

The gallery allows you to add favorite commands and organize them in categories.

The list of favorite commands is independent of the list of favorite commands in the MATLAB quick access toolbar.

To create a favorite command:

  1. Click New Favorite. The Favorite Command Editor dialog box opens.

  2. In the Label box, enter a name for the favorite command.

  3. In the Type box, specify whether the favorite command is a script or function. Functions run in a limited scope and receive callback information from the cbinfo variable.

  4. In the Code box, type the statements you want the favorite command to run.

  5. Set Category to an existing category from the drop-down list.

  6. Optionally, set Icon to one of the options provided or a custom icon. Custom icons must be PNG files. If you rename, move, or delete a custom icon, the icon no longer appears in the icon list, and any favorite commands that used the icon revert to the default icon.

  7. Optionally, select Add to quick access toolbar and Show label on quick access toolbar.

  8. Click OK.

  9. To run the statements in the Code box and ensure that they perform the desired actions, click the button for the new command. All the statements in the Code box of the Favorite Command Editor execute as if you ran those statements from the Command Window, although they do not appear in the Command History window.

To edit or delete a favorite command, right-click the command and choose the corresponding option.

To create a new category for your favorite commands:

  1. Click New Category. The Favorite Category Editor dialog box opens.

  2. In the Label box, enter a name for the category.

  3. Click OK.

To reorder categories, click the Move category to top and Move category to bottom buttons to the right of the category names.

To edit or delete a category, right-click the category and choose the corresponding option.

To reset the Simulink Favorite Commands gallery, use the slResetFavoriteCommands function.

Share Favorite Commands for Simulink

To export the contents of your Simulink Favorite Commands gallery to a file that you can share with team members, use the slExportFavoriteCommands function. The generated file saves the contents of the gallery, including the categories and their order.

To import favorite commands from a file, use the slImportFavoriteCommands function. During import, you can merge the imported content with existing content or completely overwrite the content of the gallery.

When you merge content:

  • Imported content appears after existing content.

  • If the category of an imported command matches an existing category, the imported command is added to the existing category.

  • Commands can have the same name and properties as each other. A command will not overwrite another command.

See Also

| |

Related Topics