summaryrefslogtreecommitdiff
path: root/gtk/gtktextbuffer.c
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2015-07-29 18:28:56 -0400
committerMatthias Clasen <mclasen@redhat.com>2015-07-29 21:42:58 -0400
commitc6838fbff0dba67cc067978beb9cd4a2dbe90e5f (patch)
tree7dd6046705e2c41893ff30aaf201aafedc38b781 /gtk/gtktextbuffer.c
parent98f9532a22bc37118f5958f795c5167714d31e00 (diff)
downloadgtk+-c6838fbff0dba67cc067978beb9cd4a2dbe90e5f.tar.gz
GtkTextView: Support font features
Add a ::font-features attribute to GtkTextTag, and support font features when inserting Pango markup into a text buffer.
Diffstat (limited to 'gtk/gtktextbuffer.c')
-rw-r--r--gtk/gtktextbuffer.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gtk/gtktextbuffer.c b/gtk/gtktextbuffer.c
index 5bb9a210b8..8e3e1de04e 100644
--- a/gtk/gtktextbuffer.c
+++ b/gtk/gtktextbuffer.c
@@ -4837,6 +4837,10 @@ get_tag_for_attributes (PangoAttrIterator *iter)
if (attr)
g_object_set (tag, "letter-spacing", ((PangoAttrInt*)attr)->value, NULL);
+ attr = pango_attr_iterator_get (iter, PANGO_ATTR_FONT_FEATURES);
+ if (attr)
+ g_object_set (tag, "font-features", ((PangoAttrString*)attr)->value, NULL);
+
return tag;
}