Main Content

Keyboard Shortcuts and Mouse Actions for Simulink Modeling

Keyboard shortcuts and mouse actions can help you efficiently model systems in Simulink®. To open this page from a model, use Shift + ? or click the Keyboard Shortcuts button on the navigation bar.

Note

The following keyboard shortcuts are based on Windows®. On Mac keyboards, use command (⌘) instead of Ctrl.

Perform File and Clipboard Operations

TaskShortcut
Open modelCtrl + O
Create modelCtrl + N
Print modelCtrl + P
Save all modified models in current model hierarchyCtrl + S
Save current referenced modelCtrl + Shift + S
Close modelCtrl + W
CutCtrl + X
PasteCtrl + V
DuplicateCtrl + C, Ctrl + V
UndoCtrl + Z
RedoCtrl + Y
Find search stringCtrl + F

Zoom, Scroll, and Change Current Window

TaskAction
Fit diagram to screen Spacebar
Zoom inCtrl + +
Zoom outCtrl + -
Zoom to 100%Ctrl + 0 or Alt + 1
Zoom with scroll wheel

Scroll wheel

Ctrl + scroll wheel when Scroll wheel controls zooming is cleared

Zoom in on objectDrag the Zoom button from the palette to the object.
Scroll

Spacebar + drag.

Scroll wheel + drag.

Change tabsCtrl + Shift + Tab
Go to previous windowAlt + Tab

Navigate Model Hierarchy

TaskShortcut
Open

Double-click.

Enter

Go to parent of current subsystem or referenced modelEsc
Look under block maskCtrl + U
For linked blocks, go to library of parent blockCtrl + L
Open the Model ExplorerCtrl + H

Modify Block Diagram Contents

TaskAction
Insert block at current location

Double-click and start typing the block name, then select the block from the menu.

Ctrl + . (period) twice and start typing the block name, then use the down arrow key to select the block from the menu and Enter to insert the block.

On AZERTY keyboards, use Ctrl + Shift + . (period) instead of Ctrl + . (period).

Get prompted for suggested block based on contextDouble-click the end of a line drawn from an existing block, then select a suggestion from the list or start typing to select one from the library.
Open the Library BrowserCtrl + Shift + L
Insert annotation at current location

Double-click and type the annotation content, then select the annotation option.

Ctrl + . (period) twice and type the annotation content, then use the down arrow key to select the annotation option and Enter to insert the annotation.

On AZERTY keyboards, use Ctrl + Shift + . (period) instead of Ctrl + . (period).

Copy selected objects

Drag objects with the right mouse button.

Ctrl + drag.

Copy selected objects between Simulink Editor windowsDrag objects between windows.
Delete selected objectsDelete or Backspace

Select Objects

Objects include blocks, signal lines, signal labels, and annotations. You cannot select lines and ports with the arrow keys.

TaskAction
Select an object and clear selection from other objects

Click.

Arrow keys (M to toggle between moving selection and moving objects)

Select multiple adjacent objects

Drag from empty position.

Shift + arrow keys

Select multiple objects that are not adjacent

Shift + click.

Ctrl + arrow keys to change the current object, Ctrl + spacebar to add the current object to the selection

On macOS, to add the current object to the selection, use command + shift + spacebar or shift + spacebar.

Select all blocks, lines, and annotationsCtrl + A

Modify Objects

TaskShortcut
Set main parameter for selected blockAlt + Enter
Open or hide the Property InspectorCtrl + Shift + I
Connect blocks

Click a port, then click the port you want it to connect to.

Select the first block, then Ctrl + click a second block.

Drag from port to port.

Click a port and hold Shift as you connect to the next port. Hold Shift to make multiple, consecutive connections.

Branch line

Click a port, move the cursor near the line you want to branch, and then click after you see the preview.

Select a line, move the cursor toward the element you want to connect with, and then click the port.

Ctrl + drag line.

Right mouse button + drag.

Add ports to blocks that take multiple inputs

Drag toward the port from a compatible block or signal line.

Drag from the edge of the block that you want to add the port to.

Click the edge of the port, and then drag.

Click the edge of the port, move the cursor over the signal type — signal, bus, or connector — from the menu, and drag.

Comment through blockCtrl + Shift + Y
Comment out or uncomment blockCtrl + Shift + X
Disconnect blockShift + drag block.

Name Objects

TaskAction
Rename selected object

Click or double-click the label.

Select the object and use F2.

On Mac keyboards, you can use command + return instead of F2.

Name signal lineDouble-click the signal and type its name.
Display name on branch of a named signal lineDouble-click the branch.
Name every branch of a signal Right-click the signal, select Properties, and use the dialog box.
Delete signal label and nameDelete characters in the label, or delete the name in Signal Properties dialog box.
Delete signal label only Right-click the label and select Delete Label.
Copy signal labelCtrl + drag the signal label.

Modify Block Diagram Appearance

TaskAction
Move any object, including signal labelsDrag object.
Move selected blocks and annotations

Arrow keys (M to toggle between moving selection and moving objects)

Resize block, maintaining ratio of width and heightShift + drag handle.
Resize block from the centerCtrl + drag handle.
Route lines around blocksShift + drag while drawing.
Rotate blocks clockwiseCtrl + R
Rotate blocks counterclockwiseCtrl + Shift + R
Flip blocksCtrl + I
Create subsystem from selectionCtrl + G
Create subsystem or area from empty selection

To create the highlighted option, which you can change by using the arrow keys or mouse:

  • Click inside the selection box.

  • Press Enter.

Press the number key associated with an option.

Change signal label fontSelect the signal line (not the label), then on the Format tab, click the Font Properties button arrow, then click Fonts for Model.
Mask blockCtrl + M
Refresh Model blocksCtrl + K

Perform Actions

TaskShortcut
Perform generic action

Double-click, select the Actions tab, and start typing the action name or description, then select the action from the menu.

Ctrl + . (period) and start typing the action name or description, then use the down arrow key to select the action and Enter to perform it.

On AZERTY keyboards, use Ctrl + Shift + . (period) instead of Ctrl + . (period).

Perform context-sensitive action

Select object before opening action menu.

Update, Simulate, and Generate Code for Models

TaskShortcut
Open Configuration Parameters dialog boxCtrl + E
Update modelCtrl + D
Start simulationCtrl + T
Stop simulationCtrl + Shift + T
Build model (for code generation)Ctrl + B

Debug Models

TaskShortcut
StepF10
Step inF11
Step outShift + F11
RunF5
Set or clear breakpointF12

See Also

|

Related Topics