Re: glibmm / maemo and GLIBMM_ENABLE_PROPERTIES



On Tue, 2008-02-05 at 10:34 +0000, Luca Ognibene wrote:
> Hi! I'm trying to port inkscape (uses glibmm/gtkmm) to maemo (www.maemo.org).
> After seeing that it doesn't compile i've discovered that glibmm and gtkmm
> are compiled w/o some API in maemo. May i ask why? Optimization?

Yes.

>  Is
> the speed/memory gain so strong and useful?

It's a code size reduction which reduces memory use and start up time. I
believe it's worthwhile, but you might not and that's OK.

> I'm not a c++ developer but i'm a full time developer on linux and i
> wanted to port inkscape. I've ported a lot of other programs  w/o much
> effort but this API difference between maemo and desktop pc in glibmm
> is quite hard to fix for a non c++ developer.
> I've fixed most obvious problem, but for example.. how can i fix this?
> 
> class ImageToggler : public Gtk::CellRendererPixbuf {
> public:
>  ImageToggler( char const* on, char const* off) :
>    Glib::ObjectBase(typeid(ImageToggler)),
>    Gtk::CellRendererPixbuf(),
>    _pixOnName(on),
>    _pixOffName(off),
>    _property_active (*this, "active", false),
>    _property_activatable(*this, "activatable", true),
>    _property_pixbuf_on(*this, "pixbuf_on", Glib::RefPtr<Gdk::Pixbuf>(0)),
>    _property_pixbuf_off(*this, "pixbuf_off", Glib::RefPtr<Gdk::Pixbuf>(0))

This seems to be adding GTK+ properties, which is fairly unusual (but
entirely valid). For Maemo it should probably be done with the GTK+ API
instead, using g_object_class_install_property() as in GTK+ itself. I'm
sure that other Inkscape developers will know how to do that.

> Errors are:
> dialogs/layers-panel.cpp:76: error: class
> `Inkscape::UI::Dialogs::ImageToggler' does not have any field named
> `_property_active'
> 
> Do you plan to begin to compile glibmm/gtkmm with standard api anytime soon? 
> Speed and memory in maemo tablets are going to increase, 
> developer's free time is always short :)

Probably yes, but not for the current version of Maemo and the current
hardware.

If you don't solve these problems, then I'd be glad to help at some
point in the next few weeks, if you can supply a patch of what you haev
so far.

-- 
murrayc murrayc com
www.murrayc.com
www.openismus.com



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