Re: How can I get the size of a container ???
- From: Bob Caryl <bob fis-cal com>
- To: Sergio Trinidad <strinidadr gmail com>
- Cc: gtkmm-list gnome org
- Subject: Re: How can I get the size of a container ???
- Date: Thu, 15 Dec 2005 07:47:37 -0600
Use the Gtk::Widget::get_window method (call it from your label) to get
a Glib::RefPtr<Gdk::Window>. Then call the Gdk::Window::get_geometry
method to get the dimensions of your label.
See
http://www.gtkmm.org/docs/gtkmm-2.4/docs/reference/html/classGdk_1_1Window.html#21f77b9b5019c6ab828bfeb943206ee2
for info on get_geometry.
Bob
Sergio Trinidad wrote:
> Hello,
>
> I have a label inside a vbox, and i need to know the height of the label
> or the vbox to change the size of the text to fill all available area when
> the size of the label changes.
>
> I do this with on_configure_event but it seems to only work with a window
> and not with a vbox. Any solution ?
>
> Thanks in advance
>
>------------------------------------------------------------------------
>
>_______________________________________________
>gtkmm-list mailing list
>gtkmm-list gnome org
>http://mail.gnome.org/mailman/listinfo/gtkmm-list
>
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]