Difference between revisions of "Documentation/OOo3 User Guides/Getting Started/Working with text"

From Apache OpenOffice Wiki
Jump to: navigation, search
(New page: {{DISPLAYTITLE:Working with text}} {{Documentation/GS3WriterTOC |ShowPrevNext=block |PrevPage=Documentation/OOo3_User_Guides/Getting Started/Working with documents |NextPage=Documentation/...)
 
Line 142: Line 142:
 
{{Documentation/Caution|Unlike the menu tool that applies to the individual document, a change in the default language from the Options dialog is a general change of settings of OOo and will therefore apply to all the documents created in the future. If you want to change the language for the current document only, be sure to select the For the current document only option.}}
 
{{Documentation/Caution|Unlike the menu tool that applies to the individual document, a change in the default language from the Options dialog is a general change of settings of OOo and will therefore apply to all the documents created in the future. If you want to change the language for the current document only, be sure to select the For the current document only option.}}
  
Spell checking is available only for those languages in the list that have the symbol [[]] next to them. If you do not see the symbol next to your preferred language, you can install the additional dictionary using '''Tools > Languages > More dictionaries online'''.
+
Spell checking is available only for those languages in the list that have the symbol [[Image:Spellcheck-icon_2.png]] next to them. If you do not see the symbol next to your preferred language, you can install the additional dictionary using '''Tools > Languages > More dictionaries online'''.
  
 
The language used for checking spelling is also shown in the status bar, next to the page style in use.
 
The language used for checking spelling is also shown in the status bar, next to the page style in use.

Revision as of 13:38, 10 April 2010


Working with text (selecting, copying, pasting, moving) in Writer is similar to working with text in any other program. OOo also has some convenient ways to select items that are not next to each other, select a vertical block of text, and paste unformatted text.

Selecting items that are not consecutive

To select nonconsecutive items using the mouse:

  1. Select the first piece of text.
  2. Hold down the Control key and use the mouse to select the next piece of text.
  3. Repeat as often as needed.

Now you can work with the selected text (copy it, delete it, change the style, or whatever).

Template:Documentation/Note

Selecting items that are not next to each other.

To select nonconsecutive items using the keyboard:

  1. Select the first piece of text. (For more information about keyboard selection of text, see the topic “Navigating and selecting with the keyboard” in the Help.)
  2. Press Shift+F8. This puts Writer in Add mode. The word ADD appears on the status bar.
  3. Use the arrow keys to move to the start of the next piece of text to be selected. Hold down the Shift key and select the next piece of text.
  4. Repeat as often as needed.
  5. Now you can work with the selected text.
  6. Press Esc to exit from this mode.

Selecting a vertical block of text

You can select a vertical block or “column” of text that is separated by spaces or tabs (as you might see in text pasted from e-mails, program listings, or other sources), using OOo’s block selection mode. To change to block selection mode, use Edit > Selection Mode > Block Area, or click several times in the status bar on STD until it changes to BLK.

StatusBlk.png

Now highlight the selection, using mouse or keyboard, as shown below.

Selecting a vertical block of text.

Cutting, copying, and pasting text

Cutting and copying text in Writer is similar to cutting and copying text in other applications. You can use the mouse or the keyboard for these operations.

Cut-icon.png Cut: Use Edit > Cut or the keyboard shortcut Control+X or the Cut icon on the toolbar.
Copy-icon.png Copy: Use Edit > Copy or the keyboard shortcut Control+C or the Copy icon.
Paste-icon.png Paste: Use Edit > Paste or the keyboard shortcut Control+V or the Paste icon.

If you simply click on the Paste icon, any formatting the text has (such as bold or italics) is retained. To make the pasted text take on the formatting of the surrounding text where it is being pasted, click the triangle to the right of the Paste icon and select Unformatted text from the menu.

Paste menu.

Finding and replacing text and formatting

Writer has a Find and Replace feature that automates the process of searching for text inside a document. In addition to finding and replacing words and phrases, you can:

  • Use regular expressions (wildcards) to fine-tune a search (see the Help for details).
  • Find and replace specific formatting (see the Writer Guide).
  • Find and replace paragraph styles (see the Writer Guide).

To display the Find & Replace dialog, use the keyboard shortcut Control+F or select Edit > Find & Replace.

Type the text you want to find in the Search for box.

To replace the text with different text, type the new text in the Replace with box.

You can select various options such as matching the case, matching whole words only, or doing a search for similar words. (See below for some other choices.)

When you have set up your search, click Find. To replace text, click Replace instead.

Template:Documentation/Tip

Expanded Find & Replace dialog
Documentation caution.png Use Replace All with caution; otherwise, you may end up with some hilarious (and highly embarrassing) mistakes. A mistake with Replace All might require a manual, word-by-word, search to fix.

Inserting special characters

A special character is one not found on a standard English keyboard. For example, © ¾ æ ç ñ ö ø ¢ are all special characters. To insert a special character:

  1. Place the cursor where you want the character to appear.
  2. Click Insert > Special Character to open the Special Characters window.
  3. Select the characters you wish to insert, in order, then click OK. The selected characters are shown in the lower left of the dialog. As you select a character, it is shown on the lower right, along with its numerical code.

Template:Documentation/Note

The Special Characters window, where you can insert special characters.

Template:Documentation/Tip

Setting tab stops and indents

The horizontal ruler shows both the default tab stops and any that you have defined. To set the measurement unit and the spacing of default tab stops, go to Tools > Options > OpenOffice.org Writer > General.

You can also set or change the measurement unit by right-clicking on the ruler to open a list of units, as shown below. Click on one of them to change the ruler to that unit.

Ruler showing default tab stops

Double-click on a blank part of the ruler to open the Indents & Spacing page of the Paragraph dialog. Double-click on the ruler itself to open the Tabs page of the Paragraph dialog and fine-tune tab stop settings.

File:Paragraph-tabs.png
The Tabs page of the Paragraph dialog, where you can adjust tab settings

Checking spelling

Writer provides a spelling checker, which can be used in two ways.

AutoSpellcheck.png AutoSpellcheck checks each word as it is typed and displays a wavy red line under any misspelled words. When the word is corrected, the line disappears.

Spellcheck-icon.png To perform a separate spelling check on the document (or a text selection) click the Spellcheck icon. This checks the document or selection and opens the Spellcheck dialog if any misspelled words are found.

Here are some more features of the spelling checker:

  • You can change the dictionary language (for example, to Spanish, French or German) on the Spellcheck dialog.
  • You can add a word to the dictionary. Click Add in the Spellcheck dialog and pick the dictionary to add it to.
  • The Options dialog of the Spellcheck tool has a number of different options such as whether to check uppercase words and words with numbers. It also allows you to manage custom dictionaries, that is, add or delete dictionaries, and add or delete words in a dictionary.
  • On the Font tab of the Paragraph Styles dialog, you can set paragraphs to be checked in a specific language (different from the rest of the document). See Chapter 7 (Working with Styles) in the Writer Guide for more information.

Using language tools

OOo provides some tools that make your work easier if you mix multiple languages within the same document or write documents in various languages.

You can set the language for the whole document, selected paragraphs, or even individual words or characters. In versions earlier than OOo 3.0 it was necessary to use styles in order to insert within a document paragraphs or individual groups of characters that use a different language, while now this can be conveniently done from the main menu.

Template:Documentation/Tip

The main advantage of changing the language is that you can then use the correct dictionaries to check spelling and apply the localized versions of Autocorrect replacement tables, thesaurus, and hyphenation rules.

The language tools can be found in Tools > Languages on the main menu, as shown below.

File:Languages-menu.png
The Language menu

The following options are available:

  • For selection: select this option to apply a specified language to the selected text (the selection can comprise only a few characters or several paragraphs).
  • For paragraph: select this option to apply the specified language to the paragraph where the cursor is located.
  • For all text: select this option to apply the specified language to all the document.

An alternative way to change the language of a whole document is to use Tools > Options > Language Settings > Languages. In the Default languages for documents section of the Options dialog, you can choose a different language for all the text.

File:Default-lang.png
Options available in the Languages settings
Documentation caution.png Unlike the menu tool that applies to the individual document, a change in the default language from the Options dialog is a general change of settings of OOo and will therefore apply to all the documents created in the future. If you want to change the language for the current document only, be sure to select the For the current document only option.

Spell checking is available only for those languages in the list that have the symbol Spellcheck-icon 2.png next to them. If you do not see the symbol next to your preferred language, you can install the additional dictionary using Tools > Languages > More dictionaries online.

The language used for checking spelling is also shown in the status bar, next to the page style in use.

You can also configure the language for a paragraph or a group of characters as None. This option is particularly useful in the case where you insert in the document text that you do not want to spellcheck, such as web addresses or programming language snippets.

Using AutoCorrect

Writer’s AutoCorrect function has a long list of common misspellings and typing errors, which it corrects automatically. For example, “hte” will be changed to “the”. Select Tools > AutoCorrect to open the AutoCorrect dialog. There you can define which strings of text are corrected and how. In most cases, the defaults are fine.

Template:Documentation/Tip

  • To stop Writer from replacing a specific spelling, use Tools > AutoCorrect > Replace, highlight the word pair and click Delete.
  • To add a new spelling to correct, type it into the Replace and With boxes and click New.
  • See the different tabs of the dialog for the wide variety of other options available to fine-tune AutoCorrect.

Template:Documentation/Tip

Using word completion

If Word Completion is enabled, Writer tries to guess which word you are typing and offers to complete the word for you. To accept the suggestion, press Enter. Otherwise continue typing.

Template:Documentation/Tip

You can customize word completion from the Tools > AutoCorrect > Word Completion page:

  • Add (append) a space automatically after an accepted word.
  • Show the suggested word as a tip (hovering over the word) rather than completing the text as you type.
  • Change the maximum number of words remembered for word completion and the length of the smallest words to be remembered.
  • Delete specific entries from the word completion list.
  • Change the key that accepts a suggested entry—the options are Right arrow, End key, Return (Enter), and Space bar.

Template:Documentation/Note

Using AutoText

AutoText allows you to assign text, tables, graphics and other items to a key combination. For example, rather than typing “Senior Management” every time you use that phrase, you might just type “sm” and press F3. Or you can save a formatted Note (like the one on this page) as AutoText and then insert a copy by typing “note” and pressing F3.

To assign some text to an AutoText shortcut:

  1. Type the text into your document.
  2. Select the text so it is highlighted.
  3. Select Edit > AutoText (or press Control+F3).
  4. Enter a name for your shortcut. Writer will suggest a one-letter shortcut, which you can change.
  5. Click the AutoText button on the right and select New (text only) from the menu.
  6. Click Close to return to your document.

Template:Documentation/Tip

AutoText is especially powerful when assigned to fields. See Chapter 14 (Working with Fields) in the Writer Guide for more information.

Inserting dashes and non-breaking spaces

You can insert a dash by using the Special Characters window or by using AutoCorrect. For more about AutoCorrect, see “Controlling OOO’s AutoCorrect functions” in Chapter 2 (Setting up OpenOffice.org) and Using AutoCorrect in this chapter.

– is an en-dash; that is, a dash the width of the letter “n” in the font you are using. It is U+2013 (scroll down to the General Punctuation section in the Special Characters window). To enter an en-dash using AutoCorrect, type at least one character, a space, one or two hyphens, another space, and at least one more letter, then a space. The one or two hyphens will be replaced by an en-dash.

— is an em-dash; that is, a dash the width of the letter “m” in the font you are using. It is U+2014. To enter it using AutoCorrect, type at least one character, two hyphens, and at least one more character, then a space. The two hyphens will be replaced by an em-dash.

To insert a non-breaking space (to keep characters together, for example in a telephone number), press Control+Space on the keyboard.

Content on this page is licensed under the Creative Common Attribution 3.0 license (CC-BY).
Personal tools