Abstract interface to a HTML rendering window (such as wx.html.HtmlWindow or wx.html.HtmlListBox) that is passed to wx.html.HtmlWinParser.
It encapsulates all communication from the parser to the window.
Ctor. |
|
Returns background colour to use by default. |
|
Returns mouse cursor of given type. |
|
Returns the window used for rendering (may be |
|
Converts coordinates pos relative to given cell to physical coordinates in the window. |
|
Called when a link is clicked. |
|
Called when the parser needs to open another URL (e.g. |
|
Sets window’s background to colour clr. |
|
Sets window’s background to given bitmap. |
|
Sets status bar text. |
|
Called by the parser to set window’s title to given text. |
See |
wx.html.
HtmlWindowInterface
(object)¶Possible constructors:
HtmlWindowInterface() -> None
Abstract interface to a HTML rendering window (such as HtmlWindow or HtmlListBox) that is passed to HtmlWinParser.
__init__
(self)¶Ctor.
None
GetHTMLBackgroundColour
(self)¶Returns background colour to use by default.
Colour
GetHTMLCursor
(self, type : HtmlWindowInterface.HTMLCursor)¶Returns mouse cursor of given type.
type (HtmlWindowInterface.HTMLCursor) –
Cursor
GetHTMLWindow
(self)¶Returns the window used for rendering (may be None
).
Window
HTMLCoordsToWindow
(self, cell : HtmlCell, pos : Point)¶Converts coordinates pos relative to given cell to physical coordinates in the window.
cell (wx.html.HtmlCell) –
pos (wx.Point) –
Point
OnHTMLLinkClicked
(self, link : HtmlLinkInfo)¶Called when a link is clicked.
link (wx.html.HtmlLinkInfo) – information about the clicked link
None
OnHTMLOpeningURL
(self, type : HtmlURLType, url : str)¶Called when the parser needs to open another URL (e.g.
an image).
type (HtmlURLType) – Type of the URL request (e.g. image)
url (string) – URL the parser wants to open
If the return value is wx.html.HTML_REDIRECT
, then the URL to redirect to will be stored in this variable (the pointer must never be None
)
Tuple[HtmlOpeningStatus, str]
indicator of how to treat the request
SetHTMLBackgroundColour
(self, clr : Colour)¶Sets window’s background to colour clr.
clr (wx.Colour) –
None
SetHTMLBackgroundImage
(self, bmpBg : BitmapBundle)¶Sets window’s background to given bitmap.
bmpBg (wx.BitmapBundle) –
None
SetHTMLStatusText
(self, text : str)¶Sets status bar text.
text (string) –
None
SetHTMLWindowTitle
(self, title : str)¶Called by the parser to set window’s title to given text.
title (string) –
None
HTMLBackgroundColour
¶HTMLWindow
¶See GetHTMLWindow