[Xfc-dev] xfc questions

Xavier Otazu xotazu at cvc.uab.es
Fri Aug 19 17:21:50 CEST 2005


	Hi Jeff:


> >- When defining a button image it is mandatory to define its label.
> >  
> >
> No. There are two image constructors:
> 
> Button(Widget& image);
> Button(Widget& image, const String& label, bool use_underline =
> false);
> 
[...]
> >When rendering the new button image, button size changes because of
> >the label even when it is defined as a "" string.
> >
> >  
> >
> This is a GTK+ issue. If your never set any button label text GTK
> does not create a label widget. Once you set the button text a label
> widget is created for the text. Thereafter, even if you reset the
> label to "", the  label widget is still there, taking up space, and
> wont be destroyed until the button is destroyed.
> 

	Excuse me, in my last e-mail I didn't tell it right.

	I define a button (a MEDIA_PLAY from Gtk stock) using glade. I
"import" it in my code using the Xfc::Glade xml object as you tell in
your tutorials and it works fine. Hence, I do not explicitly use the
constructors.

	The problem appears when I want to change the button image from
MEDIA_PLAY to MEDIA_PAUSE. I use the set_image() method, but as you
tell in the tutorial it is mandatory to previously define the label for
the button. I cannot change button image without defining the label,
which I define as "". If I do not define this label, button image do
not change.

	What is the way to change a button image with no label defined?


> >
> This is a GTK+ issue. Maybe this will help: 
> http://mail.gnome.org/archives/gtk-perl-list/2003-September/msg00197.html. 
> Let me know.

	Thanks.

> 
> >- It is not possible to compile a static executable because
> >libXFCglade only exists as shared library. I receive:
> >
> >/usr/local/bin/ld: cannot find -lXFCglade-4.3
> >  
> >
> By default XFC static builds are disabled. If you want to build a
> static executable you have to run ./configure with the
> --enable-static option.

	I tried to compile the code with my own makefile (I didn't use
the autoconf generated makefile) and I used the -static flag. I
searched for the static version of libGlade but I didn't find it. I
will try with this option.

> This is programming issue. You have to set the scrollbar policy for
> the scrolled window. The default is GTK_POLICY_ALWAYS which means
> that both the horizontal and vertical scrollbars will always appear

	Thanks, it worked! But finally I think I will not use this
feature, because too long text may resize window to 'stupid' big
sizes .

> 
> >- I 'sense' a connection between uimanager and glade Xml parser
> >object.
> >  
> >
> No you don't... there isn't one.
> 

	Feelings and intuition is sometimes wrong ... ;-)


	Thanks!


cheers,

Xavier



More information about the Xfc-dev mailing list