[gtkmm] getting the size of a widget



Sometimes you need to find the size of a widget.  I use this and it works.

	GtkRequisition requisition = { 0, 0 };
	widget.size_request( &requisition );
	pWidth = requisition.width;
	pHeight = requisition.height;

Just wanted to provide this to the list as documentation.  Someone who's
maintaining the tutorial or the exmaple code, might consider adding this
to those resources.

   Cheers and best wishes,
       Erik.




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