summaryrefslogtreecommitdiffstats
path: root/source/widgets/textbox.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/widgets/textbox.c')
-rw-r--r--source/widgets/textbox.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/widgets/textbox.c b/source/widgets/textbox.c
index bab5eb9f..482d1037 100644
--- a/source/widgets/textbox.c
+++ b/source/widgets/textbox.c
@@ -911,7 +911,7 @@ double textbox_get_estimated_ch ( void )
int textbox_get_estimated_height ( const textbox *tb, int eh )
{
int height = pango_font_metrics_get_ascent ( tb->metrics ) + pango_font_metrics_get_descent ( tb->metrics );
- return ( eh * height ) / PANGO_SCALE + widget_padding_get_padding_height ( WIDGET ( tb ) );
+ return ceil(( eh * height ) / (double)PANGO_SCALE) + widget_padding_get_padding_height ( WIDGET ( tb ) );
}
int textbox_get_desired_width ( widget *wid )
{