Re: gtk.HTML class nonexistent [was: Re: [pygtk] Computing optimum size of gtkhtml2.View]
- From: "Luke Kenneth Casson Leighton" <luke leighton googlemail com>
- To: "Sven Neumann" <sven gimp org>
- Cc: Luke Kenneth Casson Leighton <lkcl lkcl net>, gtk-devel-list gnome org
- Subject: Re: gtk.HTML class nonexistent [was: Re: [pygtk] Computing optimum size of gtkhtml2.View]
- Date: Fri, 15 Aug 2008 23:29:20 +0000
>> What's wrong with using gtk.Label("<b>hello</b>", use_markup=True) ?
>
> haven't got a clue - inexperience led me to believe that didn't exist? :)
ok - couldn't wait until tomorrow. i found out why it can't be used:
pango markup doesn't support the full syntax of HTML that applications
would expect to use. < div > and < code > - basic HTML tags - aren't
supported.
also, some apps use the (awful) < a href= "javascript:return false;"
> click here < /a> trick to create a hyperlink, purely to get the
cursor to change to "link". then they capture "click" signals on the
Label (yes i found out about the trick of creating an Event box around
Labels :).
python-gtkhtml2 was adequate to support this kind of trick, as is
pywebkitgtk. Label.set_use_markup would, unfortunately, not do the
trick.
worth exploring, though - thanks sven.
l.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]