From 981d35eb8ed1922a5d90bbe8e055d912ac51bc36 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Thu, 27 Nov 2003 13:42:13 +0000 Subject: (create_packtable) enable to provide 0 parameters for xpadding and ypadding (much cleaner) --- perl-install/ugtk2.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'perl-install/ugtk2.pm') diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm index 5549346a6..92a9411f0 100644 --- a/perl-install/ugtk2.pm +++ b/perl-install/ugtk2.pm @@ -457,6 +457,7 @@ sub create_notebook { sub create_packtable { my ($options, @l) = @_; my $w = Gtk2::Table->new(0, 0, $options->{homogeneous} || 0); + add2hash_($options, { xpadding => 5, ypadding => 0 }); each_index { my ($i, $l) = ($::i, $_); each_index { @@ -465,7 +466,7 @@ sub create_packtable { ref $_ or $_ = Gtk2::Label->new($_); $j != $#$l && !$options->{mcc} ? $w->attach($_, $j, $j + 1, $i, $i + 1, - 'fill', 'fill', $options->{xpadding} || 5, $options->{ypadding} || 0) : + 'fill', 'fill', $options->{xpadding}, $options->{ypadding}) : $w->attach($_, $j, $j + 1, $i, $i + 1, ['expand', 'fill'], ref($_) eq 'Gtk2::ScrolledWindow' || $_->get_data('must_grow') ? ['expand', 'fill'] : [], 0, 0); $_->show; -- cgit v1.2.1