PDFiumVCL Docs

LoadingText property

이 API 항목은 식별자, 시그니처, 코드 블록, PDF 용어를 원래 형태로 유지합니다.
Component: TPdfView  ·  Unit: PDFium
Text shown in the centre of the page while asynchronous rendering is still in progress.

Syntax

property LoadingText: string; // default 'Loading...'

Description

LoadingText is the caption that the viewer overlays on top of a partially-rendered page when AsyncRendering is True. The viewer measures the string with its current inherited font, expands the result into a centred rectangle, fills it with LoadingColor, and then draws the text on top. The default 'Loading...' is recognisable to users as a transient state and is wide enough to be visible without dominating the page.

The overlay is keyed off the text rather than off a separate visibility flag. Assigning an empty string ('') suppresses the overlay even while asynchronous rendering is active — useful when the host application wants to display its own loading widget (an animated GIF, a modal progress dialog, a separate status-bar panel) and would rather not have the built-in rectangle compete for attention.

Localise the string by assigning a translated resource at startup; the property accepts any string the host application can produce, including multi-byte characters such as Chinese, Japanese, or Arabic.

Remarks

Example

// Localised loading caption.
PdfView1.AsyncRendering := True;
PdfView1.LoadingText := SLoadingPdf; // resourcestring lookup

// Suppress the built-in indicator; use a TActivityIndicator instead.
PdfView1.LoadingText := '';
ActivityIndicator1.Animate := True;

// Stage-specific message for slow first paint.
PdfView1.LoadingText := 'Decoding first page...';
PdfView1.Active := True;

See Also

LoadingColor, AsyncRendering, Font, Active