[vlc-commits] FreeType: fix the rendering of a single caracter

Adrien Maglo git at videolan.org
Wed Sep 13 22:53:06 CEST 2017


vlc | branch: master | Adrien Maglo <magsoft at videolan.org> | Fri Sep  8 15:35:31 2017 +0200| [b80590fea95dbb51ac1015c37667c0d9f0227677] | committer: Jean-Baptiste Kempf

FreeType: fix the rendering of a single caracter

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b80590fea95dbb51ac1015c37667c0d9f0227677
---

 modules/text_renderer/freetype/text_layout.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/text_renderer/freetype/text_layout.c b/modules/text_renderer/freetype/text_layout.c
index e25ff1f844..7dd8dd4e37 100644
--- a/modules/text_renderer/freetype/text_layout.c
+++ b/modules/text_renderer/freetype/text_layout.c
@@ -1418,9 +1418,9 @@ static int LayoutParagraph( filter_t *p_filter, paragraph_t *p_paragraph,
         const run_desc_t *p_run = &p_paragraph->p_runs[p_paragraph->pi_run_ids[i]];
         const int i_advance_x = p_paragraph->p_glyph_bitmaps[ i ].i_x_advance;
 
-        if( ( i_last_space_width + i_advance_x >= i_preferred_width &&
+        if( ( i_last_space_width + i_advance_x > i_preferred_width &&
               p_run->p_style->e_wrapinfo == STYLE_WRAP_DEFAULT )
-            || i_width + i_advance_x >= i_max_width )
+            || i_width + i_advance_x > i_max_width )
         {
             if( i_line_start == i )
             {



More information about the vlc-commits mailing list