PdfiumViewer
|
Control to render PDF documents. More...
Public Member Functions | |
Rectangle | GetOuterBounds (int page) |
Get the outer bounds of the page. More... | |
PdfRenderer () | |
Initializes a new instance of the PdfRenderer class. More... | |
PdfPoint | PointToPdf (Point location) |
Converts client coordinates to PDF coordinates. More... | |
Point | PointFromPdf (PdfPoint point) |
Converts a PDF point to a client point. More... | |
PdfRectangle | BoundsToPdf (Rectangle bounds) |
Converts client coordinates to PDF bounds. More... | |
Rectangle | BoundsFromPdf (PdfRectangle bounds) |
Converts PDF bounds to client bounds. More... | |
void | Load (IPdfDocument document) |
Load a IPdfDocument into the control. More... | |
void | RotateLeft () |
Rotate the PDF document left. More... | |
void | RotateRight () |
Rotate the PDF document right. More... | |
void | ScrollIntoView (PdfRectangle bounds) |
Scroll the PDF bounds into view. More... | |
void | ScrollIntoView (Rectangle rectangle) |
Scroll the client rectangle into view. More... | |
![]() | |
void | ZoomIn () |
Zooms the PDF document in one step. More... | |
void | ZoomOut () |
Zooms the PDF document out one step. More... | |
![]() | |
void | SetDisplayRectLocation (Point offset) |
void | SetDisplayRectLocation (Point offset, bool preserveContents) |
void | PerformScroll (ScrollAction action, Orientation scrollBar) |
Protected Member Functions | |
override void | OnLayout (LayoutEventArgs levent) |
Raises the E:System.Windows.Forms.Control.Layout event. More... | |
override void | OnZoomChanged (EventArgs e) |
Called when the zoom level changes. More... | |
override void | OnPaint (PaintEventArgs e) |
Raises the E:System.Windows.Forms.Control.Paint event. More... | |
override Rectangle | GetDocumentBounds () |
Gets the document bounds. More... | |
override void | OnSetCursor (SetCursorEventArgs e) |
Called whent he cursor changes. More... | |
override void | OnMouseDown (MouseEventArgs e) |
Raises the E:System.Windows.Forms.Control.MouseDown event. More... | |
override void | OnMouseUp (MouseEventArgs e) |
Raises the E:System.Windows.Forms.Control.MouseUp event. More... | |
virtual void | OnLinkClick (LinkClickEventArgs e) |
Called when a link is clicked. More... | |
override void | SetZoom (double zoom, Point? focus) |
Called when the zoom level changes. More... | |
override void | Dispose (bool disposing) |
Releases the unmanaged resources used by the T:System.Windows.Forms.Control and its child controls and optionally releases the managed resources. More... | |
![]() | |
override void | OnMouseWheel (MouseEventArgs e) |
Raises the E:System.Windows.Forms.Control.MouseWheel event. More... | |
override bool | IsInputKey (Keys keyData) |
Determines whether the specified key is a regular input key or a special key that requires preprocessing. More... | |
override void | OnLayout (LayoutEventArgs levent) |
override void | OnMouseDown (MouseEventArgs e) |
override void | OnMouseMove (MouseEventArgs e) |
override void | OnMouseUp (MouseEventArgs e) |
![]() | |
virtual void | OnScroll (ScrollEventArgs se) |
virtual void | OnDisplayRectangleChanged (EventArgs e) |
void | SetDisplaySize (Size size) |
override void | OnLayout (LayoutEventArgs levent) |
override void | OnMouseWheel (MouseEventArgs e) |
override void | OnVisibleChanged (EventArgs e) |
override void | WndProc (ref System.Windows.Forms.Message m) |
override bool | IsInputKey (Keys keyData) |
Determines whether the specified key is a regular input key or a special key that requires preprocessing. More... | |
Properties | |
IPdfDocument | Document [get] |
The associated PDF document. More... | |
new bool | TabStop [get, set] |
Gets or sets a value indicating whether the user can give the focus to this control using the TAB key. More... | |
int | Page [get, set] |
Gets or sets the currently focused page. More... | |
PdfViewerZoomMode | ZoomMode [get, set] |
Gets or sets the way the document should be zoomed initially. More... | |
PdfRotation | Rotation [get, set] |
Gets or sets the current rotation of the PDF document. More... | |
PdfMarkerCollection | Markers [get] |
Gets a collection with all markers. More... | |
![]() | |
double | Zoom [get, set] |
Gets or sets the current zoom level. More... | |
double | ZoomFactor [get, set] |
double | ZoomMin [get, set] |
double | ZoomMax [get, set] |
MouseWheelMode | MouseWheelMode [get, set] |
![]() | |
override CreateParams | CreateParams [get] |
override Rectangle | DisplayRectangle [get] |
bool | HScroll [get] |
bool | VScroll [get] |
Events | |
LinkClickEventHandler | LinkClick |
Occurs when a link in the pdf document is clicked. More... | |
![]() | |
EventHandler | ZoomChanged |
![]() | |
ScrollEventHandler | Scroll |
EventHandler | DisplayRectangleChanged |
SetCursorEventHandler | SetCursor |
Additional Inherited Members | |
![]() | |
const double | DefaultZoomMin = 0.1 |
const double | DefaultZoomMax = 5 |
const double | DefaultZoomFactor = 1.2 |
Control to render PDF documents.
PdfiumViewer.PdfRenderer.PdfRenderer | ( | ) |
Initializes a new instance of the PdfRenderer class.
Rectangle PdfiumViewer.PdfRenderer.BoundsFromPdf | ( | PdfRectangle | bounds | ) |
Converts PDF bounds to client bounds.
bounds | The PDF bounds to convert. |
PdfRectangle PdfiumViewer.PdfRenderer.BoundsToPdf | ( | Rectangle | bounds | ) |
Converts client coordinates to PDF bounds.
bounds | The client coordinates to convert. |
|
protected |
Releases the unmanaged resources used by the T:System.Windows.Forms.Control and its child controls and optionally releases the managed resources.
disposing | true to release both managed and unmanaged resources; false to release only unmanaged resources. |
|
protectedvirtual |
Gets the document bounds.
Implements PdfiumViewer.PanningZoomingScrollControl.
Rectangle PdfiumViewer.PdfRenderer.GetOuterBounds | ( | int | page | ) |
Get the outer bounds of the page.
page | The page to get the bounds for. |
void PdfiumViewer.PdfRenderer.Load | ( | IPdfDocument | document | ) |
Load a IPdfDocument into the control.
document | Document to load. |
|
protected |
Raises the E:System.Windows.Forms.Control.Layout event.
levent | A T:System.Windows.Forms.LayoutEventArgs that contains the event data. |
|
protectedvirtual |
Called when a link is clicked.
e | The event args. |
|
protected |
Raises the E:System.Windows.Forms.Control.MouseDown event.
e | A T:System.Windows.Forms.MouseEventArgs that contains the event data. |
|
protected |
Raises the E:System.Windows.Forms.Control.MouseUp event.
e | A T:System.Windows.Forms.MouseEventArgs that contains the event data. |
|
protected |
Raises the E:System.Windows.Forms.Control.Paint event.
e | A T:System.Windows.Forms.PaintEventArgs that contains the event data. |
|
protectedvirtual |
Called whent he cursor changes.
e | The event args. |
Reimplemented from PdfiumViewer.PanningZoomingScrollControl.
|
protectedvirtual |
Called when the zoom level changes.
e | The event args. |
Reimplemented from PdfiumViewer.PanningZoomingScrollControl.
Point PdfiumViewer.PdfRenderer.PointFromPdf | ( | PdfPoint | point | ) |
Converts a PDF point to a client point.
point | The PDF point to convert. |
PdfPoint PdfiumViewer.PdfRenderer.PointToPdf | ( | Point | location | ) |
Converts client coordinates to PDF coordinates.
location | Client coordinates to get the PDF location for. |
void PdfiumViewer.PdfRenderer.RotateLeft | ( | ) |
Rotate the PDF document left.
void PdfiumViewer.PdfRenderer.RotateRight | ( | ) |
Rotate the PDF document right.
void PdfiumViewer.PdfRenderer.ScrollIntoView | ( | PdfRectangle | bounds | ) |
Scroll the PDF bounds into view.
bounds | The PDF bounds to scroll into view. |
void PdfiumViewer.PdfRenderer.ScrollIntoView | ( | Rectangle | rectangle | ) |
Scroll the client rectangle into view.
rectangle | The client rectangle to scroll into view. |
|
protectedvirtual |
Called when the zoom level changes.
zoom | The new zoom level. |
focus | The location to focus on. |
Reimplemented from PdfiumViewer.PanningZoomingScrollControl.
|
get |
The associated PDF document.
|
get |
Gets a collection with all markers.
|
getset |
Gets or sets the currently focused page.
|
getset |
Gets or sets the current rotation of the PDF document.
|
getset |
Gets or sets a value indicating whether the user can give the focus to this control using the TAB key.
<filterpriority>1</filterpriority><PermissionSet><IPermission class="System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"><IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"><IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode, ControlEvidence"><IPermission class="System.Diagnostics.PerformanceCounterPermission, System, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true"></PermissionSet>
|
getset |
Gets or sets the way the document should be zoomed initially.
LinkClickEventHandler PdfiumViewer.PdfRenderer.LinkClick |
Occurs when a link in the pdf document is clicked.