officefileapi-devexpress-dot-pdf-dot-pdftextsearchresults.md
Provides access to the document area containing the text found.
Namespace : DevExpress.Pdf
Assembly : DevExpress.Pdf.v25.2.Core.dll
NuGet Package : DevExpress.Pdf.Core
public IList<PdfOrientedRectangle> Rectangles { get; }
Public ReadOnly Property Rectangles As IList(Of PdfOrientedRectangle)
| Type | Description |
|---|---|
| IList<PdfOrientedRectangle> |
A collection of PdfOrientedRectangle objects.
|
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Rectangles property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
pdf-document-api-highlight-search-results/CS/HighlightSearchResults/Program.cs#L68
PdfTextMarkupAnnotationFacade annotation =
page.AddTextMarkupAnnotation(result.Rectangles[i], PdfTextMarkupAnnotationType.Highlight);
if (annotation != null)
pdf-document-api-highlight-search-results/VB/HighlightSearchResults/Program.vb#L57
For i As Integer = 0 To result.Rectangles.Count - 1
Dim annotation As PdfTextMarkupAnnotationFacade = page.AddTextMarkupAnnotation(result.Rectangles(i), PdfTextMarkupAnnotationType.Highlight)
If annotation IsNot Nothing Then
See Also