Re: Non-ascii characters break Cairo's show_text
- From: Ari Jolma <ari jolma tkk fi>
- To: muppet <scott asofyet org>
- Cc: gtk-perl-list gnome org
- Subject: Re: Non-ascii characters break Cairo's show_text
- Date: Thu, 28 Jun 2007 22:45:16 +0300
muppet kirjoitti:
You shouldn't need to parse anything. gtk_font_selection_get_font_name()
creates its result by calling pango_font_description_to_string(), so on your
end it should be as simple as
$font_name = $font_selection->get_font_name ();
$font_desc = Gtk2::Pango::FontDescription->from_string ($font_name);
$layout->set_font_description ($font_desc);
Thanks. This works and simplifies things greatly. I was first using
$cr->select_font_face, which requires family, slant and weight separately.
Ari
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]