[pango/pango2: 92/201] item: Add line spacing to ItemProperties




commit 41eceb0e93d16ac45e2da0f3113678360a71a5b5
Author: Matthias Clasen <mclasen redhat com>
Date:   Sun Jan 23 22:43:24 2022 -0500

    item: Add line spacing to ItemProperties

 pango/pango-item-private.h | 1 +
 pango/pango-item.c         | 5 +++++
 2 files changed, 6 insertions(+)
---
diff --git a/pango/pango-item-private.h b/pango/pango-item-private.h
index 8a47d181..78c3e4a7 100644
--- a/pango/pango-item-private.h
+++ b/pango/pango-item-private.h
@@ -67,6 +67,7 @@ struct _ItemProperties
   guint no_paragraph_break  : 1;
   guint shape_set           : 1;
   int letter_spacing;
+  int line_spacing;
   int absolute_line_height;
   double line_height;
   PangoRectangle *shape_ink_rect;
diff --git a/pango/pango-item.c b/pango/pango-item.c
index a8584549..2a68f3be 100644
--- a/pango/pango-item.c
+++ b/pango/pango-item.c
@@ -391,6 +391,7 @@ pango_item_get_properties (PangoItem      *item,
   properties->shape_logical_rect = NULL;
   properties->line_height = 0.0;
   properties->absolute_line_height = 0;
+  properties->line_spacing = 0;
 
   while (tmp_list)
     {
@@ -457,6 +458,10 @@ pango_item_get_properties (PangoItem      *item,
           properties->absolute_line_height = ((PangoAttrInt *)attr)->value;
           break;
 
+        case PANGO_ATTR_LINE_SPACING:
+          properties->line_spacing = ((PangoAttrInt *)attr)->value;
+          break;
+
         case PANGO_ATTR_SHOW:
           properties->showing_space = (((PangoAttrInt *)attr)->value & PANGO_SHOW_SPACES) != 0;
           break;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]