GM glyph_pos correct advance placement.
Glyph advances are based on the origin, not on the glyph bounding box. Draw the tick marks for the advances starting from where the run of glyphs was drawn. Change-Id: I217c10a79835ad46e0178bb77ab8e575e36704ca Reviewed-on: https://skia-review.googlesource.com/c/skia/+/368418 Reviewed-by: Herb Derby <herb@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
This commit is contained in:
parent
cfefec07ab
commit
53375a713f
@ -138,7 +138,7 @@ static void drawTestCase(SkCanvas* canvas,
|
||||
|
||||
// Magenta lines are the positions for the characters.
|
||||
paint.setColor(SK_ColorMAGENTA);
|
||||
SkScalar w = bounds.x();
|
||||
SkScalar w = 0;
|
||||
for (size_t i = 0; i < sizeof(kText) - 1; ++i) {
|
||||
canvas->drawLine(w, 0.0f, w, 5.0f, paint);
|
||||
w += widths[i];
|
||||
|
Loading…
Reference in New Issue
Block a user