Converting Frequent Segments to Snippets

You can view a list of segments that occur frequently in your project. You can see the segment text, the number of occurrences of each segment, and the number of words and characters in each segment. If you notice that certain segments are repeated numerous times in your project, you can easily convert them to snippets. See Frequent Segments and Snippets

How to Convert a Frequent Segment to a Snippet

  1. Open the Frequent Segments window pane. See Viewing Frequent Segments.
  2. Select the segment that you want to convert to a snippet.
  3. In the local toolbar, click the Create drop-down button and select Create Snippet. The Create Snippet dialog opens.

  4. In the Snippet File field, type a new name for the snippet.

    It is recommended that you leave the project folder selection as "Resources/Snippets" (or select a subfolder that you have created in the Snippets folder). After the snippet is created, you can see the snippet file in the Content Explorer.

  5. Click Create. The snippet is created and added to the Flare project that you are analyzing.
  6. Open the Snippet Suggestions window pane. See Viewing Snippet Suggestions.

    Note It may take a few moments for suggestions for the new snippet to display in the window pane. You can click Refresh the active window pane. in the local toolbar to refresh the window pane.

  7. Do one of the following, depending on whether you want to convert multiple suggestions simultaneously, or if you want to convert only one snippet suggestion at a time.

    To Convert Multiple Suggestions Simultaneously

    1. In the window pane, select all suggestions that you want to convert. If you want to select all rows click Click to select all rows.. You can hold the SHIFT key to select a range, or you can hold the CTRL key to select individual items.
    2. In the local toolbar, click the Apply button.
    3. In the message that opens, click OK. Another message lets you know how many files were changed.
    4. Click OK. All of the selected suggestions are converted to snippets.

      Note If you want to undo the conversions, you can use the Backups window pane (View > Backups). See Restoring Backup Files.

    To Convert One Suggestion at a Time

    1. In the Snippet Suggestions window pane, select the row that you want to convert to a snippet.
    2. You can either double-click on the specific row, or right-click on the row and select Open. The file opens with the suggested content highlighted.
    3. In Flare, insert the snippet (e.g., select Insert > Snippet).

      See the Inserting Snippets for more information about inserting snippets.