summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perl-install/mygtk3.pm2
-rwxr-xr-xperl-install/standalone/harddrake26
-rw-r--r--perl-install/ugtk3.pm12
3 files changed, 10 insertions, 10 deletions
diff --git a/perl-install/mygtk3.pm b/perl-install/mygtk3.pm
index 9c6fccce4..0c4798e4c 100644
--- a/perl-install/mygtk3.pm
+++ b/perl-install/mygtk3.pm
@@ -420,7 +420,7 @@ sub _gtk__Label {
$w->set_justify(delete $opts->{justify}) if exists $opts->{justify};
$w->set_line_wrap(delete $opts->{line_wrap}) if exists $opts->{line_wrap};
$w->set_alignment(@{delete $opts->{alignment}}) if exists $opts->{alignment};
- $w->modify_font(Gtk2::Pango::FontDescription->from_string(delete $opts->{font})) if exists $opts->{font};
+ $w->modify_font(Pango::FontDescription->from_string(delete $opts->{font})) if exists $opts->{font};
}
if (my $text_ref = delete $opts->{text_ref}) {
diff --git a/perl-install/standalone/harddrake2 b/perl-install/standalone/harddrake2
index bd1bcd9d0..4a605c480 100755
--- a/perl-install/standalone/harddrake2
+++ b/perl-install/standalone/harddrake2
@@ -309,7 +309,7 @@ $tree->get_selection->signal_connect('changed' => sub {
($current_device, $current_class) = @{$data[$idx]};
if ($idx ne -1) {
- use Gtk2::Pango;
+ use Pango;
my %device_fields = map {
# The U+200E character is to force LTR display, as what what follows the colon is always in LTR (device names, paths, etc),
# this ensures proper displaying of names like /dev/fd0 (otherwise it gets 'dev/fd0/').
@@ -317,7 +317,7 @@ $tree->get_selection->signal_connect('changed' => sub {
my $field = lookup_field($_);
if_($_ && $field->[0], $_ =>
[
- [ $field->[0] . ": \x{200e}", { 'foreground' => 'royalblue3', 'weight' => Gtk2::Pango->PANGO_WEIGHT_BOLD } ],
+ [ $field->[0] . ": \x{200e}", { 'foreground' => 'royalblue3', 'weight' => Pango->PANGO_WEIGHT_BOLD } ],
[ ($current_device->{$_} =~ /^(unknown)/ ? N("unknown") :
$current_device->{$_} =~ /^(Unknown)/ ? N("Unknown") :
$current_device->{$_} eq 'yes' ? N("Yes") :
@@ -569,7 +569,7 @@ sub lookup_field {
sub titleFormat {
my ($title) = @_;
- [ $title . "\n", { 'weight' => Gtk2::Pango->PANGO_WEIGHT_BOLD, scale => Gtk2::Pango->PANGO_SCALE_LARGE } ];
+ [ $title . "\n", { 'weight' => Pango->PANGO_WEIGHT_BOLD, scale => Pango->PANGO_SCALE_LARGE } ];
}
sub force_rename_field {
diff --git a/perl-install/ugtk3.pm b/perl-install/ugtk3.pm
index d1db5ed79..9ad1cc2cb 100644
--- a/perl-install/ugtk3.pm
+++ b/perl-install/ugtk3.pm
@@ -310,9 +310,9 @@ sub markup_to_TextView_format {
foreach (@$l) {
my ($_txt, $attrs) = @$_;
if ($attrs) {
- $attrs->{weight} eq 'bold' and $attrs->{weight} = do { require Gtk2::Pango; Gtk2::Pango->PANGO_WEIGHT_BOLD };
+ $attrs->{weight} eq 'bold' and $attrs->{weight} = do { require Pango; Pango->PANGO_WEIGHT_BOLD };
$attrs->{size} eq 'larger' and do {
- $attrs->{scale} = Gtk2::Pango->scale_x_large; # equivalent to Label's size => 'larger'
+ $attrs->{scale} = Pango->scale_x_large; # equivalent to Label's size => 'larger'
delete $attrs->{size};
};
}
@@ -349,7 +349,7 @@ sub create_box_with_title {
my $scroll = gtknew('ScrolledWindow', child => $wtext, width => $width, height => 200);
$scroll->signal_connect(realize => sub {
my $layout = $wtext->create_pango_layout($text);
- $layout->set_width(($width - 10) * Gtk2::Pango->scale);
+ $layout->set_width(($width - 10) * Pango->scale);
$wtext->set_size_request($width, min(200, second($layout->get_pixel_size) + 10));
$scroll->set_size_request($width, min(200, second($layout->get_pixel_size) + 10));
$o->{rwindow}->queue_resize;
@@ -653,14 +653,14 @@ sub gtkfontinfo {
foreach (qw(ascent descent approximate_char_width approximate_digit_width)) {
no strict;
my $func = "get_$_";
- $fontinfo{$_} = Gtk2::Pango->pixels($metrics->$func);
+ $fontinfo{$_} = Pango->pixels($metrics->$func);
}
%fontinfo;
}
sub gtkmodify_font {
my ($w, $arg) = @_;
- $w->modify_font(ref($arg) ? $arg : Gtk2::Pango::FontDescription->from_string($arg));
+ $w->modify_font(ref($arg) ? $arg : Pango::FontDescription->from_string($arg));
$w;
}
@@ -1446,7 +1446,7 @@ sub new {
$darea->{back_pixbuf} = gtknew('Pixbuf', file => 'banner-background');
my $d_height = $darea->{back_pixbuf}->get_height;
$darea->set_size_request(-1, $d_height);
- $darea->modify_font(Gtk2::Pango::FontDescription->from_string("13"));
+ $darea->modify_font(Pango::FontDescription->from_string("13"));
eval { $darea->{icon} = ugtk3::gtkcreate_pixbuf($icon) };
$darea->{icon} ||= ugtk3::gtkcreate_pixbuf(ugtk3::wm_icon());
my $blue_part = eval { gtknew('Pixbuf', file => 'banner-blue-part', flip => mygtk3::text_direction_rtl()) };