Getting window size (correctly)
- From: bcorr <bcorr micron com>
- To: "'gtk-perl-list gnome org'" <gtk-perl-list gnome org>
- Subject: Getting window size (correctly)
- Date: Fri, 10 May 2002 05:07:45 -0600
I am having trouble with getting the window size using the following code:
$widgets->{'ephemeral'}->show_all();
my @args = $widgets->{'ephemeral'}->window->get_geometry();
print join " ", @args, "\n";
Where 'ephemeral' is a Window containing a ScrolledWindow containing a Text
widget.
When this is run I get the following reported :
0 0 200 200 8
200 x 200, being the width and height. Unfortunately this is wrong.
I added a callback to report the same data if I press a key in the window,
this gives me the correct dimensions (i.e the ones I set using 'usize').
I have tried doing a main_iteration while events_pending type wait just in
case something was out od sync, but it still makes no difference.
I have also tried ->get_toplevel->window->get_geometry(); and get_size();
Anyone got any ideas?
Cheers,
Bill.
PS I am using Gtk Perl 0.7008 on CDE/Solaris.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]