@@ -632,7 +632,7 @@ sub setup_bottom_hbox {
632632
633633 $self -> {_font_btn_wh } = $self -> {_font_btn_w }-> signal_connect(
634634 ' font-set' => sub {
635- my $font_descr = Pango::FontDescription-> from_string($self -> {_font_btn_w }-> get_font_name);
635+ my $font_descr = Pango::FontDescription:: from_string($self -> {_font_btn_w }-> get_font_name);
636636 $self -> {_font } = $self -> {_font_btn_w }-> get_font_name;
637637
638638 if ($self -> {_current_item }) {
@@ -3190,8 +3190,9 @@ sub set_and_save_drawing_properties {
31903190 if (exists ($self -> {_items }{$key }{text })) {
31913191
31923192 # determine font description from string
3193- my ($attr_list , $text_raw , $accel_char ) = Pango-> parse_markup($self -> {_items }{$key }{text }-> get(' text' ));
3194- my $font_desc = $attr_list -> get_iterator-> get_font;
3193+ my ($ret , $attr_list , $text_raw , $accel_char ) = Pango::parse_markup($self -> {_items }{$key }{text }-> get(' text' ), -1, 0);
3194+ my $font_desc = Pango::FontDescription-> new();
3195+ $attr_list -> get_iterator-> get_font($font_desc );
31953196
31963197 # apply current font settings to button
31973198 $self -> {_font_btn_w }-> set_font_name($font_desc ? $font_desc -> to_string : $self -> {_font });
@@ -3202,8 +3203,9 @@ sub set_and_save_drawing_properties {
32023203 } elsif ($item -> isa(' GooCanvas2::CanvasText' )) {
32033204
32043205 # determine font description from string
3205- my ($attr_list , $text_raw , $accel_char ) = Pango-> parse_markup($item -> get(' text' ));
3206- my $font_desc = $attr_list -> get_iterator-> get_font;
3206+ my ($ret , $attr_list , $text_raw , $accel_char ) = Pango::parse_markup($item -> get(' text' ), -1, 0);
3207+ my $font_desc = Pango::FontDescription-> new();
3208+ $attr_list -> get_iterator-> get_font($font_desc );
32073209
32083210 # font color
32093211 $self -> {_stroke_color_w }-> set_rgba($self -> {_items }{$key }{stroke_color });
@@ -3217,7 +3219,7 @@ sub set_and_save_drawing_properties {
32173219 $self -> {_line_width } = $self -> {_line_spin_w }-> get_value;
32183220 $self -> {_stroke_color } = $self -> {_stroke_color_w }-> get_rgba;
32193221 $self -> {_fill_color } = $self -> {_fill_color_w }-> get_rgba;
3220- my $font_descr = Pango::FontDescription-> from_string($self -> {_font_btn_w }-> get_font_name);
3222+ my $font_descr = Pango::FontDescription:: from_string($self -> {_font_btn_w }-> get_font_name);
32213223 $self -> {_font } = $self -> {_font_btn_w }-> get_font_name;
32223224
32233225 # unblock 'value-change' handlers for widgets
@@ -3298,7 +3300,7 @@ sub restore_drawing_properties {
32983300 $self -> {_line_width } = $self -> {_line_spin_w }-> get_value;
32993301 $self -> {_stroke_color } = $self -> {_stroke_color_w }-> get_rgba;
33003302 $self -> {_fill_color } = $self -> {_fill_color_w }-> get_rgba;
3301- my $font_descr = Pango::FontDescription-> from_string($self -> {_font_btn_w }-> get_font_name);
3303+ my $font_descr = Pango::FontDescription:: from_string($self -> {_font_btn_w }-> get_font_name);
33023304 $self -> {_font } = $self -> {_font_btn_w }-> get_font_name;
33033305
33043306 # unblock 'value-change' handlers for widgets
@@ -4098,8 +4100,9 @@ sub show_item_properties {
40984100 $font_btn = Gtk3::FontButton-> new();
40994101
41004102 # determine font description from string
4101- my ($attr_list , $text_raw , $accel_char ) = Pango-> parse_markup($self -> {_items }{$key }{text }-> get(' text' ));
4102- my ($font_desc ) = $attr_list -> get_iterator-> get_font;
4103+ my ($ret , $attr_list , $text_raw , $accel_char ) = Pango::parse_markup($self -> {_items }{$key }{text }-> get(' text' ), -1, 0);
4104+ my $font_desc = Pango::FontDescription-> new();
4105+ $attr_list -> get_iterator-> get_font($font_desc );
41034106
41044107 # apply current font settings to button
41054108 $font_btn -> set_font_name($font_desc ? $font_desc -> to_string : $self -> {_font });
@@ -4208,8 +4211,8 @@ sub show_item_properties {
42084211 $font_btn = Gtk3::FontButton-> new();
42094212
42104213 # determine font description from string
4211- my ($attr_list , $text_raw , $accel_char ) = Pango-> parse_markup($item -> get(' text' ));
4212- my ($font_desc ) = Pango::FontDescription-> from_string($self -> {_font });
4214+ my ($ret , $ attr_list , $text_raw , $accel_char ) = Pango:: parse_markup($item -> get(' text' ), -1, 0 );
4215+ my ($font_desc ) = Pango::FontDescription:: from_string($self -> {_font });
42134216
42144217 $font_hbox -> pack_start($font_label , FALSE, TRUE, 12);
42154218 $font_hbox -> pack_start($font_btn , TRUE, TRUE, 0);
@@ -4564,7 +4567,7 @@ sub apply_properties {
45644567 $fill_color = $stroke_color -> get_rgba;
45654568 }
45664569
4567- my $font_descr = Pango::FontDescription-> from_string($font_btn -> get_font_name);
4570+ my $font_descr = Pango::FontDescription:: from_string($font_btn -> get_font_name);
45684571 $self -> {_items }{$key }{text }-> set(
45694572 ' text' => " <span font_desc=' " . $font_btn -> get_font_name . " ' >" . $digit . " </span>" ,
45704573 ' fill-color-gdk-rgba' => $fill_color ,
@@ -4657,7 +4660,7 @@ sub apply_properties {
46574660
46584661 # apply text options
46594662 if ($item -> isa(' GooCanvas2::CanvasText' )) {
4660- my $font_descr = Pango::FontDescription-> from_string($font_btn -> get_font_name);
4663+ my $font_descr = Pango::FontDescription:: from_string($font_btn -> get_font_name);
46614664
46624665 my $new_text = undef ;
46634666 if ($textview ) {
@@ -4666,7 +4669,7 @@ sub apply_properties {
46664669 } else {
46674670
46684671 # determine font description and text from string
4669- my ($attr_list , $text_raw , $accel_char ) = Pango-> parse_markup($item -> get(' text' ));
4672+ my ($ret , $ attr_list , $text_raw , $accel_char ) = Pango:: parse_markup($item -> get(' text' ), -1, 0 );
46704673 $new_text = $text_raw ;
46714674 }
46724675
@@ -4703,7 +4706,7 @@ sub modify_text_in_properties {
47034706 my $use_font = shift ;
47044707 my $use_font_color = shift ;
47054708
4706- my $font_descr = Pango::FontDescription-> from_string($font_btn -> get_font_name);
4709+ my $font_descr = Pango::FontDescription:: from_string($font_btn -> get_font_name);
47074710 my $texttag = Gtk3::TextTag-> new;
47084711
47094712 if ($use_font -> get_active && $use_font_color -> get_active) {
0 commit comments