Block commenting is a feature that allows the user to quickly comment or uncomment selected blocks of code.
Block indenting allows the user to change the indentation of a selected block of code.
Both of these features work for code that is highlighted. If any portion of a line is highlighted, the feature works on the entire line. If there is no highlighted code, commenting or indenting will work on the single line where the cursor resides.
The controls to comment or uncomment code are most easily accessible from the "Text Editor" toolbar.
The toolbar is enabled by selecting it from the
The comment buttons look like this:
The left hand
button does commenting, and the right hand button does uncommenting. If the mouse is hovered over a
button, a tooltip will appear that describes that button action. Block commenting can also be
controlled from the
The comment will always begin in column 1, and the "!" character is used to signify that comment line. Block commenting works the same way for fixed format and free format source code. The commenting operation will cause an additional comment character to be added to comment lines.
Block uncommenting only works for whole-line comments, it will not uncomment trailing comments (comments appearing after code). In free source form, the uncommenting operation ignores leading white space characters. When fixed source form code is uncommented, any comments beginning with the characters "!", "c", "C", or "*" in column 1 are uncommented. If a line beginning with one of these characters is uncommented and then recommented, the new comment will begin with the "!" character.
Block uncommenting removes a single comment character at a time, so if a line starts with "!!", after an uncommenting operation, the line will contain "!". When a line is uncommented, the comment character is removed, it is not replaced with a blank character. Any lines that are selected for uncommenting, but are not comment lines are unaffected by the uncommenting operation.
The controls to indent code are also accessed from the "Text Editor" toolbar.
The indent buttons look like this:
The arrows in the
button indicates which way the code block will be moved. If the mouse is hovered over a
button, a tooltip will appear that describes that button action. Block indenting can also be
controlled from the
By default the indent size is 4 spaces. The number of spaces can be changed with the