Graphical Text Editors
Aqua’s default text view, found in nearly every Cocoa application that involves text entry, is laden with a wide and predictable range of features. For a core OS service, the standard Aqua textbox gives you some fairly sophisticated editing tools.
First of all, there’s a myriad of undocumented keystrokes you can use to quickly move your cursor around, besides the obvious use of the arrow keys, or the even more obvious (and time-consuming) use of the mouse. These have been variously cribbed from Microsoft Word, NeXTSTEP, and even the Emacs text editor. (In this table, a “line” means a single row of text as it appears in the window, and a “paragraph” means any number of rows, bound on either end by either a hard carriage return or the start or end of the text area.)
Key command |
Action |
---|---|
- ← Control- ← |
Move the cursor to the beginning of the line. |
- →, Control- → |
Move the cursor to the end of the line. |
Control-A |
Move the cursor to the start of the paragraph. |
Control-E |
Move the cursor to the end of the paragraph. |
Option-↑ |
Move the cursor up one paragraph. |
Option-↓ |
Move the cursor down one paragraph. |
Option- → |
Move the cursor right one word. |
Option- ← |
Move the cursor left one word. |
Control-D |
Delete the character to the right of the cursor. ... |
Get Mac OS X in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.