From 773d1d29e67db5759b93e4fc999a2763448173b9 Mon Sep 17 00:00:00 2001 From: John McWilliams <37010132+jmcwilliams403@users.noreply.github.com> Date: Wed, 21 May 2025 20:29:21 -0400 Subject: [PATCH] =?UTF-8?q?Unify=20horizontal=20overshoots=20of=20top?= =?UTF-8?q?=C2=A0bars=20of=20Upper=C2=A0Gamma-like=20letters.=20(#2779)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Optimize overshoot of Script R and Cyrillic Tall Te. * Optimize overshoot of Greek Upper Gamma. --- changes/33.2.4.md | 12 +++++ .../src/letter/greek/upper-gamma.ptl | 53 ++++++++++--------- .../src/letter/latin-ext/script-r.ptl | 6 +-- .../font-glyphs/src/letter/latin/upper-t.ptl | 22 ++++---- 4 files changed, 53 insertions(+), 40 deletions(-) diff --git a/changes/33.2.4.md b/changes/33.2.4.md index 35366de95..874f3dd8b 100644 --- a/changes/33.2.4.md +++ b/changes/33.2.4.md @@ -1,5 +1,17 @@ * Refine shape of the following characters: + - GREEK CAPITAL LETTER GAMMA (`U+0393`). + - GREEK LETTER DIGAMMA (`U+03DC`) ... GREEK SMALL LETTER DIGAMMA (`U+03DD`). + - CYRILLIC CAPITAL LETTER GHE (`U+0413`). + - CYRILLIC SMALL LETTER GHE (`U+0433`). + - CYRILLIC CAPITAL LETTER GHE WITH UPTURN (`U+0490`) ... CYRILLIC SMALL LETTER GHE WITH MIDDLE HOOK (`U+0495`). + - CYRILLIC CAPITAL LETTER GHE WITH DESCENDER (`U+04F6`) ... CYRILLIC SMALL LETTER GHE WITH DESCENDER (`U+04F7`). + - CYRILLIC CAPITAL LETTER GHE WITH STROKE AND HOOK (`U+04FA`) ... CYRILLIC SMALL LETTER GHE WITH STROKE AND HOOK (`U+04FB`). + - CYRILLIC SMALL LETTER TALL TE (`U+1C84`). + - GREEK LETTER SMALL CAPITAL GAMMA (`U+1D26`). - TENGE SIGN (`U+20B8`). - TURKISH LIRA SIGN (`U+20BA`). - MANAT SIGN (`U+20BC`). + - DOUBLE STRUCK CAPITAL GAMMA (`U+213E`). - LATIN CAPITAL LETTER LAMBDA WITH STROKE (`U+A7DC`). + - LATIN SMALL LETTER SCRIPT R (`U+AB4B`). + - LATIN SMALL LETTER SCRIPT R WITH RING (`U+AB4C`). diff --git a/packages/font-glyphs/src/letter/greek/upper-gamma.ptl b/packages/font-glyphs/src/letter/greek/upper-gamma.ptl index 02f489209..21a964552 100644 --- a/packages/font-glyphs/src/letter/greek/upper-gamma.ptl +++ b/packages/font-glyphs/src/letter/greek/upper-gamma.ptl @@ -21,22 +21,23 @@ glyph-block Letter-Greek-Upper-Gamma: begin define SLAB-BOTTOM 2 define SLAB-ALL 3 - define GammaBarLeft : SB * 1.5 + define GammaBarLeftX : SB * 1.5 + define GammaRightX : RightSB - 0.75 * OX define [GammaShape top bot slabType] : glyph-proc - include : LeaningAnchor.Below.VBar.l GammaBarLeft - include : tagged 'strokeV' : VBar.l GammaBarLeft bot top - include : tagged 'strokeH' : HBar.t (GammaBarLeft - O) (RightSB - OX) top + include : LeaningAnchor.Below.VBar.l GammaBarLeftX + include : tagged 'strokeV' : VBar.l GammaBarLeftX bot top + include : tagged 'strokeH' : HBar.t (GammaBarLeftX - O) GammaRightX top match slabType [Just SLAB-ALL] : begin - include : HSerif.lt GammaBarLeft top SideJut - include : tagged 'serifLB' : HSerif.lb (GammaBarLeft + [HSwToV HalfStroke]) bot Jut - include : tagged 'serifLB' : HSerif.rb (GammaBarLeft + [HSwToV HalfStroke]) bot MidJutSide - include : tagged 'serifRT' : VSerif.dr (RightSB - OX) top VJut + include : HSerif.lt GammaBarLeftX top SideJut + include : tagged 'serifLB' : HSerif.lb (GammaBarLeftX + [HSwToV HalfStroke]) bot Jut + include : tagged 'serifLB' : HSerif.rb (GammaBarLeftX + [HSwToV HalfStroke]) bot MidJutSide + include : tagged 'serifRT' : VSerif.dr GammaRightX top VJut [Just SLAB-BOTTOM] : begin - include : tagged 'serifLB' : HSerif.lb (GammaBarLeft + [HSwToV HalfStroke]) bot Jut - include : tagged 'serifLB' : HSerif.rb (GammaBarLeft + [HSwToV HalfStroke]) bot MidJutSide + include : tagged 'serifLB' : HSerif.lb (GammaBarLeftX + [HSwToV HalfStroke]) bot Jut + include : tagged 'serifLB' : HSerif.rb (GammaBarLeftX + [HSwToV HalfStroke]) bot MidJutSide [Just SLAB-TR] : begin - include : tagged 'serifRT' : VSerif.dr (RightSB - OX) top VJut + include : tagged 'serifRT' : VSerif.dr GammaRightX top VJut define GammaConfig : object serifless { SLAB-NONE false } @@ -53,21 +54,21 @@ glyph-block Letter-Greek-Upper-Gamma: begin include : MarkSet.capital include : GammaShape CAP 0 slabType local yBar : CAP * DesignParameters.upperEBarPos - include : HBar.m GammaBarLeft (RightSB - [xMidBarShrink doST]) yBar + include : HBar.m GammaBarLeftX (RightSB - [xMidBarShrink doST]) yBar if doST : include : tagged 'serifRM' VSerif.dr (RightSB - [xMidBarShrink doST]) (yBar + HalfStroke) [mix Stroke VJut 0.5] create-glyph "cyrl/GheDescender.\(suffix)" : glyph-proc include [refer-glyph "grek/Gamma.\(suffix)"] AS_BASE ALSO_METRICS include : CyrDescender.rSideJut - x -- (GammaBarLeft + [HSwToV Stroke]) + x -- (GammaBarLeftX + [HSwToV Stroke]) y -- 0 jut -- MidJutSide create-glyph "cyrl/GheDHook.\(suffix)" : glyph-proc include [refer-glyph "grek/Gamma.\(suffix)"] AS_BASE ALSO_METRICS include : PalatalHook.rSideJut - x -- (GammaBarLeft + [HSwToV Stroke]) + x -- (GammaBarLeftX + [HSwToV Stroke]) y -- 0 jut -- MidJutSide @@ -78,14 +79,14 @@ glyph-block Letter-Greek-Upper-Gamma: begin create-glyph "cyrl/gheDescender.upright.\(suffix)" : glyph-proc include [refer-glyph "cyrl/ghe.upright.\(suffix)"] AS_BASE ALSO_METRICS include : CyrDescender.rSideJut - x -- (GammaBarLeft + [HSwToV Stroke]) + x -- (GammaBarLeftX + [HSwToV Stroke]) y -- 0 jut -- MidJutSide create-glyph "cyrl/gheDHook.upright.\(suffix)" : glyph-proc include [refer-glyph "cyrl/ghe.upright.\(suffix)"] AS_BASE ALSO_METRICS include : PalatalHook.rSideJut - x -- (GammaBarLeft + [HSwToV Stroke]) + x -- (GammaBarLeftX + [HSwToV Stroke]) y -- 0 jut -- MidJutSide @@ -94,29 +95,29 @@ glyph-block Letter-Greek-Upper-Gamma: begin include : ExtendAboveBaseAnchors (CAP + LongVJut - QuarterStroke) include : GammaShape CAP 0 slabType eject-contour 'serifRT' - include : VBar.r (RightSB - OX) CAP (CAP + LongVJut - QuarterStroke) VJutStroke + include : VBar.r GammaRightX CAP (CAP + LongVJut - QuarterStroke) VJutStroke create-glyph "cyrl/ge.upright.\(suffix)" : glyph-proc include : MarkSet.e include : ExtendAboveBaseAnchors (XH + LongVJut - QuarterStroke) include : GammaShape XH 0 slabType eject-contour 'serifRT' - include : VBar.r (RightSB - OX) XH (XH + LongVJut - QuarterStroke) VJutStroke + include : VBar.r GammaRightX XH (XH + LongVJut - QuarterStroke) VJutStroke create-glyph "cyrl/ge.italic.\(suffix)" : glyph-proc include [refer-glyph "cyrl/ge.upright.\(suffix)"] AS_BASE ALSO_METRICS eject-contour 'serifLB' eject-contour 'strokeV' include : LegShape - ztop -- [Point.fromXY Point.Type.Corner GammaBarLeft XH] + ztop -- [Point.fromXY Point.Type.Corner GammaBarLeftX XH] zbot -- [Point.fromXY Point.Type.Corner [mix SB 0 : if doST 1 0.75] 0] - xb -- GammaBarLeft + xb -- GammaBarLeftX create-glyph "cyrl/GheMidHook.\(suffix)" : glyph-proc include [refer-glyph "grek/Gamma.\(suffix)"] AS_BASE ALSO_METRICS include : MarkSet.capDesc include : MidHook.general - left -- (GammaBarLeft + [HSwToV Stroke]) + left -- (GammaBarLeftX + [HSwToV Stroke]) right -- RightSB top -- (CAP * HBarPos + QuarterStroke) ada -- ArchDepthA @@ -126,7 +127,7 @@ glyph-block Letter-Greek-Upper-Gamma: begin include [refer-glyph "cyrl/ghe.upright.\(suffix)"] AS_BASE ALSO_METRICS include : MarkSet.p include : MidHook.general - left -- (GammaBarLeft + [HSwToV Stroke]) + left -- (GammaBarLeftX + [HSwToV Stroke]) right -- RightSB top -- (XH * HBarPos + QuarterStroke) ada -- (ArchDepthA * (HBarPos ** 0.3)) @@ -155,11 +156,11 @@ glyph-block Letter-Greek-Upper-Gamma: begin include : MarkSet.p include : GammaShape XH Descender SLAB-NONE local yBar : mix 0 XH DesignParameters.upperEBarPos - include : HBar.m GammaBarLeft (RightSB - [xMidBarShrink SLAB]) yBar + include : HBar.m GammaBarLeftX (RightSB - [xMidBarShrink SLAB]) yBar if SLAB : include : tagged 'serifRM' VSerif.dr (RightSB - [xMidBarShrink SLAB]) (yBar + HalfStroke) [mix Stroke VJut 0.5] - define [GhaynOverlayBar top] : LetterBarOverlay.l GammaBarLeft (top * (1 - OverlayPos)) + define [GhaynOverlayBar top] : LetterBarOverlay.l GammaBarLeftX (top * (1 - OverlayPos)) derive-composites 'cyrl/Ghayn' 0x492 'cyrl/Ghe' [GhaynOverlayBar CAP] derive-composites 'cyrl/ghayn.upright' null 'cyrl/ghe.upright' [GhaynOverlayBar XH] @@ -169,5 +170,5 @@ glyph-block Letter-Greek-Upper-Gamma: begin create-glyph 'mathbb/grek/Gamma' 0x213E : glyph-proc include : MarkSet.capital - include : BBBarLeft GammaBarLeft 0 CAP - include : HBar.t GammaBarLeft RightSB CAP BBS + include : BBBarLeft GammaBarLeftX 0 CAP + include : HBar.t GammaBarLeftX GammaRightX CAP BBS diff --git a/packages/font-glyphs/src/letter/latin-ext/script-r.ptl b/packages/font-glyphs/src/letter/latin-ext/script-r.ptl index 1bec096c9..0493d89c5 100644 --- a/packages/font-glyphs/src/letter/latin-ext/script-r.ptl +++ b/packages/font-glyphs/src/letter/latin-ext/script-r.ptl @@ -10,8 +10,8 @@ glyph-block Letter-Latin-Script-R : begin glyph-block-import Mark-Adjustment : LeaningAnchor glyph-block-import Letter-Shared-Shapes : RightwardTailedBar + define [xLeft df] : df.leftSB + 0.75 * OX define [xBarRight df] : df.width - df.leftSB * 1.5 - define [ScriptRShape top left right fTailed sw] : glyph-proc include : tagged 'strokeR' : if fTailed RightwardTailedBar right 0 (top - 0.5 * sw) (sw -- sw) @@ -35,7 +35,7 @@ glyph-block Letter-Latin-Script-R : begin create-glyph "rScript.\(suffix)" : glyph-proc local df : include : DivFrame 1 include : df.markSet.e - include : ScriptRShape XH df.leftSB [xBarRight df] doTail df.mvs + include : ScriptRShape XH [xLeft df] [xBarRight df] doTail df.mvs include : LeaningAnchor.Below.VBar.r [xBarRight df] select-variant 'rScript' 0xAB4B (follow -- 'cyrl/che') @@ -45,7 +45,7 @@ glyph-block Letter-Latin-Script-R : begin include : df.markSet.e local subDf : DivFrame (0.75 * para.advanceScaleM) 2 - include : ScriptRShape XH subDf.leftSB [xBarRight subDf] true subDf.mvs + include : ScriptRShape XH [xLeft subDf] [xBarRight subDf] true subDf.mvs eject-contour 'strokeR' local swBowl : [AdviceStroke 3] * (subDf.mvs / Stroke) diff --git a/packages/font-glyphs/src/letter/latin/upper-t.ptl b/packages/font-glyphs/src/letter/latin/upper-t.ptl index e50aa64ee..9b58ad77d 100644 --- a/packages/font-glyphs/src/letter/latin/upper-t.ptl +++ b/packages/font-glyphs/src/letter/latin/upper-t.ptl @@ -16,8 +16,8 @@ glyph-block Letter-Latin-Upper-T : begin glyph-block-import Letter-Shared-Shapes : CyrDescender SerifFrame FlatHookDepth LeftHook RetroflexHook define ox : 0.75 * OX - define [TLeftX df] : df.leftSB + ox - define [TRightX df] : df.rightSB - ox + define [TLeftX df] : df.leftSB + 0.75 * OX + define [TRightX df] : df.rightSB - 0.75 * OX define [TShape df top doTopSerifs doBottomSerifs] : glyph-proc include : tagged 'strokeV' : VBar.m df.middle 0 top local l : TLeftX df @@ -64,22 +64,22 @@ glyph-block Letter-Latin-Upper-T : begin define [CyrlTallTeShape df top doTopSerifs doBottomSerifs] : glyph-proc define doFullSerifs : doTopSerifs && doBottomSerifs && !para.isItalic - local xRight : df.width - 1.5 * df.leftSB - local xLeft : df.leftSB - ox + local xLeft : df.leftSB + 0.75 * OX + local xBarRight : df.width - 1.5 * df.leftSB - include : tagged 'strokeLT' : HBar.t xLeft xRight top - include : tagged 'strokeV' : VBar.r xRight 0 top + include : tagged 'strokeLT' : HBar.t xLeft xBarRight top + include : tagged 'strokeV' : VBar.r xBarRight 0 top if doTopSerifs : begin include : tagged 'serifLT' : VSerif.dl xLeft top VJut if doBottomSerifs : begin - include : tagged 'serifMB' : if para.isItalic [HSerif.rb xRight 0 SideJut] : composite-proc - HSerif.rb (xRight - [HSwToV HalfStroke]) 0 Jut - HSerif.lb (xRight - [HSwToV HalfStroke]) 0 MidJutSide + include : tagged 'serifMB' : if para.isItalic [HSerif.rb xBarRight 0 SideJut] : composite-proc + HSerif.rb (xBarRight - [HSwToV HalfStroke]) 0 Jut + HSerif.lb (xBarRight - [HSwToV HalfStroke]) 0 MidJutSide if doFullSerifs : begin - include : tagged 'serifRT' : HSerif.rt xRight top SideJut + include : tagged 'serifRT' : HSerif.rt xBarRight top SideJut - include : LeaningAnchor.Below.VBar.r xRight + include : LeaningAnchor.Below.VBar.r xBarRight glyph-block-export TConfig define TConfig : object