Change Structured Text Editor preferences
Use the
Structured Text Editor
category in the Workstation Options
dialog box to configure the Structured Text Editor
options.To change structured text editor preferences:
- SelectTools>Optionsto open theWorkstation Optionsdialog box.
- Select theStructured Text Editorcategory.
- To hide or display line numbers, clear or selectShow Line Numbers. Line numbers are displayed by default.
- To enable or disable automatic outlining, clear or selectAutomatic Outlining. Automatic outlining is enabled by default.Outlining creates a collapsible outline segment when a line starts withif,while,repeat,for, andcase, and ends with the matching end construct, such asend_if.
- To enable text completion suggestions, selectShow Completion Prompt when Typing. When typing in the editor, a list of possible completion options appears. Double-click the item to insert.Show Completion Prompt when Typingis enabled by default.
- To display or hide tag and parameter values in the editor, select anInline Value Displayoption.
- Do Not Showhides tag and parameter values in the editor. This is the default setting.
- Show When Monitoring Onlinedisplays values only when online with the controller.
- Show Alwaysdisplays values online and offline.
- To set or turn off the indentation of new lines in the editor, select an indentation option.Smartindentation is selected by default.
- Noneturns off automatic indentation. When pressingEnter, the cursor is placed at the far left of the new line, with no indentation.
- Blocksets the indentation for the new line to the same indent as the preceding line.
- Smartenables indentation based on keywords such asif,end_if,else,repeat, anduntil. When pressingEnterfor a new line following a keyword, the new line is indented or outdented one tab more than the preceding line. When pressingEnterat the end of a line that does not contain a keyword, the indent matches the indent for the preceding line.
- Under theTabsheading, configure the following parameters:
- InTab Size, click the number of spaces for each tab to represent.The number applies to all tabs in all of the structured text routines. The default tab size value is 4.
- To create spaces instead of tabs when pressing the Tab key on a keyboard, clickInsert Spaces.
- To enter a regular tab when you pressing the Tab key, clickKeep Tabs.TIP:All tabs remain the same if switching modes. Also, if changing the tab size, all tabs change to the new size. Tabs that are entered as spaces remain at the current size.
- To open a text box that includes the header text to be automatically added to the beginning of new Structured Text routines, selectInclude Header on Create.The text box is pre-populated with information blocks: <Company Information>, <Developer Name>, <Routine Name>, <Description>, and <Date>.The blocks are filled in automatically from the company name provided when theLogix Designerapplication is installed, the name of the user who created the routine, the routine name and description, and the current date. However, if you replace one of the information blocks with text that you type, that information block is not automatically updated. For example, if you replace <Routine Name> with Routine A, then Routine A appears in every header.You can also change the layout of the header, including the placement or order of the information blocks.
- SelectApplyto save the header text.
- SelectOKto accept all the changes made to the preferences and close theWorkstation Optionsdialog box.
Provide Feedback