File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -916,15 +916,15 @@ FT2Font::compute_string_bbox( ) {
916916 for ( size_t n = 0 ; n < glyphs.size (); n++ ) {
917917 FT_BBox glyph_bbox;
918918 FT_Glyph_Get_CBox ( glyphs[n], ft_glyph_bbox_subpixels, &glyph_bbox );
919+ if ( glyph_bbox.xMin < bbox.xMin ) bbox.xMin = glyph_bbox.xMin ;
920+ if ( glyph_bbox.yMin < bbox.yMin ) bbox.yMin = glyph_bbox.yMin ;
919921 if (glyph_bbox.xMin == glyph_bbox.xMax ) {
920922 right_side += glyphs[n]->advance .x >> 10 ;
921923 if ( right_side > bbox.xMax ) bbox.xMax = right_side;
922924 } else {
923- if ( glyph_bbox.xMin < bbox.xMin ) bbox.xMin = glyph_bbox.xMin ;
924- if ( glyph_bbox.yMin < bbox.yMin ) bbox.yMin = glyph_bbox.yMin ;
925925 if ( glyph_bbox.xMax > bbox.xMax ) bbox.xMax = glyph_bbox.xMax ;
926- if ( glyph_bbox.yMax > bbox.yMax ) bbox.yMax = glyph_bbox.yMax ;
927926 }
927+ if ( glyph_bbox.yMax > bbox.yMax ) bbox.yMax = glyph_bbox.yMax ;
928928 }
929929 /* check that we really grew the string bbox */
930930 if ( bbox.xMin > bbox.xMax ) {
You can’t perform that action at this time.
0 commit comments