Advanced Find and Replace in LibreOffice Writer

The basic Find and Replace dialog allows users to quickly change text. However, there are more advanced settings for finding text with specific characteristics. Specific characteristics also can be included with the replaced text.

Click the “Other options” arrow to reveal the more advanced options. Several items will be revealed. There are check boxes and buttons.

Check boxes
  • Current selection only
  • Regular expressions
  • Similarity search
  • Replace backwards
  • Including Styles
  • Comments
Other buttons
  • Attributes
  • Format
  • No Format
Current selection only

This check box works with the Replace All button. A check in this box mean that only instances of the characters in a highlighted section of text or a table will be replaced.

  1. Select a desired section of text or cells in a table.
  2. Open the Find and Replace dialog.
  3. Type in the desired characters in the Find text box.
  4. Type in the desired characters in the Replace text box.
  5. Click the Other options arrow to reveal the advance features.
  6. Place a check in the Current selection check box.
  7. Click the Replace All button.
Regular expressions

This allows users to include wildcards in the Find text box. Wildcards allow you to make your searches more specific. They also help you find text in a document when you are unsure of the specific string of characters.

  1. Place a check in this box.
  2. Then type a string of characters with a wildcard. This Web page discusses the different wildcards.
Similarity search

This checkbox will words and strings of text in a document that are based on what is entered in the Find text box but different from it. There is an associated button with the check box. Click it to launch the Similarity search dialog.

This page will go into more detail about how to use this dialog.

Replace backwards

A check in this box will replace the characters in the Find box with those in the Replace box, starting with the bottom of the document. It works with the Replace button.

Click the Replace button, and it will highlight the last instance in the document of the characters in the Find box. The second click will change the highlighted text to what is in the Replace box. The next instance of the characters in the document will be highlighted.

Paragraph Styles

This checkbox will change the text fields to drop-down menus of paragraph styles. The Find drop-down menu will list the styles that are in the document. The Replace menu will list all the available styles that are available.

  1. Click the Paragraph Styles checkbox. The Find and Replace text boxes are transformed into drop-down menus.
  2. Select the desired paragraph style in the Find drop-down menu.
  3. If you simply want to find text in the document that are in this paragraph style.
  4. If you want to change the paragraph style of text that is in the style in the Find drop-down menu, do the following:
    1. Click the Replace drop-down menu and choose a desired style.
    2. Click either the Replace button or Replace All button
Comments

This checkbox will set Writer to find and change text in comments that are to the right of the document. Comments are associated with with chosen text in a document. Each comment is connected to the text where the cursor is located.

The Comments need to be found and replaced individually. The Find All and Replace All buttons are grayed out. Find Previous, Find Next, and Replace can be clicked. Visit the Basic Find and Replace page.

Other buttons

Below the checkboxes are three buttons: Attributes, Format, and No Format. Clicking inside the Find text box so the cursor is flashing makes all three active. Only the Format and No Format buttons are active when you click inside the Replace text box.

When you click the Attributes and Format buttons associated dialogs open for each. The No Format button clears any formats to text in the Find and Replace boxes.