diff --git a/changes/27.2.1.md b/changes/27.2.1.md index db6b187bb..12307f83d 100644 --- a/changes/27.2.1.md +++ b/changes/27.2.1.md @@ -1 +1,2 @@ +* Refine shape of flat `5` (#2030). * Fix `ss02`, `ss04`, `ss06`, `ss13`, `ss17`'s application on `i` and `j` (#2033). diff --git a/font-src/glyphs/number/5.ptl b/font-src/glyphs/number/5.ptl index 1ed9ae9d1..09815ee58 100644 --- a/font-src/glyphs/number/5.ptl +++ b/font-src/glyphs/number/5.ptl @@ -35,12 +35,12 @@ glyph-block Digits-Five : begin define [FiveShape] : with-params [ top bp pBarPosSwAdj [sw Stroke] [bbd 0] [obl 0] [zt 0] - [bottomShape FiveArcStroke] + [bottomShape FiveArcStroke] [pXLeft 0.025] ] : glyph-proc local t1 : (top * bp + sw * pBarPosSwAdj) * 0.8 local t2 : (top * bp + sw * pBarPosSwAdj) * 1.0 - local xLeft : [mix SB RightSB 0.025] + zt - local xright : [mix RightSB SB 0.05] - (OX - O) + local xLeft : [mix SB RightSB pXLeft] + zt + local xRight : [mix RightSB SB 0.05] - (OX - O) local kGap : 0.144 - 0.1 * sw / t2 @@ -52,7 +52,7 @@ glyph-block Digits-Five : begin local oblCor : Math.hypot 1 obl local xVBar : firstKnot.x - oblCor * [HSwToV sw] local xVBarOffset : (top - firstKnot.y) * obl - include : HBar.t [if zt SB (xVBar + xVBarOffset)] xright top sw + include : HBar.t [if zt SB (xVBar + xVBarOffset)] xRight top sw include : union intersection [Rect (firstKnot.y + sw) firstKnot.y 0 Width] : dispiro flat xVBar firstKnot.y [widths.rhs.heading (sw) Upward] @@ -67,33 +67,33 @@ glyph-block Digits-Five : begin Rect (t2 / 2 + t2 * kGap) (t2 / 2 - t2 * kGap) 0 Middle - if (!bbd && SLAB) : include : VSerif.dr xright top [Math.min VJut ((top - t2) * 0.8)] + if (!bbd && SLAB) : include : VSerif.dr xRight top [Math.min VJut ((top - t2) * 0.8)] define FiveConfig : SuffixCfg.weave object # upper-left-bar "upright" 0 "oblique" (1 / 12) object # middle - "arched" { FiveArcStroke DesignParameters.fiveBarPos 0 } - "flat" { FiveFlatStroke (7 / 8 * DesignParameters.fiveBarPos) (1/3) } + "arched" { FiveArcStroke DesignParameters.fiveBarPos 0 0.025 } + "flat" { FiveFlatStroke (7 / 8 * DesignParameters.fiveBarPos) (1/3) 0.05 } - foreach { suffix { obl { bottomShape pBarPos pBarPosSwAdj } } } [pairs-of FiveConfig] : do + foreach { suffix { obl { bottomShape pBarPos pBarPosSwAdj pXLeft } } } [pairs-of FiveConfig] : do create-glyph "five.lnum.\(suffix)" : glyph-proc include : MarkSet.capital - include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (obl -- obl) + include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (obl -- obl) (pXLeft -- pXLeft) create-glyph "five.onum.\(suffix)" : glyph-proc include : OnumMarks.p - include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (obl -- obl) + include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (obl -- obl) (pXLeft -- pXLeft) include : ShiftDown create-glyph "zhuangToneFive.\(suffix)" : glyph-proc include : MarkSet.capital - include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (zt -- ((RightSB - SB) * 0.05)) + include : FiveShape CAP pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (zt -- ((RightSB - SB) * 0.05)) (pXLeft -- pXLeft) create-glyph "zhuangtonefive.\(suffix)" : glyph-proc include : MarkSet.e - include : FiveShape XH pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (zt -- ((RightSB - SB) * 0.05)) + include : FiveShape XH pBarPos pBarPosSwAdj (bottomShape -- bottomShape) (zt -- ((RightSB - SB) * 0.05)) (pXLeft -- pXLeft) select-variant 'five.lnum' [CodeLnum '5'] (follow -- 'five') select-variant 'five.onum' [CodeOnum '5'] (follow -- 'five')