Fix ligation for [|]
(#2221).
This commit is contained in:
parent
d5661093ff
commit
1f7be24fe1
3 changed files with 22 additions and 13 deletions
|
@ -22,3 +22,4 @@
|
||||||
- BLACK LEFT-POINTING TRIANGLE (`U+25C0`).
|
- BLACK LEFT-POINTING TRIANGLE (`U+25C0`).
|
||||||
* Fix broken shape of `U+1FB95`, `U+1FB96` and `U+1FB97` (#2218).
|
* Fix broken shape of `U+1FB95`, `U+1FB96` and `U+1FB97` (#2218).
|
||||||
* Increase weight for `U+276E`/`U+276F` (#2217).
|
* Increase weight for `U+276E`/`U+276F` (#2217).
|
||||||
|
* Fix ligation for `[|]` (#2221).
|
||||||
|
|
|
@ -164,7 +164,7 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
|
|
||||||
create-glyph 'ligExtBracketLeft' : glyph-proc
|
create-glyph 'ligExtBracketLeft' : glyph-proc
|
||||||
Joining.set currentGlyph Joining.Classes.Right
|
Joining.set currentGlyph Joining.Classes.Right
|
||||||
include : Bracket.Shape ParenTop ParenBot (Middle - [HSwToV HalfStroke]) [mix SB RightSB DesignParameters.bracketInside]
|
include : Bracket.Shape ParenTop ParenBot (Middle - [HSwToV HalfStroke]) Width
|
||||||
|
|
||||||
create-glyph 'bracketLeftUpper' 0x23A1 : glyph-proc
|
create-glyph 'bracketLeftUpper' 0x23A1 : glyph-proc
|
||||||
include : ForceUpright
|
include : ForceUpright
|
||||||
|
@ -227,12 +227,12 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
(ParenTop - SymbolMid - Stroke * 1.5) / 2
|
(ParenTop - SymbolMid - Stroke * 1.5) / 2
|
||||||
return : object parenCenter radius
|
return : object parenCenter radius
|
||||||
|
|
||||||
export : define [UpperHalfShape top bottom sw pExt] : glyph-proc
|
export : define [UpperHalfShape top bottom sw ext] : glyph-proc
|
||||||
define [object parenCenter radius] : Dim
|
define [object parenCenter radius] : Dim
|
||||||
define xIns : mix SB RightSB DesignParameters.braceInside
|
define xIns : mix SB RightSB DesignParameters.braceInside
|
||||||
define xTip : mix SB RightSB DesignParameters.braceOutside
|
define xTip : mix SB RightSB DesignParameters.braceOutside
|
||||||
include : dispiro
|
include : dispiro
|
||||||
flat ((1 + [fallback pExt 0]) * xIns) top [widths.center.heading sw Leftward]
|
flat (xIns + [fallback ext 0]) top [widths.center.heading sw Leftward]
|
||||||
curl (xIns - 0.1) top [heading Leftward]
|
curl (xIns - 0.1) top [heading Leftward]
|
||||||
archv
|
archv
|
||||||
flat parenCenter (top - radius) [heading Downward]
|
flat parenCenter (top - radius) [heading Downward]
|
||||||
|
@ -240,12 +240,12 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
arcvh
|
arcvh
|
||||||
straight.left.end xTip bottom [heading Leftward]
|
straight.left.end xTip bottom [heading Leftward]
|
||||||
|
|
||||||
export : define [LowerHalfShape top bottom sw pExt] : glyph-proc
|
export : define [LowerHalfShape top bottom sw ext] : glyph-proc
|
||||||
define [object parenCenter radius] : Dim
|
define [object parenCenter radius] : Dim
|
||||||
define xIns : mix SB RightSB DesignParameters.braceInside
|
define xIns : mix SB RightSB DesignParameters.braceInside
|
||||||
define xTip : mix SB RightSB DesignParameters.braceOutside
|
define xTip : mix SB RightSB DesignParameters.braceOutside
|
||||||
include : dispiro
|
include : dispiro
|
||||||
flat ((1 + [fallback pExt 0]) * xIns) bottom [widths.center.heading sw Leftward]
|
flat (xIns + [fallback ext 0]) bottom [widths.center.heading sw Leftward]
|
||||||
curl (xIns - 0.1) bottom [heading Leftward]
|
curl (xIns - 0.1) bottom [heading Leftward]
|
||||||
archv
|
archv
|
||||||
flat parenCenter (bottom + radius) [heading Upward]
|
flat parenCenter (bottom + radius) [heading Upward]
|
||||||
|
@ -278,7 +278,7 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
|
|
||||||
######
|
######
|
||||||
|
|
||||||
export : define [CurlyShape sw pFlatIn pFlatOut pExt] : glyph-proc
|
export : define [CurlyShape sw pFlatIn pFlatOut ext] : glyph-proc
|
||||||
local hs : sw / 2
|
local hs : sw / 2
|
||||||
local xIns : mix SB RightSB DesignParameters.braceInside
|
local xIns : mix SB RightSB DesignParameters.braceInside
|
||||||
local xOus : mix SB RightSB DesignParameters.braceOutside
|
local xOus : mix SB RightSB DesignParameters.braceOutside
|
||||||
|
@ -296,7 +296,7 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
local fine : sw * CThin
|
local fine : sw * CThin
|
||||||
|
|
||||||
include : dispiro
|
include : dispiro
|
||||||
flat (xIns * (1 + pExt)) (top - hs) [widths.center.heading sw Leftward]
|
flat (xIns + [fallback ext 0]) (top - hs) [widths.center.heading sw Leftward]
|
||||||
curl (xIns - flatLengthIn) (top - hs) [heading Leftward]
|
curl (xIns - flatLengthIn) (top - hs) [heading Leftward]
|
||||||
archv.superness (2.2 + pFlatIn)
|
archv.superness (2.2 + pFlatIn)
|
||||||
g4.down.mid m1 (top - radius1) [heading Downward]
|
g4.down.mid m1 (top - radius1) [heading Downward]
|
||||||
|
@ -307,7 +307,7 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
curl xOus (SymbolMid + (sw - fine) / 2) [heading Leftward]
|
curl xOus (SymbolMid + (sw - fine) / 2) [heading Leftward]
|
||||||
|
|
||||||
include : dispiro
|
include : dispiro
|
||||||
flat (xIns * (1 + pExt)) (bot + hs) [widths.center.heading sw Leftward]
|
flat (xIns + [fallback ext 0]) (bot + hs) [widths.center.heading sw Leftward]
|
||||||
curl (xIns - flatLengthIn) (bot + hs) [heading Leftward]
|
curl (xIns - flatLengthIn) (bot + hs) [heading Leftward]
|
||||||
archv.superness (2.2 + pFlatIn)
|
archv.superness (2.2 + pFlatIn)
|
||||||
g4.up.mid m1 (bot + radius1) [heading Upward]
|
g4.up.mid m1 (bot + radius1) [heading Upward]
|
||||||
|
@ -330,8 +330,8 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
|
|
||||||
create-glyph 'ligExtBraceLeft.straight' : glyph-proc
|
create-glyph 'ligExtBraceLeft.straight' : glyph-proc
|
||||||
Joining.set currentGlyph Joining.Classes.Right
|
Joining.set currentGlyph Joining.Classes.Right
|
||||||
include : Brace.UpperHalfShape top SymbolMid Stroke 1
|
include : Brace.UpperHalfShape top SymbolMid Stroke Width
|
||||||
include : Brace.LowerHalfShape SymbolMid bot Stroke 1
|
include : Brace.LowerHalfShape SymbolMid bot Stroke Width
|
||||||
create-glyph 'ligExtBraceRight.straight' : glyph-proc
|
create-glyph 'ligExtBraceRight.straight' : glyph-proc
|
||||||
include [refer-glyph 'ligExtBraceLeft.straight'] AS_BASE ALSO_METRICS
|
include [refer-glyph 'ligExtBraceLeft.straight'] AS_BASE ALSO_METRICS
|
||||||
include : FlipAround Middle SymbolMid
|
include : FlipAround Middle SymbolMid
|
||||||
|
@ -380,12 +380,12 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
curlyFlatBoundary { 0.25 0.05 }
|
curlyFlatBoundary { 0.25 0.05 }
|
||||||
|
|
||||||
foreach { suffix { pFlatIn pFlatOut } } [Object.entries CurlyBraceConfig] : do
|
foreach { suffix { pFlatIn pFlatOut } } [Object.entries CurlyBraceConfig] : do
|
||||||
create-glyph "braceLeft.\(suffix)" : Brace.CurlyShape Stroke pFlatIn pFlatOut 0
|
create-glyph "braceLeft.\(suffix)" : Brace.CurlyShape Stroke pFlatIn pFlatOut
|
||||||
turned "braceRight.\(suffix)" null "braceLeft.\(suffix)" Middle SymbolMid
|
turned "braceRight.\(suffix)" null "braceLeft.\(suffix)" Middle SymbolMid
|
||||||
|
|
||||||
create-glyph "ligExtBraceLeft.\(suffix)" : glyph-proc
|
create-glyph "ligExtBraceLeft.\(suffix)" : glyph-proc
|
||||||
Joining.set currentGlyph Joining.Classes.Right
|
Joining.set currentGlyph Joining.Classes.Right
|
||||||
include : Brace.CurlyShape Stroke pFlatIn pFlatOut 1
|
include : Brace.CurlyShape Stroke pFlatIn pFlatOut Width
|
||||||
create-glyph "ligExtBraceRight.\(suffix)" : glyph-proc
|
create-glyph "ligExtBraceRight.\(suffix)" : glyph-proc
|
||||||
include [refer-glyph "ligExtBraceLeft.\(suffix)"] AS_BASE ALSO_METRICS
|
include [refer-glyph "ligExtBraceLeft.\(suffix)"] AS_BASE ALSO_METRICS
|
||||||
include : FlipAround Middle SymbolMid
|
include : FlipAround Middle SymbolMid
|
||||||
|
@ -396,7 +396,7 @@ glyph-block Symbol-Punctuation-Brackets : begin
|
||||||
local xIns : mix SB RightSB DesignParameters.braceInside
|
local xIns : mix SB RightSB DesignParameters.braceInside
|
||||||
local top : mix SymbolMid ParenTop (1 + DesignParameters.braceOvershoot)
|
local top : mix SymbolMid ParenTop (1 + DesignParameters.braceOvershoot)
|
||||||
local bot : mix SymbolMid ParenBot (1 + DesignParameters.braceOvershoot)
|
local bot : mix SymbolMid ParenBot (1 + DesignParameters.braceOvershoot)
|
||||||
include : Brace.CurlyShape fine pFlatIn pFlatOut 0
|
include : Brace.CurlyShape fine pFlatIn pFlatOut
|
||||||
include : VBar.r xIns (bot + fine / 2) (top - fine / 2) fine
|
include : VBar.r xIns (bot + fine / 2) (top - fine / 2) fine
|
||||||
|
|
||||||
turned "whiteBraceRight.\(suffix)" null "whiteBraceLeft.\(suffix)" Middle SymbolMid
|
turned "whiteBraceRight.\(suffix)" null "whiteBraceLeft.\(suffix)" Middle SymbolMid
|
||||||
|
|
|
@ -976,12 +976,20 @@ define [buildLigationsImpl gsub para $LigGroup$] : begin
|
||||||
# [| |] {| |}
|
# [| |] {| |}
|
||||||
LigGroup "Bracket and bar" : begin
|
LigGroup "Bracket and bar" : begin
|
||||||
CreateLigationLookup : list
|
CreateLigationLookup : list
|
||||||
|
if [hasLG 'brack-bar'] : chain-rule
|
||||||
|
{'bracketLeft'} ~> advance
|
||||||
|
{'bar'} ~> advance
|
||||||
|
{'bracketRight'} ~> advance
|
||||||
if [hasLG 'brack-bar'] : chain-rule
|
if [hasLG 'brack-bar'] : chain-rule
|
||||||
{'bracketLeft'} ~> {'ligExtBracketLeft'}
|
{'bracketLeft'} ~> {'ligExtBracketLeft'}
|
||||||
{'bar'} ~> {'ligBarInsideBracketLeft'}
|
{'bar'} ~> {'ligBarInsideBracketLeft'}
|
||||||
if [hasLG 'brack-bar'] : chain-rule
|
if [hasLG 'brack-bar'] : chain-rule
|
||||||
{'bar'} ~> {'ligBarInsideBracketRight'}
|
{'bar'} ~> {'ligBarInsideBracketRight'}
|
||||||
{'bracketRight'} ~> {'ligExtBracketRight'}
|
{'bracketRight'} ~> {'ligExtBracketRight'}
|
||||||
|
if [hasLG 'brace-bar'] : chain-rule
|
||||||
|
{'braceLeft'} ~> advance
|
||||||
|
{'bar'} ~> advance
|
||||||
|
{'braceRight'} ~> advance
|
||||||
if [hasLG 'brace-bar'] : chain-rule
|
if [hasLG 'brace-bar'] : chain-rule
|
||||||
{'braceLeft'} ~> {'ligExtBraceLeft'}
|
{'braceLeft'} ~> {'ligExtBraceLeft'}
|
||||||
{'bar'} ~> {'ligBarInsideBracketLeft'}
|
{'bar'} ~> {'ligBarInsideBracketLeft'}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue