Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions libraries/radpdfprocessing/features/search.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,18 @@ The `TextSearchOptions` class exposes the following properties for setting the s
| `CaseSensitive` | Gets or sets a value indicating whether the search is case sensitive. |
| `WholeWordsOnly` | Gets or sets a value indicating whether only whole words are matched. |

### Regular Expression and Multi-Word Search

To search for patterns or multi-word phrases, set `UseRegularExpression = true` on `TextSearchOptions`. When using regular expressions, keep `WholeWordsOnly = false` so that internal delimiter wrappers do not conflict with your pattern.

During text extraction:
* Words on the same line are separated by a single space (`" "`).
* Line breaks within the page are normalized to a single space (`" "`) using `TextSearchOptions.TextSearchLinesSeparator`.
* Text search is evaluated per page; phrases that span across page boundaries are not matched.
* In PDF documents, spaces are determined by glyph positioning (`Delta = 1.15`). If text fragments lack sufficient visual displacement, words may be extracted contiguously.

<snippet id='regex-and-multiword-search'/>

## See Also

* [RadFixedDocument]({%slug radpdfprocessing-model-radfixeddocument%})