[vte] widget: Fix get_preferred_height to use the correct padding
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc: 
- Subject: [vte] widget: Fix get_preferred_height to use the correct padding
- Date: Sun,  5 Jun 2016 14:17:22 +0000 (UTC)
commit 5bc6b3f8d8e733c02bebb9da8090429fef2b2688
Author: Simon McVittie <smcv debian org>
Date:   Mon May 23 10:42:41 2016 +0100
    widget: Fix get_preferred_height to use the correct padding
    
    The implementation of GtkWidgetClass:get_preferred_height by
    mistake used the horizontal padding instead of the vertical padding.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=760944
 src/vte.cc |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/vte.cc b/src/vte.cc
index dcf2df1..d3ff12a 100644
--- a/src/vte.cc
+++ b/src/vte.cc
@@ -8199,10 +8199,10 @@ VteTerminalPrivate::widget_get_preferred_height(int *minimum_height,
        *minimum_height = m_char_height * 1;
         *natural_height = m_char_height * m_row_count;
 
-       *minimum_height += m_padding.left +
-                          m_padding.right;
-       *natural_height += m_padding.left +
-                          m_padding.right;
+       *minimum_height += m_padding.top +
+                          m_padding.bottom;
+       *natural_height += m_padding.top +
+                          m_padding.bottom;
 
        _vte_debug_print(VTE_DEBUG_WIDGET_SIZE,
                        "[Terminal %p] minimum_height=%d, natural_height=%d for %ldx%ld cells.\n",
[
Date Prev][
Date Next]   [
Thread Prev][
Thread Next]   
[
Thread Index]
[
Date Index]
[
Author Index]