Cleanup direct manipulation of contours

This commit is contained in:
Belleve Invis 2020-06-03 21:37:45 -07:00
parent 02b61d119e
commit 344d001217

View file

@ -1050,12 +1050,12 @@ glyph-block Letter-Latin-W : begin
local wMidHeight : if barStraight (topWithoutSerif * [Math.min 1 (df.div * 0.9)]) (top * 0.6) local wMidHeight : if barStraight (topWithoutSerif * [Math.min 1 (df.div * 0.9)]) (top * 0.6)
if barStraight : begin if barStraight : begin
include : dispiro include : tagged 'strokeDown1' : dispiro
widths.lhs widths.lhs
flat (df.leftSB + O * 2) top [heading Downward] flat (df.leftSB + O * 2) top [heading Downward]
g4 (m1 - fineOffsetOuter) 0 [widths.lhs fineOuter] g4 (m1 - fineOffsetOuter) 0 [widths.lhs fineOuter]
: else : begin : else : begin
include : dispiro include : tagged 'strokeDown1' : dispiro
widths.lhs widths.lhs
flat df.leftSB top [heading Downward] flat df.leftSB top [heading Downward]
curl df.leftSB (top * 0.75) [heading Downward] curl df.leftSB (top * 0.75) [heading Downward]
@ -1101,17 +1101,18 @@ glyph-block Letter-Latin-W : begin
include : difference [InnerShapes] [InnerStrokeMask] include : difference [InnerShapes] [InnerStrokeMask]
if barStraight : begin if barStraight : begin
include : dispiro include : tagged 'strokeUp2' : dispiro
widths.rhs widths.rhs
flat (df.rightSB - O * 2) top [heading Downward] flat (df.rightSB - O * 2) top [heading Downward]
g4 (m2 + fineOffsetOuter) 0 [widths.rhs fineOuter] g4 (m2 + fineOffsetOuter) 0 [widths.rhs fineOuter]
: else : begin : else : begin
include : dispiro include : tagged 'strokeUp2' : dispiro
widths.rhs widths.rhs
flat df.rightSB top [heading Downward] flat df.rightSB top [heading Downward]
curl df.rightSB (top * 0.75) [heading Downward] curl df.rightSB (top * 0.75) [heading Downward]
quadcontrols 0 0.3 6 unimportant quadcontrols 0 0.3 6 unimportant
g4 (m2 + fineOffsetOuter) 0 [widths.rhs fineOuter] g4 (m2 + fineOffsetOuter) 0 [widths.rhs fineOuter]
include : AIVSerifs top df.leftSB df.rightSB include : AIVSerifs top df.leftSB df.rightSB
set WShape.fineOuter 5 set WShape.fineOuter 5
@ -1169,11 +1170,8 @@ glyph-block Letter-Latin-W : begin
include : WShape top barStraight df include : WShape top barStraight df
# Eject unnecessary contours # Eject unnecessary contours
this.contours.pop eject-contour 'strokeUp2'
if SLAB : begin if SLAB : eject-contour 'serifRT'
local s : this.contours.pop
this.contours.pop
this.contours.push s
include : dispiro include : dispiro
widths.rhs widths.rhs