| |||
| Home > System Canvas Reference > Overview of System Canvas > Workspace windows | |||
The workspace window is the large pane on the left side of the application window.
Use the workspace views to display and edit the graphical representation of a system the LISA code for the components.
Components can be hierarchical system components or single components that do not have any sub components or internal connections.
The workspace window has two tabs at the bottom of the window:
Displays the LISA source code of the component.
The workspace can also display other text files. See Open File dialog.
The Source view is a fully-featured source text editor that includes the following:
Similar operation to common Windows text editors.
Standard copy and paste operations on selected text are supported. Text copied from the Source view can be pasted into another System Canvas text field or into an external text editor.
Undo/redo operations are enabled. Text changes can be undone by using Ctrl-Z or Edit → Undo. Text changes can be repeated by using Ctrl-Y or Edit → Redo.
Syntax highlighting is provided for LISA, C++, HTML,
Makefiles, project (*.sgproj) and repository
(*.sgrepo) files.
Auto-indenting and brace matching is provided. Indenting is done by using four spaces rather than tab characters.
Auto-completion for LISA source. If you type a delimiter
such as “.” or “:”, a list
box with appropriate components, ports or behaviors for the context
is shown. Master and slave ports are indicated by icons.
Call hint functionality is included. If you type
a delimiter such as “(“, a tooltip is displayed
with either a component constructor or behavior prototype, depending
on the context. Call hints are enabled if tooltips are enabled in
the Appearance section of the Preferences dialog. See Preferences dialog.
Lexical information for auto-completion and call hint functionality is updated every time a LISA file is parsed. This occurs, for example, when switching between the Source and Block Diagram.
Displays the graphical representation of the component. It enables adding components, connections between components, and ports to the displayed component. Add labels to the diagram to provide comments.
Displaying the block diagram fails if:
the file is not written in LISA
the syntax of the LISA file is incorrect
the LISA file contains more than one component
the LISA file contains a protocol.
The Block Diagram view supports copy and paste operations on selected components, connections, labels, and self ports. Either:
use the cursor to draw a bounding rectangle around the box
press and hold shift while clicking on the components to copy.
Component instance names are changed if the component is copied. Connections are only copied if both ends of the connection are copied.
If the system is changed in the Source view, the change is immediately reflected in the Block Diagram view. If a change is made in the Block Diagram view, it is immediately reflected in the Source view.
For each open component, or other open file, a new workspace tab is created at the top of the Workspace window. The name of the file shown in the workspace tab. The status of the file is indicated by:
an asterisk is displayed behind the name if the file is modified
a question mark behind the filename if the file is not part of the project.
Click the right mouse button in the workspace to open the context menu for that view.
The context menu of the Source tab contains items for common text operations:
Cancel last action.
Cancel Undo. Repeat the action that was undone.
Cut selected text.
Copy selected text.
Paste text from global clipboard.
Delete selected text.
Selects all text in the window.
The context menu for the Block Diagram tab has the following entries:
This item opens a new workspace tab for the selected component.
Deletes the component or connection, depending on the item the mouse pointer was positioned when activating the context menu
Adds a port to the component in the active workspace.
Mirrors the graphical object representing the port.
If a port array is selected, this option is enabled. Select it to display all of the individual port elements. Port arrays with eight or fewer elements are expanded by default.
Ports with a large number of elements might expand so that all elements appear on top of one another. Click and drag to move the individual port elements to separate locations. Alternatively, collapse the port, increase the component size, then expand the port again.
If a port array is selected, this option is enabled. Select it to hide the individual port elements and only display the top-level port name. Port arrays with more than eight elements are collapsed by default.
If a port is selected, this option is enabled. Select it to hide only the selected port.
If a port is selected, this option is enabled. Select it to hide ports that have not yet been connected to other ports.
This option hides all ports that use a specified protocol. Select the protocols to filter from the displayed Show/Hide Connection Types dialog.
Shows all ports of the component.
If a connection is selected, this option is enabled. If selected, the connection line is redrawn.
Opens a dialog that lists the object properties.