diff --git a/src/hb-font-private.hh b/src/hb-font-private.hh index d2801fb86..d391f462c 100644 --- a/src/hb-font-private.hh +++ b/src/hb-font-private.hh @@ -541,7 +541,7 @@ struct hb_font_t { } inline hb_position_t em_scalef (float v, int scale) { - return (hb_position_t) (v * scale / face->get_upem ()); + return (hb_position_t) round (v * scale / face->get_upem ()); } }; diff --git a/src/hb-ot-layout-gpos-table.hh b/src/hb-ot-layout-gpos-table.hh index 743767a5c..c8ea6e054 100644 --- a/src/hb-ot-layout-gpos-table.hh +++ b/src/hb-ot-layout-gpos-table.hh @@ -333,7 +333,7 @@ struct Anchor case 1: u.format1.get_anchor (c, glyph_id, x, y); return; case 2: u.format2.get_anchor (c, glyph_id, x, y); return; case 3: u.format3.get_anchor (c, glyph_id, x, y); return; - default: return; + default: return; } } diff --git a/src/hb-private.hh b/src/hb-private.hh index acddd8938..9a1f2c514 100644 --- a/src/hb-private.hh +++ b/src/hb-private.hh @@ -40,6 +40,7 @@ #define HB_OT_H_IN #endif +#include #include #include #include