From 40aa38a94cb495d44e05720fc942afb9d919d6a4 Mon Sep 17 00:00:00 2001 From: be5invis Date: Thu, 30 Mar 2017 18:54:55 +0800 Subject: [PATCH] Add a taily "Q". --- glyphs/letters-unified-basic.ptl | 29 ++++++++++++++++++----------- meta/feature/ligation.ptl | 10 +++++++++- variants.toml | 8 ++++++++ 3 files changed, 35 insertions(+), 12 deletions(-) diff --git a/glyphs/letters-unified-basic.ptl b/glyphs/letters-unified-basic.ptl index c05e576ac..0601030ff 100644 --- a/glyphs/letters-unified-basic.ptl +++ b/glyphs/letters-unified-basic.ptl @@ -1976,23 +1976,29 @@ export : define [apply] : begin save 'olowerhalf' 0x1D17 ### Q - sketch # Q + sketch # Q.straight set-width WIDTH - - include glyphs.O AS_BASE + include glyphs.O AS_BASE local shift : linreg 18 0 126 0.25 STROKE include : dispiro widths.rhs flat (MIDDLE + WIDTH * 0.075 - STROKE * HVCONTRAST * shift) (-CAP * 0.2) [heading UPWARD] curl (MIDDLE - STROKE * HVCONTRAST * shift) 0 - #start-from MIDDLE 0 - #line-to (MIDDLE + WIDTH * 0.15 - HALFSTROKE * HVCONTRAST) (-CAP * 0.2) - #line-to (MIDDLE + WIDTH * 0.15 + HALFSTROKE * HVCONTRAST) (-CAP * 0.2) - #line-to (MIDDLE + STROKE * HVCONTRAST) 0 - #line-to (MIDDLE + STROKE * (1 - 0.5 / 3) * HVCONTRAST) (STROKE * 0.5) - #reverse-last - save 'Q' 'Q' - save 'cyrQa' 0x51A + save 'Q.straight' + sketch # Q.taily + set-width WIDTH + include glyphs.O AS_BASE + include : dispiro + widths.rhs + flat (MIDDLE + HALFSTROKE * HVCONTRAST) HALFSTROKE [heading DOWNWARD] + curl (MIDDLE + HALFSTROKE * HVCONTRAST) 0 [heading DOWNWARD] + arcvh + flat [Math.min (MIDDLE + HALFSTROKE * HVCONTRAST / 2 + HOOKX - 1) (MIDDLE + HALFSTROKE * HVCONTRAST + HOOK - STROKE)] (STROKE - HOOK) + curl (MIDDLE + HALFSTROKE * HVCONTRAST / 2 + HOOKX) (STROKE - HOOK) + save 'Q.taily' + + select-variant 'Q' 'Q' 'taily' + alias 'cyrQa' 0x51A 'Q' ### q sketch # q @@ -2920,6 +2926,7 @@ export : define [apply] : begin widths.rhs flat (tcenter + HALFSTROKE - LONGJUT + TBALANCE2 - HALFSTROKE * TANSLANT) XH curl (tcenter + HALFSTROKE + LONGJUT + TBALANCE2 - HALFSTROKE * TANSLANT) XH + define [FlatSmallTShape top bot] : glyph-construction local barl : tcenter + HALFSTROKE - LONGJUT + TBALANCE2 - HALFSTROKE * TANSLANT local barr : tcenter + HALFSTROKE + LONGJUT + TBALANCE2 - HALFSTROKE * TANSLANT diff --git a/meta/feature/ligation.ptl b/meta/feature/ligation.ptl index c447c1b87..331e69e52 100644 --- a/meta/feature/ligation.ptl +++ b/meta/feature/ligation.ptl @@ -30,7 +30,15 @@ local less {'less'} local hyphen {'hyphen'} local exclam {'exclam'} local greater {'greater'} -local alphabet {'a' 'a.doublestorey' 'a.singlestorey' 'b' 'c' 'd' 'e' 'f' 'g' 'g.doublestorey' 'g.singlestorey' 'g.opendoublestorey' 'h' 'i' 'i.hooky' 'i.serifed' 'i.italic' 'i.zshaped' 'j' 'j.straight' 'j.serifed' 'k' 'l' 'l.serifed' 'l.italic' 'l.hooky' 'l.zshaped' 'l.tailed' 'l.hookybottom' 'm' 'm.longleg' 'm.shortleg' 'n' 'o' 'p' 'q' 'r' 's' 't' 'u' 'v' 'w' 'x' 'y' 'z' 'A' 'B' 'C' 'D' 'E' 'F' 'G' 'H' 'I' 'J' 'K' 'L' 'M' 'N' 'O' 'P' 'Q' 'R' 'S' 'T' 'U' 'V' 'W' 'X' 'Y' 'Z' 'zero' 'zero.slashed' 'zero.dotted' 'zero.unslashed' 'one' 'two' 'three' 'four' 'five' 'six' 'seven' 'eight' 'nine' 'underscore' 'underscore.high' 'underscore.low'} +local alphabet { + 'a' 'a.doublestorey' 'a.singlestorey' 'b' 'c' 'd' 'e' 'f' 'g' 'g.doublestorey' 'g.singlestorey' + 'g.opendoublestorey' 'h' 'i' 'i.hooky' 'i.serifed' 'i.italic' 'i.zshaped' 'j' 'j.straight' 'j.serifed' + 'k' 'l' 'l.serifed' 'l.italic' 'l.hooky' 'l.zshaped' 'l.tailed' 'l.hookybottom' 'm' 'm.longleg' + 'm.shortleg' 'n' 'o' 'p' 'q' 'r' 's' 't' 't.standard' 't.flatend' 'u' 'v' 'w' 'x' 'y' 'z' 'A' 'B' 'C' + 'D' 'E' 'F' 'G' 'H' 'I' 'J' 'K' 'L' 'M' 'N' 'O' 'P' 'Q' 'Q.straight' 'Q.taily' 'R' 'S' 'T' 'U' 'V' 'W' + 'X' 'Y' 'Z' 'zero' 'zero.slashed' 'zero.dotted' 'zero.unslashed' 'one' 'two' 'three' 'four' 'five' 'six' + 'seven' 'eight' 'nine' 'underscore' 'underscore.high' 'underscore.low' +} local [acops] {'less' 'greater' 'hyphen' 'equal' 'plus'} local [acskip] {'slash' 'bar' 'at' 'ampersand' 'percent' 'numbersign'} local [asterisk_center] ({'asterisk'} ~> {'asterisk.low'}) diff --git a/variants.toml b/variants.toml index e9db8ad96..cea84d7ee 100644 --- a/variants.toml +++ b/variants.toml @@ -165,6 +165,14 @@ tag = 'cv40' t = 'flatend' tag = 'cv41' +[simple.v-q-straight] +Q = 'straight' +tag = 'cv42' + +[simple.v-q-taily] +Q = 'taily' +tag = 'cv43' + # composites [composite.upright] ss01 = ['cv01', 'cv11', 'cv05', 'cv10', 'cv14', 'cv18', 'cv21', 'cv22', 'cv25', 'cv29', 'cv32', 'cv34', 'cv36'] # Andale Mono Style