Hi, group,
Here is an about dialog (see attached code) using HtmlWindow control copied from bundled demo. I just added a "mailto" link and a "http" link in the html source, however, it seems does not work as expected. When I click the "mailto" link, it shows an error: "Unable to open requested HTML document:....". When I click a "http" link, I expect it will open in default browser, but the page will be only displayed on the dialog itself, even though I use "target=_blank" for the link. What could be the possible solution here? Thanks in advance.
Hi, group,
Here is an about dialog (see attached code) using HtmlWindow control copied from bundled demo. I just added a "mailto" link and a "http" link in the html source, however, it seems does not work as expected. When I click the "mailto" link, it shows an error: "Unable to open requested HTML document:....". When I click a "http" link, I expect it will open in default browser, but the page will be only displayed on the dialog itself, even though I use "target=_blank" for the link. What could be the possible solution here? Thanks in advance.
wxHtmlWindow is not a full-feldged browser. It is mainly concerned with layout of a simple HTML subset, not with fully integrating with your system. To do what you want you need derive a class from wxHtmlWindow and override its OnLinkClicked method. Then you can do whatever you want with the link yourself.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!