Re: Size of widget
- From: learfox furry ao net
- To: Fredrik Rambris <fredrik rambris com>
- Cc: GTK Application Development List <gtk-app-devel-list gnome org>
- Subject: Re: Size of widget
- Date: Thu, 4 Jan 2001 14:17:51 -0800 (PST)
How do I get the current size of a widget? (Like a GtkFixed).
Also. Anyone know of a containerwidget that wraps the children kindof
like a wordprocessor does with the words? Like icons in gmc but it
should be any widgets.
When yer definatly sure the widget has the right size you want, use
w = GTK_WIDGET(fixed);
if(w != NULL)
{
width = w->allocation.width;
height = w->allocation.height;
}
One thing I should point out that w->allocation.x and w->allocation.y are
not quite useful as they are relative to their immediate parent *windows*
(not widgets) and not very useful in most cases.
--
Sincerely, ,"-_ \|/
-Capt. Taura M. , O=__ --X--
..__ ,_JNMNNEO=_ /|\
OMNOUMmnne. {OMMNNNEEEEOO=_
UOOOBIOOOEOMMn. 'LONMMMMNNEEEOOO=.__..,,..
UUOOEUUOOOOOOOObe '"=OMMMMWNEEEOOOOO,"=OEEEOO=,._
OOUUUIEEIOONNOIUbe. "7OMMMMNNNNNWWEEEEOOOOOO" "'.
EEBNNMMMNWNWWEEIMMNe. __ 7EMMMNNNNNWWWEEEEEEEOO. " .
NNMMMMWWWMMMWEINMMMNn "=BBEEEEMMMMMMMMNNNWWWEEOOOOO=._ .
http://furry.ao.net/~learfox/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]