diff options
author | damien <damien@mandriva.com> | 2002-01-11 12:59:42 +0000 |
---|---|---|
committer | damien <damien@mandriva.com> | 2002-01-11 12:59:42 +0000 |
commit | b21b0c38599bfa70e1d5610713ca22aa9ed3c04a (patch) | |
tree | 66f09b09e781a2023126085d8c76c1887db45af7 /perl-install | |
parent | f5b7bbbae268f86a6b8276464f99fe07fcbd7700 (diff) | |
download | drakx-backup-do-not-use-b21b0c38599bfa70e1d5610713ca22aa9ed3c04a.tar drakx-backup-do-not-use-b21b0c38599bfa70e1d5610713ca22aa9ed3c04a.tar.gz drakx-backup-do-not-use-b21b0c38599bfa70e1d5610713ca22aa9ed3c04a.tar.bz2 drakx-backup-do-not-use-b21b0c38599bfa70e1d5610713ca22aa9ed3c04a.tar.xz drakx-backup-do-not-use-b21b0c38599bfa70e1d5610713ca22aa9ed3c04a.zip |
new icons placement
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/my_gtk.pm | 42 |
1 files changed, 32 insertions, 10 deletions
diff --git a/perl-install/my_gtk.pm b/perl-install/my_gtk.pm index 756e43db7..8ba40f468 100644 --- a/perl-install/my_gtk.pm +++ b/perl-install/my_gtk.pm @@ -621,8 +621,9 @@ sub create_box_with_title($@) { $o->{box_size} = sum(map { round(length($_) / 60 + 1/2) } map { split "\n" } @_); $o->{box} = new Gtk::VBox(0,0); - $o->{icon} && !$::isWizard and eval { gtkpack__($o->{box}, gtkset_border_width(gtkpack_(new Gtk::HBox(0,0), 1, gtkpng($o->{icon})),5)); }; if (@_ <= 2 && $o->{box_size} > 4) { + $o->{icon} && !$::isWizard and + eval { gtkpack__($o->{box}, gtkset_border_width(gtkpack_(new Gtk::HBox(0,0), 1, gtkpng($o->{icon})),5)); }; my $wanted = n_line_size($o->{box_size}, 'text', $o->{box}); my $height = min(250, $wanted); my $has_scroll = $height < $wanted; @@ -636,15 +637,36 @@ sub create_box_with_title($@) { } else { my $a = !$::no_separator; undef $::no_separator; - gtkpack__($o->{box}, - (map { - my $w = ref $_ ? $_ : new Gtk::Label($_); - $::isWizard and $w->set_justify("left"); - $w->set_name("Title"); - $w; - } map { ref $_ ? $_ : warp_text($_) } @_), - if_($a, new Gtk::HSeparator) - ); + if ($o->{icon} && !$::isWizard) { + gtkpack__($o->{box}, + gtkpack_(new Gtk::HBox(0,0), + 0, gtkset_usize(new Gtk::VBox(0,0), 15, 0), + 0, eval { gtkpng($o->{icon}) }, + 0, gtkset_usize(new Gtk::VBox(0,0), 15, 0), + 1, gtkpack_($o->{box_title} = new Gtk::VBox(0,0), + 1, new Gtk::HBox(0,0), + (map { + my $w = ref $_ ? $_ : new Gtk::Label($_); + $::isWizard and $w->set_justify("left"); + $w->set_name("Title"); + (0, $w); + } map { ref $_ ? $_ : warp_text($_) } @_), + 1, new Gtk::HBox(0,0), + ) + ), + if_($a, new Gtk::HSeparator) + ) + } else { + gtkpack__($o->{box}, + (map { + my $w = ref $_ ? $_ : new Gtk::Label($_); + $::isWizard and $w->set_justify("left"); + $w->set_name("Title"); + $w; + } map { ref $_ ? $_ : warp_text($_) } @_), + if_($a, new Gtk::HSeparator) + ) + } } } |