diff options
Diffstat (limited to 'src/ftcrfont.c')
| -rw-r--r-- | src/ftcrfont.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ftcrfont.c b/src/ftcrfont.c index 119ec284094..e089f9dea85 100644 --- a/src/ftcrfont.c +++ b/src/ftcrfont.c | |||
| @@ -677,7 +677,11 @@ ftcrhbfont_begin_hb_font (struct font *font, double *position_unit) | |||
| 677 | 677 | ||
| 678 | ftcrfont_info->ft_size = ft_face->size; | 678 | ftcrfont_info->ft_size = ft_face->size; |
| 679 | hb_font_t *hb_font = fthbfont_begin_hb_font (font, position_unit); | 679 | hb_font_t *hb_font = fthbfont_begin_hb_font (font, position_unit); |
| 680 | if (ftcrfont_info->bitmap_position_unit) | 680 | /* HarfBuzz 5 correctly scales bitmap-only fonts without position |
| 681 | unit adjustment. | ||
| 682 | (https://github.com/harfbuzz/harfbuzz/issues/489) */ | ||
| 683 | if (!hb_version_atleast (5, 0, 0) | ||
| 684 | && ftcrfont_info->bitmap_position_unit) | ||
| 681 | *position_unit = ftcrfont_info->bitmap_position_unit; | 685 | *position_unit = ftcrfont_info->bitmap_position_unit; |
| 682 | 686 | ||
| 683 | return hb_font; | 687 | return hb_font; |