Getting HTML tag from cell

I would like to popup a tooltip window when a user hovers over an
image in my wxHtmlWindow. The OnCellMouseHover method tells me
the hovering is happening and supplies the wxHtmlCell. However there
seems no way to go from that back to the original tag (the information
I need is in the ALT attribute).

Since I generate the HTML internally I can change the markup in any
way if that makes it easier.

Incidentally the GetId method isn't wrapped, but SetId is.

Roger

Roger Binns wrote:

I would like to popup a tooltip window when a user hovers over an
image in my wxHtmlWindow. The OnCellMouseHover method tells me
the hovering is happening and supplies the wxHtmlCell. However there
seems no way to go from that back to the original tag (the information
I need is in the ALT attribute).

I don't know. Vaclav?

Incidentally the GetId method isn't wrapped, but SetId is.

In which class?

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Incidentally the GetId method isn't wrapped, but SetId is.

In which class?

wxHtmlCell. (I was hoping that I could put ID="blah blah" in the HTML
tag and see the same id in wxHtmlCell.GetId :slight_smile:

Roger

Roger Binns wrote:

wxHtmlCell. (I was hoping that I could put ID="blah blah" in the
HTML tag and see the same id in wxHtmlCell.GetId :slight_smile:

In theory yes. In practice, this was only implemented for <img> so
far.

VS

···

--
PGP key: 0x465264C9, available from http://pgp.mit.edu/

Hi,

Robin Dunn wrote:

> I would like to popup a tooltip window when a user hovers over an
> image in my wxHtmlWindow. The OnCellMouseHover method tells me
> the hovering is happening and supplies the wxHtmlCell. However
> there seems no way to go from that back to the original tag (the
> information I need is in the ALT attribute).

I don't know. Vaclav?

That's true, the tag information (and parsing tree) was discarded when
parsing finished. I don't know how to work around this, other then
writing own tag handler (if wxPython supports it). But it would be
nice to have some callback mechanism in wxHtmlParser that would let
you associate tags with cells...

VS

···

--
PGP key: 0x465264C9, available from http://pgp.mit.edu/