projects
/
platform
/
upstream
/
libHarfBuzzSharp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a7b32f2
)
Use horizontal ascent as fallback vertical origin
author
Behdad Esfahbod
<behdad@behdad.org>
Wed, 26 Oct 2016 16:12:50 +0000
(18:12 +0200)
committer
Behdad Esfahbod
<behdad@behdad.org>
Wed, 26 Oct 2016 16:12:50 +0000
(18:12 +0200)
src/hb-font-private.hh
patch
|
blob
|
history
diff --git
a/src/hb-font-private.hh
b/src/hb-font-private.hh
index
324cadc
..
cda97a6
100644
(file)
--- a/
src/hb-font-private.hh
+++ b/
src/hb-font-private.hh
@@
-337,14
+337,15
@@
struct hb_font_t {
}
}
- /* Internal only */
inline void guess_v_origin_minus_h_origin (hb_codepoint_t glyph,
hb_position_t *x, hb_position_t *y)
{
*x = get_glyph_h_advance (glyph) / 2;
- /* TODO use font_extents.ascender */
- *y = y_scale;
+ /* TODO cache this somehow?! */
+ hb_font_extents_t extents;
+ get_h_extents_with_fallback (&extents);
+ *y = extents.ascender;
}
inline void get_glyph_h_origin_with_fallback (hb_codepoint_t glyph,