wxWidgets: wxHtmlWindowInterface Class Reference

| Version: 3.0.2

- Main Page
- Related Pages
- Categories
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | List of all members
wxHtmlWindowInterface Class Referenceabstract

`#include <wx/html/htmlwin.h>`

Inheritance diagram for wxHtmlWindowInterface:
[legend]

## Detailed Description

Abstract interface to a HTML rendering window (such as wxHtmlWindow or wxHtmlListBox) that is passed to wxHtmlWinParser.

It encapsulates all communication from the parser to the window.

## Public Types
enum | HTMLCursor { HTMLCursor_Default, HTMLCursor_Link, HTMLCursor_Text }
| Type of mouse cursor. More...

## Public Member Functions
| wxHtmlWindowInterface ()
| Ctor.
virtual | ~wxHtmlWindowInterface ()
virtual void | SetHTMLWindowTitle (const wxString &title)=0
| Called by the parser to set window's title to given text.
virtual void | OnHTMLLinkClicked (const wxHtmlLinkInfo &link)=0
| Called when a link is clicked.
virtual wxHtmlOpeningStatus | OnHTMLOpeningURL (wxHtmlURLType type, const wxString &url, wxString *redirect) const =0
| Called when the parser needs to open another URL (e.g.
virtual wxPoint | HTMLCoordsToWindow (wxHtmlCell *cell, const wxPoint &pos) const =0
| Converts coordinates pos relative to given cell to physical coordinates in the window.
virtual wxWindow * | GetHTMLWindow ()=0
| Returns the window used for rendering (may be NULL).
virtual wxColour | GetHTMLBackgroundColour () const =0
| Returns background colour to use by default.
virtual void | SetHTMLBackgroundColour (const wxColour &clr)=0
| Sets window's background to colour clr.
virtual void | SetHTMLBackgroundImage (const wxBitmap &bmpBg)=0
| Sets window's background to given bitmap.
virtual void | SetHTMLStatusText (const wxString &text)=0
| Sets status bar text.
virtual wxCursor | GetHTMLCursor (wxHtmlWindowInterface::HTMLCursor type) const =0
| Returns mouse cursor of given type.

## Member Enumeration Documentation

enum wxHtmlWindowInterface::HTMLCursor

Type of mouse cursor.

Enumerator:

  HTMLCursor_Default | Standard mouse cursor (typically an arrow)
  HTMLCursor_Link | Cursor shown over links.
  HTMLCursor_Text | Cursor shown over selectable text.

## Constructor & Destructor Documentation

wxHtmlWindowInterface::wxHtmlWindowInterface | ( |  | ) |

Ctor.

virtual wxHtmlWindowInterface::~wxHtmlWindowInterface | ( |  | ) |
| virtual

## Member Function Documentation

virtual wxColour wxHtmlWindowInterface::GetHTMLBackgroundColour | ( |  | ) | const
| pure virtual

Returns background colour to use by default.

virtual wxCursor wxHtmlWindowInterface::GetHTMLCursor | ( | wxHtmlWindowInterface::HTMLCursor | type | ) | const
| pure virtual

Returns mouse cursor of given type.

virtual wxWindow* wxHtmlWindowInterface::GetHTMLWindow | ( |  | ) |
| pure virtual

Returns the window used for rendering (may be NULL).

virtual wxPoint wxHtmlWindowInterface::HTMLCoordsToWindow | ( | wxHtmlCell * | cell,
|  | const wxPoint & | pos
| ) |  | const
| pure virtual

Converts coordinates pos relative to given cell to physical coordinates in the window.

virtual void wxHtmlWindowInterface::OnHTMLLinkClicked | ( | const wxHtmlLinkInfo & | link | ) |
| pure virtual

Called when a link is clicked.

Parameters

  link | information about the clicked link

virtual wxHtmlOpeningStatus wxHtmlWindowInterface::OnHTMLOpeningURL | ( | wxHtmlURLType | type,
|  | const wxString & | url,
|  | wxString * | redirect
| ) |  | const
| pure virtual

Called when the parser needs to open another URL (e.g.

an image).

Parameters

  type | Type of the URL request (e.g. image)
  url | URL the parser wants to open
  redirect | If the return value is wxHTML_REDIRECT, then the URL to redirect to will be stored in this variable (the pointer must never be NULL)

Returns
  indicator of how to treat the request

virtual void wxHtmlWindowInterface::SetHTMLBackgroundColour | ( | const wxColour & | clr | ) |
| pure virtual

Sets window's background to colour clr.

virtual void wxHtmlWindowInterface::SetHTMLBackgroundImage | ( | const wxBitmap & | bmpBg | ) |
| pure virtual

Sets window's background to given bitmap.

virtual void wxHtmlWindowInterface::SetHTMLStatusText | ( | const wxString & | text | ) |
| pure virtual

Sets status bar text.

virtual void wxHtmlWindowInterface::SetHTMLWindowTitle | ( | const wxString & | title | ) |
| pure virtual

Called by the parser to set window's title to given text.