PdfViewer Class

Definition

Assembly Broadside.Viewer.Blazor.dll
Inherits Object → ComponentBase
Show inherited members (21)

A PDF viewer for Blazor WebAssembly: pages are rasterized in tiles by the managed software rasterizer on the browser's thread, in slices that leave every animation frame to the browser, and drawn into a canvas; a remote Source is read through HTTP range requests, so page 1 of a linearized file shows before the rest downloads. Pointer, wheel and keyboard input drive the viewer core's InputModel; mouse drags over text select it (copy with the browser's copy command); links and form fields work through the AnnotationLayer; and each loaded page's logical structure is mirrored into an invisible DOM tree in reading order, so screen readers and the keyboard reach page text.

[SupportedOSPlatform("browser")]
public sealed class PdfViewer : ComponentBase, IComponent, IHandleEvent, IHandleAfterRender, IAsyncDisposable

Remarks

Spec #33 track 6 shell (issue #221), over the viewer core of issues #209 to #220. Accessibility: ISO 32000-2 §14.8 (tagged PDF) and §14.9.3 (alternate descriptions) through AccessibilityBridge. Actions: ISO 32000-2 §12.6.4 — destinations inside the document are followed; every action, URIs included, is reported through OnAction and never performed.

Keys while the viewer has focus: arrows, Page Up/Down, Space, Home/End scroll and turn pages; + and - zoom, 0 fits the width; Tab and Shift+Tab move between links and form fields, Enter activates one; Ctrl/Cmd+A selects all text; Shift+arrows extend a selection; N, H, T, L, G, K, F, D and P move the reading focus to the next element, heading, table, list, figure, link, form field, landmark or page (Shift goes back); Escape clears the selection and the reading focus.

Runs in the browser only (it imports a small JavaScript module from _content/Broadside.Viewer.Blazor).

Tip: use kind:method, kind:property, kind:ctor. Press Esc to clear.

Properties (16)

Methods (13)