Sun Microsystems, Inc.
spacerspacer
spacer www.sun.com docs.sun.com |
spacer
black dot
 
 
12.  Using Text Editor Entering Text Using Wrap To Fit To Set Wrap To Fit On or Off  Previous   Contents   Next 
   
 

Entering Special Characters

Different systems often use certain key combinations to insert special characters (see "Composing Special Characters").

In some instances, a key combination may be reserved by Text Editor. For example, a Text Editor mnemonic for displaying a menu might conflict with a key sequence you want to use on your keyboard. To insert the correct character you may need to override the reserved behavior by preceding the key combination with Control+Q.

Moving the Cursor in a Document

As you enter and edit text, you move the insertion cursor using the mouse and keyboard cursor keys. Using the mouse, move the pointer to the new location in the document and click mouse button 1.

You can also use the keyboard cursor movement keys:

Key

Cursor Movement

Up Arrow

Up one line

Down Arrow

Down one line

Left Arrow

Left one character

Right Arrow

Right one character

Control+Left Arrow

Move left to previous word

Control+Right Arrow

Move right to next word

Home

Beginning of the current line

End

End of the current line

Control+Up Arrow

Beginning of the previous paragraph

Control+Down Arrow

Beginning of the next paragraph

Control+Home

Beginning of the document

Control+End

End of the document

Control+G

To the Line field in the status line


Note - If your keyboard uses different key labels, ask your system administrator to identify the corresponding keys.


To Go to a Specific Line

  1. Display the status line (see "To Display the Status Line").

  2. Press Control+G or click in the Line field of the status line.

  3. Type the line number you want to go to and press Return.

To Scroll a Document

  • Select and drag the vertical scroll bar to view more text. Use the horizontal scroll bar to view long lines.

You can also use the scrolling keys:

Key

Scroll Movement

Page Up

Up one page

Page Down

Down one page

Control+Page Up

Left one page

Control+Page Down

Right one page

Selecting Text

Before using edit commands such as cut and paste, you must select the text. You can select text using the mouse or the keyboard.

To Select Text with the Mouse

  1. Click at the beginning of the text you want to select.

  2. Press and hold mouse button 1 and drag to the end of the text.

    To deselect text, click any area in the window.


    Note - To modify a selection you have made, press and hold the Shift key and mouse button 1. Then drag forward or backward to adjust the amount of selected text. Or, hold down the Shift key and one of the arrow keys to change the selection.


You can also use these shortcuts for selecting text:

Word

Double-click the word

Line

Triple-click the line

All text

Quadruple-click in the text

Secondary Selection

This method enables you select text and replace it with another selection, which is used as the replacement text.

To Replace Text Using Secondary Selection

  1. Select the text that you want to replace.

  2. Move the pointer to the beginning of the text you want to replace the first selection with. Hold down the Alt key and mouse button 2 and drag to the end of the text you want to use.

    The text is underlined.


    Note - If your keyboard does not have an Alt key, ask your system administrator to identify the corresponding key.


  3. Release the Alt key and mouse button.

    The underlined text overwrites your first selection.

To Select Text with the Keyboard

Text to Select

Action

Text block

Move the cursor to the beginning of the text block. Hold down the Shift key and an arrow key to move the cursor to the end of the text block.

Cursor to beginning of line

Shift+Home

Cursor to end of line

Shift+End

Cursor to beginning of paragraph

Shift+Control+Up Arrow

Cursor to end of paragraph

Shift+Control+Down Arrow

Cursor to beginning of document

Shift+Control+Home

Cursor to end of document

Shift+Control+End

All text

Control+/

Deselect all text

Control+\

Editing Text

Minor edits can be made using the editing keys. You may also want to copy, move, or delete portions of text, find and change a word or phrase, or check the spelling of your document.

Editing Keys

Key

Action

Backspace

Deletes the character before the cursor

Delete

Deletes the character following the insertion cursor

Control+Backspace

Deletes the previous word

Shift+Backspace

Deletes characters from the cursor to the beginning of the line

Control+Delete

Deletes all the characters from the cursor to the end of the current line

Insert

Toggles Overstrike and Insert mode

Menu Shortcut Keys

You can also use these shortcut keys when making edits.

Table 12-1 Shortcut Keys

Control+C

Copy selected text

Control+X

Cut selected text

Control+V

Paste selected text

Control+F

Find/Change text

Control+Z

Undo a cut, delete, clear, include, copy, or paste command

 
 
 
  Previous   Contents   Next