From 2b628d77c216443dfc672aa765317c76847a2783 Mon Sep 17 00:00:00 2001 From: be5invis Date: Fri, 14 Aug 2015 02:59:17 +0800 Subject: [PATCH] Added horn shapes. So yeah, we support Vietnamese now. --- buildglyphs.patel | 25 +++++++++++-------------- glyphs/overmarks.patel | 16 ++++++++++++++++ 2 files changed, 27 insertions(+), 14 deletions(-) diff --git a/buildglyphs.patel b/buildglyphs.patel index 9958e69..f268d65 100644 --- a/buildglyphs.patel +++ b/buildglyphs.patel @@ -145,21 +145,18 @@ define [buildFont para recursive] : begin { .type anchor.type ) - define markAboveLower (.anchors (.above [tm (.x MIDDLE .y XH .type BASE)])) - define markAboveCap (.anchors (.above [tm (.x MIDDLE .y CAP .type BASE)])) - define markBelowLower (.anchors (.below [tm (.x MIDDLE .y DESCENDER .type BASE)])) - define markBelowZero (.anchors (.below [tm (.x MIDDLE .y 0 .type BASE)])) - define markTrailingLower (.anchors (.trailing [tm (.x MIDDLE .y DESCENDER .type BASE)])) - define markTrailingZero (.anchors (.trailing [tm (.x MIDDLE .y 0 .type BASE)])) - define markLFLower (.anchors (.lf [tm (.x MIDDLE .y DESCENDER .type BASE)])) - define markLFZero (.anchors (.lf [tm (.x MIDDLE .y 0 .type BASE)])) + define markAboveLower (.anchors (.above [tm (.x MIDDLE .y XH .type BASE)])) + define markAboveCap (.anchors (.above [tm (.x MIDDLE .y CAP .type BASE)])) + define markBelowLower (.anchors (.below [tm (.x MIDDLE .y DESCENDER .type BASE)])) + define markBelowZero (.anchors (.below [tm (.x MIDDLE .y 0 .type BASE)])) + define markHornRTLower (.anchors (.hornRT [tm (.x RIGHTSB .y XH .type BASE)])) + define markHornRTCap (.anchors (.hornRT [tm (.x RIGHTSB .y CAP .type BASE)])) - - define capitalMarks (.anchors (.above markAboveCap.anchors.above .below markBelowZero.anchors.below)) - define bMarks (.anchors (.above markAboveCap.anchors.above .below markBelowZero.anchors.below)) - define eMarks (.anchors (.above markAboveLower.anchors.above .below markBelowZero.anchors.below)) - define pMarks (.anchors (.above markAboveLower.anchors.above .below markBelowLower.anchors.below)) - define ifMarks (.anchors (.above markAboveCap.anchors.above .below markBelowLower.anchors.below)) + define capitalMarks (.anchors (.above markAboveCap.anchors.above .hornRT markHornRTCap.anchors.hornRT .below markBelowZero.anchors.below)) + define bMarks (.anchors (.above markAboveCap.anchors.above .hornRT markHornRTCap.anchors.hornRT .below markBelowZero.anchors.below)) + define eMarks (.anchors (.above markAboveLower.anchors.above .hornRT markHornRTLower.anchors.hornRT .below markBelowZero.anchors.below)) + define pMarks (.anchors (.above markAboveLower.anchors.above .hornRT markHornRTLower.anchors.hornRT .below markBelowLower.anchors.below)) + define ifMarks (.anchors (.above markAboveCap.anchors.above .hornRT markHornRTCap.anchors.hornRT .below markBelowLower.anchors.below)) Stroke.bindParameters para diff --git a/glyphs/overmarks.patel b/glyphs/overmarks.patel index 500ca51..8677442 100644 --- a/glyphs/overmarks.patel +++ b/glyphs/overmarks.patel @@ -296,6 +296,22 @@ create-glyph 'revCommaAbove' : glyph-construction { apply-transform : Translate 0 [DOTRADIUS * 0.25] apply-transform : Italify } +create-glyph 'horn' : glyph-construction { + set-width 0 + assign-unicode 0x31B + local radius : markHalfStroke * 1.5 + include : list { + Ring [XH + ACCENT + radius] [XH + ACCENT - radius] [markMiddle - radius] [markMiddle + radius] + } + include : create-stroke + :.start-from [markMiddle + radius] [XH + ACCENT] + :.set-width 0 [markFine * 1.75] + :.curve-to [markMiddle + radius] [mix [XH + ACCENT] [aboveMarkBot - radius] 0.75] [markMiddle - radius - markHalfStroke] [aboveMarkBot - radius] + apply-transform : Upright + apply-transform : Translate [-markMiddle + radius * 0.35] 0 + apply-transform : Italify + set-anchor 'hornRT' MARK 0 [aboveMarkBot + markFine * 0.75] 0 aboveMarkTop +} create-glyph 'barAbove' : glyph-construction { set-width 0 assign-unicode 0x30D