| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright © 2011,2014 Google, Inc. | 2 * Copyright © 2011,2014 Google, Inc. |
| 3 * | 3 * |
| 4 * This is part of HarfBuzz, a text shaping library. | 4 * This is part of HarfBuzz, a text shaping library. |
| 5 * | 5 * |
| 6 * Permission is hereby granted, without written agreement and without | 6 * Permission is hereby granted, without written agreement and without |
| 7 * license or royalty fees, to use, copy, modify, and distribute this | 7 * license or royalty fees, to use, copy, modify, and distribute this |
| 8 * software and its documentation for any purpose, provided that the | 8 * software and its documentation for any purpose, provided that the |
| 9 * above copyright notice and the following two paragraphs appear in | 9 * above copyright notice and the following two paragraphs appear in |
| 10 * all copies of this software. | 10 * all copies of this software. |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 return font->em_scale_x (ot_font->h_metrics.get_advance (glyph)); | 212 return font->em_scale_x (ot_font->h_metrics.get_advance (glyph)); |
| 213 } | 213 } |
| 214 | 214 |
| 215 static hb_position_t | 215 static hb_position_t |
| 216 hb_ot_get_glyph_v_advance (hb_font_t *font HB_UNUSED, | 216 hb_ot_get_glyph_v_advance (hb_font_t *font HB_UNUSED, |
| 217 void *font_data, | 217 void *font_data, |
| 218 hb_codepoint_t glyph, | 218 hb_codepoint_t glyph, |
| 219 void *user_data HB_UNUSED) | 219 void *user_data HB_UNUSED) |
| 220 { | 220 { |
| 221 const hb_ot_font_t *ot_font = (const hb_ot_font_t *) font_data; | 221 const hb_ot_font_t *ot_font = (const hb_ot_font_t *) font_data; |
| 222 return font->em_scale_y (-ot_font->v_metrics.get_advance (glyph)); | 222 return font->em_scale_y (-(int) ot_font->v_metrics.get_advance (glyph)); |
| 223 } | 223 } |
| 224 | 224 |
| 225 static hb_bool_t | 225 static hb_bool_t |
| 226 hb_ot_get_glyph_h_origin (hb_font_t *font HB_UNUSED, | 226 hb_ot_get_glyph_h_origin (hb_font_t *font HB_UNUSED, |
| 227 void *font_data HB_UNUSED, | 227 void *font_data HB_UNUSED, |
| 228 hb_codepoint_t glyph HB_UNUSED, | 228 hb_codepoint_t glyph HB_UNUSED, |
| 229 hb_position_t *x HB_UNUSED, | 229 hb_position_t *x HB_UNUSED, |
| 230 hb_position_t *y HB_UNUSED, | 230 hb_position_t *y HB_UNUSED, |
| 231 void *user_data HB_UNUSED) | 231 void *user_data HB_UNUSED) |
| 232 { | 232 { |
| (...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 339 { | 339 { |
| 340 hb_ot_font_t *ot_font = _hb_ot_font_create (font); | 340 hb_ot_font_t *ot_font = _hb_ot_font_create (font); |
| 341 if (unlikely (!ot_font)) | 341 if (unlikely (!ot_font)) |
| 342 return; | 342 return; |
| 343 | 343 |
| 344 hb_font_set_funcs (font, | 344 hb_font_set_funcs (font, |
| 345 _hb_ot_get_font_funcs (), | 345 _hb_ot_get_font_funcs (), |
| 346 ot_font, | 346 ot_font, |
| 347 (hb_destroy_func_t) _hb_ot_font_destroy); | 347 (hb_destroy_func_t) _hb_ot_font_destroy); |
| 348 } | 348 } |
| OLD | NEW |