# 7.4. Finding and Replacing Text

## 7.4.1. The Find Command

The "Find" command can be invoked 3 ways:

- By selecting Edit->Find and Replace... from the Menu bar

- You can use the keyboard shortcut: Ctrl-F

- By clicking on the toolbar.

When the Find Command is invoked, a dialog appears.

This first thing you need to do is enter what you want to search for in the text box labled "Search String".

You can now click on either "Find First" or "Find Next".

Clicking on "Find First" instructs KWord to begin at the beginning of the document and search for the first occurance of that string of characters.

Clicking on "Find Next" also instructs KWord to search for the string of letters, but KWord begins at the current cursor position.

When KWord finds a match, it moves the cursor to that point in the document, and highlights the matching string of characters. You have the option of clicking "Find Next" again, to find the next match. When you have found the string of letters you are looking for, you can click "Close" to close the window and return you to editing your document.

When KWord has shown you all the possible matches in the document, it will stop searching.

## 7.4.2. Refining Your Search

As you can see, the dialog box allows you to refine your search.

Search options which are in grey, are currently unavailable and will have no impact on the search results. Search options which are in black, can be selected by clicking once in the box preceeding the option.

Find Whole Words only

  If this option is selected, KWord will only find a match if the string of characters is the entire word.

  As an example, searching for "man" will match "Man" or "man", but will not match "manual", or "command"

Case Sensative

  Normally, KWord does not evaluate upper and lower case differences. When this option is checked, searching for "man" will not match "Man".

Regular Expression

  STUFF

Use Wildcards

  STUFF

Find Backwords

  When this option is checked, Kword searches from the current position backwards.

Family

  When this option is selected, only text string which matchs the search string and are formatted using the selected font family will return a match.

  Once you select this option, the dropdown box to the right will become active. You can select from all available text families here.

  As an example, searching for "man" with the family set to "times", will not match "man" which is formatted using a helvetica font.

Size

  When this option is selected, only text string which matchs the search string and are formatted using the selected font size will return a match.

  Once you select this option, the dropdown box to the right will become active. You can select from all available text sizes here.

Color

  When this option is selected, the color of the font is evaluated.

  When you select this option, you can see the current color to the right. Clicking on this colorbar will allow you to choose another color.

Bold

  When this option is selected, only characters that are in boldface will be returned as a match.

  Once you have selected the "Bold" search option, another checkbox labled "Bold" appears to the right. Select this box to search for characters in boldface. Leave this box blank to search for characters not in boldface.

Italic

  When this option is selected, only characters that are in italics will be returned as a match.

  Once you have selected the "Italic" search option, another checkbox labled "Italic" appears to the right. Select this box to search for characters in italics. Leave this box blank to search for characters not in italics.

Underline

  When this option is selected, only characters that are underlined will be returned as a match.

  Once you have selected the "Underline" search option, another checkbox labled "Underline" appears to the right. Select this box to search for underlined characters. Leave this box blank to search for characters without underlines.

Vertical Alignment

  When this option is selected, you can choose to only search for characters which are superscript, subscript or normal.

## 7.4.3. The Replace Command

The replace command is an extension of the search command.

Begin by completeing the find panel just as you would if you were going to use the find feature by itself.

When you are ready, you should click on the tab labled "Replace".

In this window, you enter the text and formatting of the text that will replace what you entered in the "Find" window.

In the text box labled "Replace String", enter the new text you want inserted.

With KWord, you can also format the strings before you replace them.

At this point, may also choose to change the formating of the text:

Family

  When this option is selected, you can change the font family.

  Once you select this option, the dropdown box to the right will become active. You can select from all available text families here.

Size

  When this option is selected, you can change the font size.

  Once you select this option, the dropdown box to the right will become active. You can select from all available text sizes here.

Color

  When this option is selected, you can change the color of the font.

  When you select this option, you can see the current color to the right. Clicking on this colorbar will allow you to choose another color.

Bold

  When this option is selected, you can toggle boldface on and off.

  Once you have selected the "Bold" search option, another checkbox labled "Bold" appears to the right. Check this box to turn boldface on, Leave this box empty to turn boldface off.

Italic

  When this option is selected, you can toggle italics on and off.

  Once you have selected the "Italic" search option, another checkbox labled "Italic" appears to the right. Check this box to turn italics on. Leave this box along to turn italics off.

Underline

  When this option is selected, you can toggle underlining on and off.

  Once you have selected the "Underline" search option, another checkbox labled "Underline" appears to the right. Check this box to turn underlining on. Leave this box along to turn underline off.

Vertical Alignment

  When this option is selected, you can toggle superscript and subscript on or off.

| Unless you specify additional formatting options, KWord will take the text formatting options of the text string you searched for, and use them to format the text you use to replace it.

When you have all your options set, you have one of three options to control replacing.

Replace First

  After you click this button, KWord will replace the first occurance of the search text with the replacement text.

Replace Next

  After you click this button, KWord will replace the next occurance of the search string, starting from the current cursor posistion.

Replace All

  After you click this button, KWord will replace all occurances of the search string, starting at the beginning of the document.

  If you click on the box labled "Ask before replacing", KWord will search for each occurance, highlight the text, and give you three options.

  - Yes - KWord will replace the text, and search for the next occurance.

  - No - This will abort the find and replace without any more changes.

  - Skip - This will skip this occurance, and search for the next occurance.

  When KWord has finished replacing all occurances, you can click "Close" to exit the window, or perform another find/replace.