Source Editor

The Source Editor is a full-featured text editor that is integrated with the Form Editor, Explorer, compiler, and debugger. You can open the Source Editor by double-clicking an editable element. For example, double-click a Java or text object in the Explorer to open the Source Editor.

Colors in the Source Editor

Source code displayed in the Source Editor window is syntactically colored. For example, all Java keywords are shown in blue and all Java comments in light gray. Guarded blocks of Java code generated by the Form Editor has a light blue background and cannot be edited. All colors are configurable.

Modes and Insertion Point

There are two modes in the Source Editor, insert mode and overwrite mode. In insert mode, the default insertion point is a vertical bar and text that you type is inserted. In overwrite mode, the default insertion point is a solid block and text that you type replaces the existing text.

Use the Insert key to toggle between the two modes.

Whenever the insertion point in the Source Editor window is immediately after a brace, bracket, or parenthesis, the matching brace, bracket, or parenthesis is highlighted.

Tip If the Source Editor only beeps when you try to enter new text, the file is a read-only file.

Margins

The left margin displays annotation glyphs that indicate line status, such as breakpoints, the program counter, build errors, or bookmarks. The margin can also optionally display line numbers.

A faint vertical line in the Source Editor marks a suggested right margin for your text. This configurable margin is set to 80 characters from the left margin by default.

Status Line

The Source Editor status line is beneath the horizontal scroll bar. The first area of the status line shows the current line number and row number in the form line:row. The second area of the status line indicates the insertion mode (INS or OVR). The text area on the right is used for status messages.

Source Editor Tabs

If you are editing more than one file, the bottom of the Source Editor window has tabs used to view different documents. From each of these tabs, the document can be saved, closed, docked, undocked, cloned, and other actions that depend on the state of the file and the modules that are installed.

The tooltip for each tab displays more information about the file, including the type of file and the file's location. If you have multiple instances of the same file open in the Source Editor, it might be because the file is mounted in multiple places. Check the tooltip for each file's tab.

Each modified and unsaved file in the Source Editor window has an asterisk (*) after its name on its tab and in the window title. You can save a file by choosing Save from the File menu, the Source Editor window's contextual menu, or the contextual menu of the file's tab.

See also
Editing Source Files
Using Annotations
Configuring the Source Editor
Setting Fonts and Colors

Legal Notices