Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(442)

Unified Diff: src/pshinter/pshalgo.c

Issue 89753003: Update freetype to latest version of ASOP. (Closed) Base URL: https://chromium.googlesource.com/chromium/src/third_party/freetype.git@master
Patch Set: Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/pshinter/pshalgo.h ('k') | src/pshinter/pshglob.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pshinter/pshalgo.c
diff --git a/src/pshinter/pshalgo.c b/src/pshinter/pshalgo.c
index d798978914ad85cf80667065cf5531d31e7f6f85..343472ddb388fe9cdc049f49dae40e8776031ee1 100644
--- a/src/pshinter/pshalgo.c
+++ b/src/pshinter/pshalgo.c
@@ -4,8 +4,7 @@
/* */
/* PostScript hinting algorithm (body). */
/* */
-/* Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 */
-/* by */
+/* Copyright 2001-2010, 2012, 2013 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used */
@@ -402,13 +401,13 @@
FT_Fixed delta,
FT_Int dimension )
{
- PSH_Hint hint;
- FT_UInt count;
+ FT_UInt count;
for ( count = 0; count < table->max_hints; count++ )
{
- hint = table->hints + count;
+ PSH_Hint hint = table->hints + count;
+
hint->cur_pos = FT_MulFix( hint->org_pos, scale ) + delta;
hint->cur_len = FT_MulFix( hint->org_len, scale );
@@ -563,7 +562,7 @@
else if ( len > 0 )
{
/* This is a very small stem; we simply align it to the
- * pixel grid, trying to find the minimal displacement.
+ * pixel grid, trying to find the minimum displacement.
*
* left = pos
* right = pos + len
@@ -1162,8 +1161,8 @@
int result = PSH_DIR_NONE;
- ax = ( dx >= 0 ) ? dx : -dx;
- ay = ( dy >= 0 ) ? dy : -dy;
+ ax = FT_ABS( dx );
+ ay = FT_ABS( dy );
if ( ay * 12 < ax )
{
@@ -2194,7 +2193,7 @@
/* something to do? */
if ( outline->n_points == 0 || outline->n_contours == 0 )
- return PSH_Err_Ok;
+ return FT_Err_Ok;
#ifdef DEBUG_HINTER
« no previous file with comments | « src/pshinter/pshalgo.h ('k') | src/pshinter/pshglob.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698