[Glade-devel] [Glade] External library
Joaquin Cuenca Abela
e98cuenc@yahoo.com
Fri, 13 Aug 2004 02:03:28 -0700 (PDT)
--- Cornet Mickael <mickael_cornet@yahoo.fr> wrote:
> --- Joaquin Cuenca Abela <e98cuenc@yahoo.com> a
> écrit
> :
> >
> > --- Cornet Mickael <mickael_cornet@yahoo.fr>
> wrote:
> >
> > > Thank you Shane,
> > >
> > > I study the gtk-base.xml and the glade-gtk.c
> files
> > > and
> > > there is the library parameter. I think I have
> to
> > > write my own files (.xml + .c) to use my
> library.
> >
> > Please note that if your graphic library is not
> > based
> > in gtk (ie, you should implement gtk widgets),
> then
> > you will not be able to use it in glade3.
> >
> > The mechanism in place only helps to insulate
> glade3
> > from the specifics of gtkwidgets, but not from the
> > specifics of any graphic library whatsoever.
> >
> > If your library is gtk+ based, then I can give you
> a
> > sample of what needs to be done to make it work.
> >
> > Cheers,
>
> Ok, my library is not based on GTK but I would like
> to
> adapt GTK widgets to my library properties in order
> to
> generate glade (xml) files that I will convert with
> a
> script to c code for my applications, do you think
> it
> can be possible with Glade3?
Nope. I don't understand everything (adapt gtk widgets
to your library properties??), but you should note
that glade3 should discover the properties of your
widgets.
Glade3 does it using the reflection mechanisms
provided in gtk+, so if your widgets don't show its
properties that way, glade3 is not gonna see anything.
The xml files are just there to specify some details
of the properties that can't be expressed in gtk+, or
to add some fake properties.
To discover the widgets in your library, glade3 is
basically gonna look in the catalogs for widgets to
instanciate, and it will instanciate it using the
widgetname_type_init (not sure about the exact
name...)
So if your widgets are not gtk+ widgets, that's not
gonna work at all.
Cheers,
=====
Joaquin Cuenca Abela
e98cuenc at yahoo dot com
__________________________________
Do you Yahoo!?
Yahoo! Mail - 50x more storage than other providers!
http://promotions.yahoo.com/new_mail