THotPDF.SetLoadedAnnotationRect Method
Replaces the annotation /Rect to move or resize an annotation on an existing page
Declaration
procedure SetLoadedAnnotationRect(PageIndex, AnnotationIndex: Integer; X1, Y1, X2, Y2: Single);
Parameters
PageIndexis the zero-based loaded page indexAnnotationIndexis the zero-based annotation index on that pageX1,Y1,X2, andY2are endpoints in raw PDF user-space points
Usage notes
- Endpoint order is normalized, so reverse drag coordinates produce the same rectangle
- This API does not apply Viewer zoom, scroll, page-rotation, or view-rotation transforms
- All cached DPI variants of the affected page are invalidated immediately without evicting other pages
- Invalid indexes leave the loaded document unchanged
Related APIs
GetLoadedAnnotationInfo · SetLoadedAnnotationBorderStyle · Loaded document toolkit