PDFium Delphi Component Docs

เมธอด SetReadingHighlight

Component: TPdfView  ·  Unit: PDFium
Controls the TPdfView reading-highlight overlay used by synchronized text-to-speech playback

Syntax

procedure SetReadingHighlight(const Rects: TPdfRectangles; PageNumber: Integer);

Parameters

RectsTPdfRectangles. Page-coordinate rectangles to paint
PageNumberInteger. One-based page that owns the rectangles

Return Value

ส่งสี่เหลี่ยมไฮไลต์การอ่านมาในพิกัดของหน้า และวาดทับบนหน้าที่ร้องขอ วิธีนี้ตั้งใจใช้กับย่อหน้า หัวข้อ เซลล์ตาราง หรือบรรทัดที่กำลังถูกพูดในขณะนั้น

ล้างไฮไลต์เมื่อการเล่นหยุดหรือเมื่อแอปย้ายไปยัง fragment อื่น ReadingHighlightColor ควบคุมสีของ overlay

Description

Remarks

if Length(Content.Fragments) > 0 then
  PdfView1.SetReadingHighlight(Content.Fragments[0].LineRects, Content.Page);

Example

SetReadingHighlight, ClearReadingHighlight, ReadingHighlightColor, ReadableContent