summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authordamien <damien@mandriva.com>2001-02-28 02:53:10 +0000
committerdamien <damien@mandriva.com>2001-02-28 02:53:10 +0000
commitf10135f75069699597108bdb6b158e0f7330b970 (patch)
tree7d4a9216735c39af49dd678830c1513d1bf0ae09 /perl-install
parentfd0b1e50cdf8068c82ce050ac85077282386cdc5 (diff)
downloaddrakx-backup-do-not-use-f10135f75069699597108bdb6b158e0f7330b970.tar
drakx-backup-do-not-use-f10135f75069699597108bdb6b158e0f7330b970.tar.gz
drakx-backup-do-not-use-f10135f75069699597108bdb6b158e0f7330b970.tar.bz2
drakx-backup-do-not-use-f10135f75069699597108bdb6b158e0f7330b970.tar.xz
drakx-backup-do-not-use-f10135f75069699597108bdb6b158e0f7330b970.zip
added gtkset_shadow_type
added auto path for png pixmap
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/my_gtk.pm10
1 files changed, 9 insertions, 1 deletions
diff --git a/perl-install/my_gtk.pm b/perl-install/my_gtk.pm
index 0570e3d81..bb9b38f76 100644
--- a/perl-install/my_gtk.pm
+++ b/perl-install/my_gtk.pm
@@ -10,7 +10,7 @@ use vars qw(@ISA %EXPORT_TAGS @EXPORT_OK $border);
@ISA = qw(Exporter);
%EXPORT_TAGS = (
helpers => [ qw(create_okcancel createScrolledWindow create_menu create_notebook create_packtable create_hbox create_vbox create_adjustment create_box_with_title create_treeitem) ],
- wrappers => [ qw(gtksignal_connect gtkpack gtkpack_ gtkpack__ gtkpack2 gtkpack3 gtkpack2_ gtkpack2__ gtksetstyle gtkappend gtkadd gtkput gtktext_insert gtkset_usize gtkset_justify gtkset_active gtkshow gtkdestroy gtkset_mousecursor gtkset_mousecursor_normal gtkset_mousecursor_wait gtkset_background gtkset_default_fontset gtkctree_children gtkxpm gtkpng gtkcreate_xpm gtkcreate_png) ],
+ wrappers => [ qw(gtksignal_connect gtkpack gtkpack_ gtkpack__ gtkpack2 gtkpack3 gtkpack2_ gtkpack2__ gtksetstyle gtkappend gtkset_shadow_type gtkadd gtkput gtktext_insert gtkset_usize gtkset_justify gtkset_active gtkshow gtkdestroy gtkset_mousecursor gtkset_mousecursor_normal gtkset_mousecursor_wait gtkset_background gtkset_default_fontset gtkctree_children gtkxpm gtkpng gtkcreate_xpm gtkcreate_png) ],
ask => [ qw(ask_warn ask_okcancel ask_yesorno ask_from_entry ask_file) ],
);
$EXPORT_TAGS{all} = [ map { @$_ } values %EXPORT_TAGS ];
@@ -179,6 +179,12 @@ sub gtkappend($@) {
}
$w
}
+
+sub gtkset_shadow_type {
+ $_[0]->set_shadow_type($_[1]);
+ $_[0];
+}
+
sub gtkadd($@) {
my $w = shift;
foreach (@_) {
@@ -268,6 +274,8 @@ sub gtkcreate_xpm {
}
sub gtkcreate_png {
my ($f) = @_;
+ $f =~ m|.png$| or $f="$f.png";
+ if ( $f !~ /\//) { -e "$_/$f" and $f="$_/$f", last foreach $ENV{SHARE_PATH}, "$ENV{SHARE_PATH}/libDrakX/pixmaps", "pixmaps" }
my $im = Gtk::Gdk::ImlibImage->load_image($f) or die "gtkcreate_png: missing png file $f";
$im->render($im->rgb_width, $im->rgb_height);
($im->move_image(), $im->move_mask);