next up previous contents index
Next: Using Xic Up: Text Entry Windows Previous: Selections and Clipboards   Contents   Index


GTK Text Input Key Bindings

The following table provides the key bindings for editable text entry areas in GTK-2. However, be advised that these bindings are programmable, and may be augmented or changed by installation of a local theme.

GTK Text-Entry Key Bindings
Ctrl-a Select all text
Ctrl-c Copy selected text to clipboard
Ctrl-v Paste clipboard at cursor
Ctrl-x Cut selection to clipboard
Home Move cursor to beginning of line
End Move cursor to end of line
Left Move cursor left one character
Ctrl-Left Move cursor left one word
Right Move cursor right one character
Ctrl-Right Move cursor right one word
Backspace Delete previous character
Ctrl-Backspace Delete previous word
Clear Delete current line
Shift-Insert Paste clipboard at cursor
Ctrl-Insert Copy selected text to clipboard
Delete Delete next character
Shift-Delete Cut selected text to clipboard
Ctrl-Delete Delete next word

Clicking with button 1 will move the cursor to that location. Double clicking will select the clicked-on word. Triple clicking will select the entire line. Button 1 is also used to select text by dragging the pointer over the text to select.

Clicking with button 2 will paste the primary selection into the line at the click location, if the window text is editable.

Clicking with button 3 will will bring up a context menu. From the menu, the user can select editing operations.

These operations are basically the same in Windows and Unix/Linux, with one important difference: in Windows, the primary selection applies only to the program containing the selection. In Unix/Linux, the primary selection applies to the entire desktop, like the clipboard.

Special characters can be entered using the Unicode escape Ctrl-u. The sequence starts by pressing Ctrl-u, then entering hex digits representing the character code, and is terminated with a space character or Enter. The Unicode coding can be obtained from tables provided on the internet, or from applications such as KCharSelect which is part of the KDE desktop. These are generally expressed as ``U + xxxx'' where the xxxx is a hex number. It is the hex number that should be entered following Ctrl-u. For example, the code for $ \pi$ (pi) is 03c0. Note that special characters can also be selected and copied, or in some cases dragged and dropped, from another window.


next up previous contents index
Next: Using Xic Up: Text Entry Windows Previous: Selections and Clipboards   Contents   Index
Stephen R. Whiteley 2022-05-28