QM  6.1.1
Model-Based Design Tool
Loading...
Searching...
No Matches
Working with Code Editors

Working with DiagramsSearch/Replace

QM provides an advanced text editor for working with files, as well as text-based properties in the Property Editor. Besides the usual features expected of a state-of-the-art editor, the QM text editor provides the following features:

  • Full integration with QM (Cut/Copy/Paste, Undo/Redo, Search/Replace, etc.)
  • Extended syntax highlighting for C, C++, Make, Tcl, Arduino (C++)
  • Powerful keyboard shortcuts (e.g., block-indent/unindent, brace-kiss, etc.)
Note
The appearance of the QM text editor, such as fonts and colors, can be customized by means of the QM Style Sheet.

Syntax Highlighting

The Syntax Highlighter supplied with the QM text editor has been customized to highlight the QM-specific constructs, such as:

  • the Code-Generation Directives ($declare${}, $define${}, $define1${})
  • the me->... and e->... constructs for accessing the state-machine members and event-parameters, respectively
  • the standard fixed-width integer types from <stdint.h> header file (uint8_t, uint16_t...)
Text editors in QM (File item, Property Sheet)

Key Bindings

The QM text editor provides the following key bindings (the highlighted key-bindings are arguably the most useful):

Keypress Action
Backspace Deletes the character to the left of the cursor.
Delete Deletes the character to the right of the cursor.
Tab Indent a block of text.
Shift+Tab Un-indent a block of text.
Ctrl+Delete Deletes to the end of the line.
Ctrl+K Find matching brace/parenthesis ("brace kiss").
Ctrl+C Copy the selected text to the clipboard.
Ctrl+Insert Copy the selected text to the clipboard.
Ctrl+V Pastes the clipboard text into text edit.
Shift+Insert Pastes the clipboard text into text edit.
Ctrl+X Deletes the selected text and copies it to the clipboard.
Shift+Delete Deletes the selected text and copies it to the clipboard.
Ctrl+Z Undoes the last operation.
Ctrl+Y Redoes the last operation.
LeftArrow Moves the cursor one character to the left.
Ctrl+LeftArrow Moves the cursor one word to the left.
RightArrow Moves the cursor one character to the right.
Ctrl+RightArrow Moves the cursor one word to the right.
UpArrow Moves the cursor one line up.
Ctrl+UpArrow Moves the cursor one word up.
DownArrow Moves the cursor one line down.
Ctrl+Down Arrow Moves the cursor one word down.
PageUp Moves the cursor one page up.
PageDown Moves the cursor one page down.
Home Moves the cursor to the beginning of the line.
Ctrl+Home Moves the cursor to the beginning of the text.
End Moves the cursor to the end of the line.
Ctrl+End Moves the cursor to the end of the text.
Wheel Scrolls the page vertically (the Wheel is the mouse wheel).
Alt+Wheel Scrolls the page horizontally (the Wheel is the mouse wheel).

Working with DiagramsSearch/Replace