[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master 3cf7d32b90a: Display glyphs whose first contours commence at orig
From: |
Po Lu |
Subject: |
master 3cf7d32b90a: Display glyphs whose first contours commence at origin |
Date: |
Thu, 7 Dec 2023 22:00:50 -0500 (EST) |
branch: master
commit 3cf7d32b90ad32321c141bb2a34a670d2d6df5b7
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Display glyphs whose first contours commence at origin
* src/sfnt.c (sfnt_build_append): Don't disregard redundant
motion if outline is empty. Problem encountered in the "M"
glyph within Source Code Pro VF Italic.
---
src/sfnt.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/src/sfnt.c b/src/sfnt.c
index 8ec19290859..34239973797 100644
--- a/src/sfnt.c
+++ b/src/sfnt.c
@@ -3487,12 +3487,18 @@ sfnt_build_append (int flags, sfnt_fixed x, sfnt_fixed
y)
{
struct sfnt_glyph_outline *outline;
+ outline = build_outline_context.outline;
+
if (x == build_outline_context.x
- && y == build_outline_context.y)
+ && y == build_outline_context.y
+ /* If the outline is presently empty, the first move_to must be
+ recorded even if its X and Y are set to origin. Without this
+ initial vertex, edges will be generated from the next vertex
+ onward, and thus be misaligned. */
+ && outline->outline_used)
/* Ignore redundant motion. */
return build_outline_context.outline;
- outline = build_outline_context.outline;
outline->outline_used++;
/* See if the outline has to be extended. Checking for overflow
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master 3cf7d32b90a: Display glyphs whose first contours commence at origin,
Po Lu <=