- class QPdfLinkModel¶
The
QPdfLinkModel
class holds the geometry and the destination for each link that the specifiedpage
contains. More…Added in version 6.6.
Synopsis¶
Properties¶
Methods¶
def
__init__()
def
document()
def
linkAt()
def
page()
Slots¶
def
setDocument()
def
setPage()
Signals¶
def
pageChanged()
Note
This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE
Detailed Description¶
This is used in PDF viewers to implement the hyperlink mechanism.
- class Role¶
Constant
Description
QPdfLinkModel.Role.Link
A
QPdfLink
object.QPdfLinkModel.Role.Rectangle
Bounding rectangle around the link.
QPdfLinkModel.Role.Url
If the link is a web link, the URL for that; otherwise an empty URL.
QPdfLinkModel.Role.Page
If the link is an internal link, the page number to which the link should jump; otherwise
-1
.QPdfLinkModel.Role.Location
If the link is an internal link, the location on the page to which the link should jump.
QPdfLinkModel.Role.Zoom
If the link is an internal link, the suggested zoom level on the destination page.
Note
Properties can be used directly when
from __feature__ import true_property
is used or via accessor functions otherwise.- property documentᅟ: QPdfDocument¶
This property holds The document to load links from..
- Access functions:
- property pageᅟ: int¶
This property holds The page to load links from..
- Access functions:
Signal
pageChanged()
Constructs a new link model with parent object
parent
.- document()¶
- Return type:
See also
Getter of property
documentᅟ
.- documentChanged()¶
Notification signal of property
documentᅟ
.Returns a
valid
link if found under thepoint
(given in units of points, 1/72 of an inch), or an invalid link if it is not found. In other words, this function is useful for picking, to handle mouse click or hover.Getter of property
pageᅟ
.- pageChanged(page)¶
- Parameters:
page – int
Notification signal of property
pageᅟ
.- setDocument(document)¶
- Parameters:
document –
QPdfDocument
See also
Setter of property
documentᅟ
.Setter of property
pageᅟ
.