next up previous contents index
Next: Layer Table Up: Prompt Line Previous: Prompt Line   Contents   Index


Prompt Line Editing

Some commands will convert the prompt line to editing mode. In this mode, the background color changes, and text typed by the user will appear in the prompt line window. Keys pressed when the main window has focus are directed to the prompt line, so it is usually not necessary to force keyboard focus to the prompt line. In text edit mode, key bindings from the table below are available.

Prompt Line Editor Bindings
Ctrl-A Move cursor to beginning of line
Ctrl-E Move cursor to end of line
Ctrl-K Delete to end of line
Ctrl-P Paste primary selection at cursor
Ctrl-U Delete current line
Ctrl-V Paste clipboard at cursor
Left Move cursor left one character
Right Move cursor right one character
Page Down Move cursor to right by half a line, scroll if necessary
Page Up Move cursor to left by half a line, scroll if necessary
Backspace Delete previous character
Delete Delete next character
Esc Exit editing, abort operation
Enter Terminate editing

The arrow keys move the cursor back and forth, Backspace deletes the character or hypertext reference to the left of the cursor and moves the cursor to the left, and Delete deletes the object at the cursor. Ctrl-U deletes the entire line. Ctrl-K will delete the character at the cursor and all characters to the right. Ctrl-A and Ctrl-E move the cursor to the beginning or end of the line, respectively. The line will scroll to the left or right if longer that the available space, when the cursor hits the left and right boundaries. The Esc key exits edit mode, discarding the input. The Enter key exits edit mode, saving the input. The cursor can be at any position when Enter is pressed.

There is no limit on the number of characters in the string, which can be much longer than the display space. The Page Down and Page Up keys move the cursor to the right or left (respectively) by half the number of characters displayable in the prompt area, and will scroll if necessary to keep the cursor visible.

The Ctrl-P and Ctrl-V keys paste text from the primary selection and clipboard, respectively, at the cursor. Under Windows, these actions are identical, text is obtained from the Windows clipboard. Under Unix/Linux, clicking with button 2 will also paste the primary selection, and button 3 will also paste the clipboard. The primary selection is generally the most recently selected text in any window, the clipboard contains text that was explicitly saved via an operation in a text entry window.

While in editing mode, the keypress display to the left of the prompt line is replaced with two or three buttons. The R and S buttons, which are always present when the prompt line is in editing mode, provide access to five general-purpose registers for text, plus a register for the ``last'' text. Both buttons produce a drop-down menu containing register numbers. If a selection in made in the S menu, the text currently in the prompt area is saved to the register whose number was selected. Any previous content is overwritten. If a selection is made in the R menu, text saved in the register whose number is selected will replace the text in the prompt area. The saved text can contain hypertext entries (see below).

In some contexts, a third (``L'') button appears. This provides access to the ``long text'' capability, which allows multiple lines of text to be entered by providing access to a text editor window.

When editing mode is exited, the buttons disappear and are replaced with the keys pressed display. If Enter was pressed to terminate editing mode, the text is automatically saved in register 0, and will be available from the R menu the next time editing mode is entered.

For some property strings, if a line of text that is longer than 256 characters is opened for editing on the prompt line, the Text Editor will appear, loaded with the text. The text will be saved as a ``long text'' item.

These features are described in more detail in the description of the label command in 4.9.

Non-printing characters in the text will be displayed using special symbols, which can be edited (in edit mode) as normal characters. The non-printing character most likely to appear (and the only one that probably should appear) corresponds to the line termination character. These cause a line break when the text is displayed as a label on-screen, and can be entered while in editing mode with Shift-Enter. In Windows, these are shown as a paragraph symbol, while in Unix/Linux a ``v/t'' (vertical tab) glyph is used. Other characters will show as a black dot in Windows, or a ``strange'' character in Unix/Linux.

The prompt line participates in the drop protocol for files. Files dropped on the prompt line in normal mode have the same effect as files dropped in the main drawing window - the file will be taken as layout input and displayed in the drawing window.

When in text editing mode, files dropped in a drawing window or the prompt line will not be displayed, rather the full path to the file is inserted into the text line at the cursor. This means that when responding to a prompt to open a file, the File Selection pop-up from the File Select button in the File Menu can be used to find the file. The file can then be dragged into the main window or the prompt line window and dropped, and the name will appear on the prompt line. Also while the prompt line is in editing mode, pressing the Open (green octagon) button or the Open menu entry of the File Selection pop-up will load the selected file path into the prompt line rather than opening the cell for editing. In most situations where Xic prompts for a file path via the prompt line, a simplified version of the File Selection pop-up will appear while editing is active.

When giving input to Xic, single and double quotes can be used to ``hide'' characters, such as space characters, that Xic would otherwise interpret incorrectly. Xic will generally strip the outermost quotes before processing, so inner-level quotes will be retained (quote marks of different types nest). A quote mark which is preceded by a backslash will be treated as an ordinary character.

As an example, consider the prompt of the Open command. The command prompt expects one or two tokens. The first token is the name of a file to open. The second token, if given, is the name of the cell to edit if the first token names a multi-cell file such as a GDSII file. Suppose that the file is in a directory named ``Xic Files''. Without the quoting mechanism, there is an obvious problem. To edit the file, one enters, for example (each of these would work),

"Xic Files"/my_design.gds
"Xic Files/my_design.gds"
Xic" "Files/my_design.gds

The double quotes make each of these strings appear to Xic as a single word.

Xic contains a ``hypertext'' editing capability, which is active in electrical mode. This is necessary, for example, when setting device properties which reference other devices or nodes. The device names and node numbers are set by Xic, and change if the circuit is modified, thus property text could become invalid if it were static. Instead, internally, strings are stored as data structures which reference pure text as well as devices and nodes by internal reference. Thus, these hypertext strings are always valid.

One accesses a hypertext reference by clicking on the schematic while text input is being solicited in the prompt area. The returned data can be a node reference, a device branch reference, or a device name. The string, as currently defined, is inserted into the displayed text in the prompt area in color. Note that one can only delete the whole item with the Delete and Backspace keys, the hypertext references are treated as single items.


next up previous contents index
Next: Layer Table Up: Prompt Line Previous: Prompt Line   Contents   Index
Stephen R. Whiteley 2012-04-01