[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ft-devel] [PATCH] Re: losing outline flags while auto-hinting
From: |
Alexei Podtelezhnikov |
Subject: |
[ft-devel] [PATCH] Re: losing outline flags while auto-hinting |
Date: |
Thu, 16 Feb 2012 21:14:25 -0500 |
On Thu, Feb 16, 2012 at 2:07 AM, Werner LEMBERG <address@hidden> wrote:
> This is a bug. Reason is that the autohinter doesn't preserve this
> flag while copying around the outlines (in function af_loader_load_g).
This safe patch fixes it for me.
diff --git a/src/autofit/afloader.c b/src/autofit/afloader.c
index e73109f..9bd68a9 100644
--- a/src/autofit/afloader.c
+++ b/src/autofit/afloader.c
@@ -465,7 +465,13 @@
if ( error )
goto Exit;
- slot->outline = internal->loader->base.outline;
+ /* reassign all outline fields except flags to protect them */
+ slot->outline.n_contours = internal->loader->base.outline.n_contours;
+ slot->outline.n_points = internal->loader->base.outline.n_points;
+ slot->outline.points = internal->loader->base.outline.points;
+ slot->outline.tags = internal->loader->base.outline.tags;
+ slot->outline.contours = internal->loader->base.outline.contours;
+
slot->format = FT_GLYPH_FORMAT_OUTLINE;
}