// Set a thick red border for the current path object ImageEnView1.PdfViewer.Objects[idx].PathStrokeWidth := 5; ImageEnView1.PdfViewer.Objects[idx].StrokeColor := TColor2TRGBA( clRed, 255 );
// Remove the border for the current path object ImageEnView1.PdfViewer.Objects[idx].PathStrokeWidth := 0;
// Add a spot wherever user clicks on a PDF page procedure TfrmMain.ImageEnView1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); const Spot_Size = 20; Spot_Border_Color = clBlack; Spot_Border_Size = 2; Spot_Fill_Color = clRed; Spot_Opacity = 255; var clickPos: TDPoint; obj: TPdfObject; begin clickPos := ImageEnView1.PdfViewer.ScrToPage( X, Y, True );
// Center ellipse over click position obj := ImageEnView1.PdfViewer.Objects.AddEllipse( clickPos.X - Spot_Size div 2, clickPos.Y - Spot_Size div 2, Spot_Size, Spot_Size );