canvas and html



Hello,

incidentially just a few days ago I hacked together a small library
that allows embedding of gtk widgets into gecko based browsers (and
presumably others that support the netscape plugin API). It's really
just a quick hack but may serve for prototyping widget/html/css stuff.

How to get it:
bzr get http://robsta.rsm-freilassing.de/projects/gtk-np
"make install" does not work yet, copy libgtknp.so to a directory your
browser is looking for plugins.

How does it work (example from tests/button.html):
<object type="widget/x-GtkButton" style="border:1px solid black;
height:100px; width:200px">
<param name="label" value="hallo" />
<param name="xalign" value="1" />
<param name="yalign" value="1" />
</object>
the PARAMs are mapped to corresponding gobject properties, other
interaction with the widgets is not yet possible (eventually I'm
hoping to hook up mozilla's emerging python support).

Needless saying that blending Alexander Larsson's offscreen widget
drawing patch and gecko's support for windowless plugins is on the
roadmap ;-)

Somewhat related I'm wondering whether there is a way to have gtk
register its gobjects/widgets so they can be instantiated by name (or
the chances for a patch that introduced something like "GType
gtk_type_from_name (const gchar *name)"). Heck, maybe gobject based
libs could install a factory method into the gobject system to allow
querying for previously unregistered named types?

Best,
Rob



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]