From e265b9fea8c3dc13f35854a514a5d549526b3a30 Mon Sep 17 00:00:00 2001 From: be5invis Date: Thu, 13 May 2021 20:27:05 -0700 Subject: [PATCH] Add Low asterisk (`U+204E`) and double asterisk (`U+2051`). --- changes/7.0.0.md | 42 ++++++++++--------- font-src/glyphs/auto-build/composite.ptl | 2 +- font-src/glyphs/symbol/math/apl.ptl | 2 +- .../glyphs/symbol/punctuation/asterisk.ptl | 37 +++++++++------- font-src/otl/gsub-ligation.ptl | 6 +-- params/variants.toml | 32 ++++++++------ 6 files changed, 68 insertions(+), 53 deletions(-) diff --git a/changes/7.0.0.md b/changes/7.0.0.md index e869369b5..b041b2c43 100644 --- a/changes/7.0.0.md +++ b/changes/7.0.0.md @@ -5,26 +5,28 @@ - `K`, `k`, Cyrillic Ka (`К` and `к`). - Cyrillic Ze (`З` and `з`). * Add characters: - - Cyrillic Iotified E (`U+0464`, `U+0465`). - - Cyrillic Omega (`U+0460`, `U+0461`), Ot (`U+047E`, `U+047F`), Broad Omega (`U+A64C`, `U+A64D`). - - Cyrillic Psi (`U+0470`, `U+0471`). - - Cyrillic Broad On (`U+047A`, `U+047B`). - - Cyrillic combining Dasia (`U+0485`), Psili (`U+0486`), Pokrytie (`U+0478`). - - Cyrillic Ornate Omega (`U+047C`, `U+047D`). - - Cyrillic Koppa (`U+0480`, `U+0481`). - - Cyrillic Semi-soft Sign (`U+048C`, `U+048D`). - - Cyrillic Er with Tick (`U+048E`, `U+048F`). - - Cyrillic tailed Short I (`U+048A`, `U+048B`), tailed El (`U+04C5`, `U+04C6`), railed En (`U+04C9`, `U+04CA`), tailed Em (`U+04CD`, `U+04CE`). - - Cyrillic Ka with Vertical Stroke (`U+049C`, `U+049D`). - - Cyrillic Ka with Stroke (`U+049E`, `U+049F`). - - Cyrillic Pe with Middle Hook (`U+04A6`, `U+04A7`). - - Cyrillic Abkhasian Ha (`U+04A8`, `U+04A9`). - - Cyrillic Te-Tse (`U+04B4`, `U+04B5`). - - Cyrillic Abkhazian Che (`U+04BC` ... `U+04BF`). - - Cyrillic Ka with Hook (`U+04C3`, `U+04C4`). - - Cyrillic Ghe with Stroke and Hook (`U+04FA`, `U+04FB`). - - Cyrillic Ha with Hook (`U+04FC`, `U+04FD`). - - Cyrillic Ha with Stroke (`U+04FE`, `U+04FF`). + - All remaining letters in Cyrillic block, including: + - Cyrillic Iotified E (`U+0464`, `U+0465`). + - Cyrillic Omega (`U+0460`, `U+0461`), Ot (`U+047E`, `U+047F`), Broad Omega (`U+A64C`, `U+A64D`). + - Cyrillic Psi (`U+0470`, `U+0471`). + - Cyrillic Broad On (`U+047A`, `U+047B`). + - Cyrillic combining Dasia (`U+0485`), Psili (`U+0486`), Pokrytie (`U+0478`). + - Cyrillic Ornate Omega (`U+047C`, `U+047D`). + - Cyrillic Koppa (`U+0480`, `U+0481`). + - Cyrillic Semi-soft Sign (`U+048C`, `U+048D`). + - Cyrillic Er with Tick (`U+048E`, `U+048F`). + - Cyrillic tailed Short I (`U+048A`, `U+048B`), tailed El (`U+04C5`, `U+04C6`), railed En (`U+04C9`, `U+04CA`), tailed Em (`U+04CD`, `U+04CE`). + - Cyrillic Ka with Vertical Stroke (`U+049C`, `U+049D`). + - Cyrillic Ka with Stroke (`U+049E`, `U+049F`). + - Cyrillic Pe with Middle Hook (`U+04A6`, `U+04A7`). + - Cyrillic Abkhasian Ha (`U+04A8`, `U+04A9`). + - Cyrillic Te-Tse (`U+04B4`, `U+04B5`). + - Cyrillic Abkhazian Che (`U+04BC` ... `U+04BF`). + - Cyrillic Ka with Hook (`U+04C3`, `U+04C4`). + - Cyrillic Ghe with Stroke and Hook (`U+04FA`, `U+04FB`). + - Cyrillic Ha with Hook (`U+04FC`, `U+04FD`). + - Cyrillic Ha with Stroke (`U+04FE`, `U+04FF`). + - Low asterisk (`U+204E`) and double asterisk (`U+2051`). - Helm symbol (`U+2388`). * Add tailed variants for Cyrillic El, En, Che, Yery and Ya (#972). * Add more serifed variants for `K`, `k`, `n`, Cyrillic Ka (`К` and `к`) and Cyrillic Ef (`ф`) to better reproduce PT Mono (#986). diff --git a/font-src/glyphs/auto-build/composite.ptl b/font-src/glyphs/auto-build/composite.ptl index beb51c9e2..9c61b0984 100644 --- a/font-src/glyphs/auto-build/composite.ptl +++ b/font-src/glyphs/auto-build/composite.ptl @@ -899,7 +899,7 @@ glyph-block AutoBuild-Accented-Equal : begin createAccentedOp 'equal' 7 0.5 0 (aboveMarkBot - (SymbolMid - XH / 2)) : list list 0x2259 {"triangularWedge.NWID"} list 0x225a {"triangularVee.NWID"} - list 0x225b {"asterisk.pentaLow"} + list 0x225b {"asterisk.pentaSMid"} list 0x225c {"whiteTriangleUp.NWID"} createAccentedOp 'sqrt' 5 0.5 (-Width / 4) [mix OperBot OperTop 0.6] : list list 0x221b {"three.lnum"} diff --git a/font-src/glyphs/symbol/math/apl.ptl b/font-src/glyphs/symbol/math/apl.ptl index 30f226641..01e1922c3 100644 --- a/font-src/glyphs/symbol/math/apl.ptl +++ b/font-src/glyphs/symbol/math/apl.ptl @@ -155,7 +155,7 @@ glyph-block Symbol-Math-APL : begin create-glyph 0x2360 : composite-proc [refer-glyph 'enquad'] [aplBoxed : composite-proc [refer-glyph 'colon'] [Realign Middle (XH/2) Middle SymbolMid]] create-glyph 0x2361 : composite-proc [refer-glyph 'top'] [MarkSet.tack] [refer-glyph 'dieresisAbove'] [clear-anchors] create-glyph 0x2362 : composite-proc [refer-glyph 'nabla'] [refer-glyph 'dieresisAbove'] - create-glyph 0x2363 : composite-proc [refer-glyph 'asterisk.pentaLow'] [MarkSet.plus] [refer-glyph 'dieresisAbove'] [clear-anchors] + create-glyph 0x2363 : composite-proc [refer-glyph 'asterisk.pentaSMid'] [MarkSet.plus] [refer-glyph 'dieresisAbove'] [clear-anchors] create-glyph 0x2364 : composite-proc [refer-glyph 'whiteSmallCircle.NWID'] [MarkSet.plus] [refer-glyph 'dieresisAbove'] [clear-anchors] create-glyph 0x2365 : composite-proc [refer-glyph 'whiteCircle.NWID'] [MarkSet.plus] [refer-glyph 'dieresisAbove'] [clear-anchors] create-glyph 0x2366 : composite-proc [refer-glyph 'enquad'] [Overlay [refer-glyph 'cup'] [refer-glyph 'aplbar']] diff --git a/font-src/glyphs/symbol/punctuation/asterisk.ptl b/font-src/glyphs/symbol/punctuation/asterisk.ptl index 7575db7dc..b3bc8249f 100644 --- a/font-src/glyphs/symbol/punctuation/asterisk.ptl +++ b/font-src/glyphs/symbol/punctuation/asterisk.ptl @@ -12,13 +12,13 @@ glyph-block Symbol-Punctuation-Asterisk : begin define asteriskCenterY : ParenTop - LongJut * 1.5 define asteriskKinds : list - list 5 1.2 0 0.4 Stroke 'asterisk' 'pentaHigh' 'pentaLow' 'midXH' - list 5 0.85 0 0.4 Stroke 'smallasterisk' 'high' 'low' '' - list 5 1 0 0.4 GeometryStroke 'opAsterisk' 'high' 'low' '' - list 6 1.2 0 0.4 Stroke 'asterisk' 'hexHigh' 'hexLow' '' - list 5 1.2 1 0.4 Stroke 'asterisk' 'turnPentaHigh' 'turnPentaLow' '' - list 6 1.2 0.5 0.4 Stroke 'asterisk' 'turnHexHigh' 'turnHexLow' '' - foreach [{sides size rot pFine stroke name high low midXH} : items-of asteriskKinds] : begin + list 5 1.2 0 0.4 Stroke 'asterisk' 'pentaHigh' 'pentaSMid' 'midXH' 'pentaLow' 'dualAsterisk' + list 6 1.2 0 0.4 Stroke 'asterisk' 'hexHigh' 'hexSMid' '' 'hexLow' 'dualAsterisk' + list 5 1.2 1 0.4 Stroke 'asterisk' 'turnPentaHigh' 'turnPentaSMid' '' 'turnPentaLow' 'dualAsterisk' + list 6 1.2 0.5 0.4 Stroke 'asterisk' 'turnHexHigh' 'turnHexSMid' '' 'turnHexLow' 'dualAsterisk' + list 5 0.85 0 0.4 Stroke 'smallAsterisk' 'high' 'low' '' '' '' + list 5 1 0 0.4 GeometryStroke 'opAsterisk' 'high' 'low' '' '' '' + foreach [{sides size rot pFine stroke name high sMid midXH low dual} : items-of asteriskKinds] : begin create-glyph (name + '.' + high) : glyph-proc local radius : LongJut * size local fine : stroke * pFine @@ -31,18 +31,23 @@ glyph-block Symbol-Punctuation-Asterisk : begin flat Middle asteriskCenterY [widths fine fine] curl (Middle + radius * s) (asteriskCenterY + radius * c) [widths final final] - create-glyph (name + '.' + low) : composite-proc + if sMid : create-glyph (name + '.' + sMid) : composite-proc refer-glyph (name + '.' + high) - Upright - Translate 0 (SymbolMid - asteriskCenterY) - Italify + ApparentTranslate 0 (SymbolMid - asteriskCenterY) if midXH : create-glyph (name + '.' + midXH) : composite-proc refer-glyph (name + '.' + high) - Upright - Translate 0 (XH / 2 - asteriskCenterY) - Italify + ApparentTranslate 0 (XH / 2 - asteriskCenterY) + + if low : create-glyph (name + '.' + low) : composite-proc + refer-glyph (name + '.' + high) + ApparentTranslate 0 (2 * (SymbolMid - asteriskCenterY)) + + if (dual && sMid && low) : create-glyph (dual + '.' + sMid) : composite-proc + refer-glyph (name + '.' + high) + refer-glyph (name + '.' + low) select-variant 'asterisk' '*' - select-variant 'asterisk/lowered' (shapeFrom -- 'asterisk') - + select-variant 'asterisk/sMid' (shapeFrom -- 'asterisk') + select-variant 'lowAsterisk' 0x204E (shapeFrom -- 'asterisk') + select-variant 'dualAsterisk' 0x2051 (follow -- 'asterisk/sMid') diff --git a/font-src/otl/gsub-ligation.ptl b/font-src/otl/gsub-ligation.ptl index 3f5c92b62..c85503b66 100644 --- a/font-src/otl/gsub-ligation.ptl +++ b/font-src/otl/gsub-ligation.ptl @@ -102,13 +102,13 @@ define [buildLigationsImpl sink para featureName mappedFeature rankedLookups] : CreateLigationLookup : list chain-rule # (* {'parenLeft'} ~> look-around - {'asterisk'} ~> {'asterisk/lowered'} + {'asterisk'} ~> {'asterisk/sMid'} chain-rule # *) - {'asterisk'} ~> {'asterisk/lowered'} + {'asterisk'} ~> {'asterisk/sMid'} {'parenRight'} ~> look-around do "Operator centering" : if [hasLG 'center-ops'] : begin - define [centerAsterisk] : {'asterisk'} ~> {'asterisk/lowered'} + define [centerAsterisk] : {'asterisk'} ~> {'asterisk/sMid'} define [centerColon] : {'colon'} ~> {'colon.mid'} define [centerCaret] : {'asciiCaret'} ~> {'asciiCaret.low'} define [centerTilde] : {'asciiTilde'} ~> {'asciiTilde.low'} diff --git a/params/variants.toml b/params/variants.toml index c23460f30..9348f8b83 100644 --- a/params/variants.toml +++ b/params/variants.toml @@ -4512,49 +4512,57 @@ tag = "cv81" rank = 1 description = "Higher five-pointed asterisk `*`" selector.asterisk = "pentaHigh" -selector."asterisk/lowered" = "pentaLow" +selector."asterisk/sMid" = "pentaSMid" +selector."lowAsterisk" = "pentaLow" [prime.asterisk.variants.penta-low] rank = 2 description = "Lower five-pointed asterisk `*`" -selector.asterisk = "pentaLow" -selector."asterisk/lowered" = "pentaLow" +selector.asterisk = "pentaSMid" +selector."asterisk/sMid" = "pentaSMid" +selector."lowAsterisk" = "pentaLow" [prime.asterisk.variants.flip-penta-high] rank = 3 description = "Higher five-pointed and turned asterisk `*`" selector.asterisk = "turnPentaHigh" -selector."asterisk/lowered" = "turnPentaLow" +selector."asterisk/sMid" = "turnPentaSMid" +selector."lowAsterisk" = "turnPentaLow" [prime.asterisk.variants.flip-penta-low] rank = 4 description = "Lower five-pointed and turned asterisk `*`" -selector.asterisk = "turnPentaLow" -selector."asterisk/lowered" = "turnPentaLow" +selector.asterisk = "turnPentaSMid" +selector."asterisk/sMid" = "turnPentaSMid" +selector."lowAsterisk" = "turnPentaLow" [prime.asterisk.variants.hex-high] rank = 5 description = "Higher six-pointed asterisk `*`" selector.asterisk = "hexHigh" -selector."asterisk/lowered" = "hexLow" +selector."asterisk/sMid" = "hexSMid" +selector."lowAsterisk" = "hexLow" [prime.asterisk.variants.hex-low] rank = 6 description = "Lower six-pointed asterisk `*`" -selector.asterisk = "hexLow" -selector."asterisk/lowered" = "hexLow" +selector.asterisk = "hexSMid" +selector."asterisk/sMid" = "hexSMid" +selector."lowAsterisk" = "hexLow" [prime.asterisk.variants.turn-hex-high] rank = 7 description = "Higher turned six-pointed asterisk `*`" selector.asterisk = "turnHexHigh" -selector."asterisk/lowered" = "turnHexLow" +selector."asterisk/sMid" = "turnHexSMid" +selector."lowAsterisk" = "turnHexLow" [prime.asterisk.variants.turn-hex-low] rank = 8 description = "Lower turned six-pointed asterisk `*`" -selector.asterisk = "turnHexLow" -selector."asterisk/lowered" = "turnHexLow" +selector.asterisk = "turnHexSMid" +selector."asterisk/sMid" = "turnHexSMid" +selector."lowAsterisk" = "turnHexLow"