-
-
Notifications
You must be signed in to change notification settings - Fork 1
The Command Launcher Part 2
In this command launcher post, we’ll explore some of the basic ways to use the command launcher.
To execute a menu command, simply start entering part of the menu name. Capitalization is not important. So, for example, to save the current file, enter something like "save". As you enter each character, TKE will present all of the potential matching commands in the matching list below the input field. All menu commands will be displayed in the match results using a * Menu: prefix, where the * is the name of the main menu that contains the command (to help you learn where commands are located in the menus). To execute the selected command, simply hit the RETURN key.
As you continue to use the command-launcher, it will get better in matching the command associated with the "save" keyword such that the "File Menu: Save file" command should be the top-most match when entering the keyword "save".
If you want to quickly change the syntax highlighter of the current editing buffer, simply launch the command launcher and start typing in the name of the language to use. For example, to cause the current buffer to syntax highlight according to the Tcl language, simply enter ‘tcl’ in the command launcher. Hitting the RETURN key when the "Syntax: Tcl" option is selected will change the syntax highlighter for the buffer.
As an additional hint, all of the available languages are prefixed by the string "Syntax: "; therefore, you can get a listing of all languages by entering "syntax" in the command launcher.
To try a new TKE theme, simply enter the name of the theme in the command launcher or enter the "theme" to a listing of all available themes. Hitting the RETURN key when a desired theme is selected will automatically change the UI to match the look of the selected theme.
Various language syntaxes have support for symbols which are simply searchable points within the file. For example, the Tcl syntax will make all procedures symbols. So you can view and jump to any Tcl procedure within an editing buffer by entering the ‘@’ character followed by the name of the procedure (or a fuzzy matching portion of it) and hitting the RETURN key when the desired procedure is selected.
Not all languages have parsing support for symbols so to see what if they are supported in your syntax, simply enter the ‘@’ symbol in the command launcher for the current editing buffer and see what symbols show up. If the list is empty, that syntax does not currently have symbol support defined in its syntax file. You can see the documentation for syntax files and how to add symbol support to it in the User Guide.
If you have placed any markers in the current editing buffer, you can quickly jump to one by entering the ‘,’ character, followed by the name of marker. If you created a marker without specifying a name, TKE created the buffer with the name "Marker-" followed by a unique number (starting with the number one). Selecting a marker and hitting the RETURN key will automatically jump to the marker line, positioning the cursor at the beginning of the line.
We will take a look at some more capabilities accessible via the command launcher. In the meantime, start using this invaluable tool to increase your editing prowess!