summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDavid Turner <david@freetype.org>2001-10-29 17:22:12 +0000
committerDavid Turner <david@freetype.org>2001-10-29 17:22:12 +0000
commit9d7e5e8b8b455c10e6429827f2e8f00047261c52 (patch)
treefbaf36316f75393f9016d4947eb1724a9650eb07 /tests
parentb92479b8c246e5ed1757d6dff2b5687085e0e451 (diff)
downloadfreetype2-9d7e5e8b8b455c10e6429827f2e8f00047261c52.tar.gz
other auto-hinter experiments not worthy of a Changelog entry
Diffstat (limited to 'tests')
-rw-r--r--tests/gview.c36
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/gview.c b/tests/gview.c
index 3bc214fc6..4c1df3741 100644
--- a/tests/gview.c
+++ b/tests/gview.c
@@ -858,6 +858,42 @@ ah_draw_edges( void )
}
}
}
+
+ if ( option_show_horz_hints && option_show_links )
+ {
+ AH_Segment* seg = glyph->horz_segments;
+ FT_UInt count = glyph->num_hsegments;
+
+ for ( ; count > 0; count--, seg++ )
+ {
+ AH_Segment* seg2 = NULL;
+ NV_Path link;
+ NV_Vector v1, v2;
+
+ if ( seg->link )
+ {
+ if ( seg->link > seg )
+ seg2 = seg->link;
+ }
+ else if ( seg->serif )
+ seg2 = seg->serif;
+
+ if ( seg2 )
+ {
+ v1.y = seg->first->y;
+ v2.y = seg2->first->y;
+ v1.x = (seg->first->x + seg->last->x)/2 - pp1;
+ v2.x = (seg2->first->x + seg2->last->x)/2 - pp1;
+
+ link = ah_link_path( &v1, &v2, 0 );
+
+ nv_painter_set_color( painter, seg->serif ? SERIF_LINK_COLOR : LINK_COLOR, 256 );
+ nv_painter_fill_path( painter, &size_transform, 0, link );
+
+ nv_path_destroy( link );
+ }
+ }
+ }
}
}
}