diff --git a/.prettierrc.yaml b/.prettierrc.yaml index 19f7e471a2..1f455f2c30 100644 --- a/.prettierrc.yaml +++ b/.prettierrc.yaml @@ -1,4 +1,6 @@ -# .prettierrc -printWidth: 100 -useTabs: true -tabWidth: 4 \ No newline at end of file +# .prettierrc +printWidth: 100 +useTabs: true +tabWidth: 4 +trailingComma: none +arrowParens: avoid \ No newline at end of file diff --git a/README.md b/README.md index 52e7e72a5a..4953b920aa 100644 --- a/README.md +++ b/README.md @@ -29,6 +29,7 @@ All versions include the same ranges of characters: Latin letters, Greek letters ![Languages Sample](https://raw.githubusercontent.com/be5invis/Iosevka/master/images/languages.png) + 159 Supported Languages: @@ -55,7 +56,7 @@ Iosevka supports Language-Specific Ligations, which is the ligation set enabled To build Iosevka you should: -1. Ensure that [`nodejs`](http://nodejs.org) (≥ 8.4), [`ttfautohint`](http://www.freetype.org/ttfautohint/), [`otfcc`](https://github.com/caryll/otfcc) (≥ 0.9.3) and `otf2otc` are present. +1. Ensure that [`nodejs`](http://nodejs.org) (≥ 12.16.0), [`ttfautohint`](http://www.freetype.org/ttfautohint/), [`otfcc`](https://github.com/caryll/otfcc) (≥ 0.10.3-alpha) and `otf2otc` are present. 2. Install necessary libs by `npm install`. If you’ve installed them, upgrade to the latest. 3. `npm run build -- contents::iosevka`. @@ -71,23 +72,23 @@ Since version 2.0, Iosevka would no longer support building via `makefile`. To i 2. Add a build plan into `private-build-plans.toml`, following this format: ```toml - [buildPlans.iosevka-custom] # is your plan name - family = "Iosevka Custom" # Font menu family name - design = ["common styles"] # Common styles - upright = ["upright-only", "styles"] # Upright-only styles - italic = ["italic-only", "styles"] # Italic-only styles - oblique = ["oblique-only", "styles"] # Oblique-only styles - hintParams = ["-a", "sss"] # Optional custom parameters for ttfautohint + [buildPlans.iosevka-custom] # is your plan name + family = "Iosevka Custom" # Font menu family name + design = ["leading-1500", "v-i-hooky", "v-l-hooky"] # Customize styles + hintParams = ["-a", "sss"] # Optional custom parameters for ttfautohint + # Override default building weights - # When buildPlans..weights is absent - # All weights would built and mapped to default shape/CSS - # IMPORTANT : Currently "menu" property only support 100, 200, 300, 400, 450, 500, 600, 700, 800, 900. - # and "shape" properly only supports number between 100 and 900 (inclusive). + # When buildPlans..weights is absent, all weights would built and mapped to + # default values. + # IMPORTANT : Currently "menu" and "css" property only support numbers between 0 and 1000. + # and "shape" properly only supports number between 100 and 900 (inclusive). + # If you decide to use custom weights you have to define all the weights you + # plan to use otherwise they will not be built. [buildPlans.iosevka-custom.weights.regular] - shape = 400 # Weight for glyph shapes - menu = 400 # Weight for menu name - css = 400 # Weight for webfont CSS + shape = 400 # Weight for glyph shapes. + menu = 400 # Weight for the font's names. + css = 400 # Weight for webfont CSS. [buildPlans.iosevka-custom.weights.book] shape = 450 @@ -98,7 +99,9 @@ Since version 2.0, Iosevka would no longer support building via `makefile`. To i shape = 700 menu = 700 css = 700 - + # End weight section + + # Override default building slant sets # Format: = <"normal"|"italic"|"oblique"> # When this section is absent, all slants would be built. @@ -106,6 +109,27 @@ Since version 2.0, Iosevka would no longer support building via `makefile`. To i upright = "normal" italic = "italic" oblique = "oblique" + # End slant section + + + # Override default building widths + # When buildPlans..widths is absent, all widths would built and mapped to + # default values. + # IMPORTANT : Currently "shape" property only support 3, 5, and 7, while "menu" only + # support 1, 2, 3, 4, 5, 6, 7, 8, 9. + # If you decide to use custom weights you have to define all the weights you + # plan to use otherwise they will not be built. + [buildPlans.iosevka-custom.widths.normal] + shape = 5 # Width of glyph shapes. + menu = 5 # Width for the font's names. + css = "normal" # "font-stretch' property of webfont CSS. + + + [buildPlans.iosevka-custom.widths.extended] + shape = 7 + menu = 7 + css = "expanded" + # End width section ``` 3. Run `npm run build -- contents::` and the built fonts would be avaliable in `dist/`. Aside from `contents::`, other options are: @@ -134,10 +158,12 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a - `no-cv-ss` : Prevent generation of `cv##` and `ss##` features. + * Styles for ligation sets, include: * `ligset-dlig`: Default ligation set would be assigned to Discretionary ligatures. + * `ligset-clike`: Default ligation set would be assigned to C-Like. * `ligset-javascript`: Default ligation set would be assigned to JavaScript. * `ligset-php`: Default ligation set would be assigned to PHP. * `ligset-ml`: Default ligation set would be assigned to ML. @@ -147,7 +173,6 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a * `ligset-idris`: Default ligation set would be assigned to Idris. * `ligset-elm`: Default ligation set would be assigned to Elm. * `ligset-purescript`: Default ligation set would be assigned to PureScript. - * `ligset-patel`: Default ligation set would be assigned to PatEL. * `ligset-swift`: Default ligation set would be assigned to Swift. * `ligset-coq`: Default ligation set would be assigned to Coq. * `ligset-matlab`: Default ligation set would be assigned to Matlab. @@ -155,6 +180,7 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a + * Styles for further customizing default (`calt`) ligation sets: @@ -178,6 +204,7 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a * `calt-kern-dotty`: Move connecting dotty punctuations closer, like for `::`, `:::` and `...`.. * `calt-logic`: Enable ligation for `/\` and `\/`. * `calt-llgg`: Enable ligation for `<<`, `>>` and other angle-bracket chaining. + * `calt-llggeq`: Enable ligation for `<<=`, `>>=` as shift operator. * `calt-dotoper`: Treat dot (`.`) as operator and perform chained centering. * `calt-arrowZALE`: Treat `<=` as arrow. * `calt-arrowZAGE`: Treat `>=` as co-arrow. @@ -202,6 +229,7 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a * `exclude-check-and-cross-symbol`: Exclude `✓✔✕✖✗✘` (U+2713 – U+2718) from the font. + * Styles as stylistic sets: @@ -224,6 +252,7 @@ The current available styles for `design`/`upright`/`italic`/`oblique` options a + * Styles for individual characters. They are easy-to-understand names of the `cv##` styles, including: diff --git a/build-plans.toml b/build-plans.toml index 1a1122ed68..ff79fbce21 100644 --- a/build-plans.toml +++ b/build-plans.toml @@ -399,6 +399,104 @@ from = [ "iosevka-term-curly-slab" ] +[collectPlans.iosevka-ss01] +from = [ + "iosevka-ss01", + "iosevka-fixed-ss01", + "iosevka-term-ss01" +] + +[collectPlans.iosevka-ss02] +from = [ + "iosevka-ss02", + "iosevka-fixed-ss02", + "iosevka-term-ss02" +] + +[collectPlans.iosevka-ss03] +from = [ + "iosevka-ss03", + "iosevka-fixed-ss03", + "iosevka-term-ss03" +] + +[collectPlans.iosevka-ss04] +from = [ + "iosevka-ss04", + "iosevka-fixed-ss04", + "iosevka-term-ss04" +] + +[collectPlans.iosevka-ss05] +from = [ + "iosevka-ss05", + "iosevka-fixed-ss05", + "iosevka-term-ss05" +] + +[collectPlans.iosevka-ss06] +from = [ + "iosevka-ss06", + "iosevka-fixed-ss06", + "iosevka-term-ss06" +] + +[collectPlans.iosevka-ss07] +from = [ + "iosevka-ss07", + "iosevka-fixed-ss07", + "iosevka-term-ss07" +] + +[collectPlans.iosevka-ss08] +from = [ + "iosevka-ss08", + "iosevka-fixed-ss08", + "iosevka-term-ss08" +] + +[collectPlans.iosevka-ss09] +from = [ + "iosevka-ss09", + "iosevka-fixed-ss09", + "iosevka-term-ss09" +] + +[collectPlans.iosevka-ss10] +from = [ + "iosevka-ss10", + "iosevka-fixed-ss10", + "iosevka-term-ss10" +] + +[collectPlans.iosevka-ss11] +from = [ + "iosevka-ss11", + "iosevka-fixed-ss11", + "iosevka-term-ss11" +] + +[collectPlans.iosevka-ss12] +from = [ + "iosevka-ss12", + "iosevka-fixed-ss12", + "iosevka-term-ss12" +] + +[collectPlans.iosevka-ss13] +from = [ + "iosevka-ss13", + "iosevka-fixed-ss13", + "iosevka-term-ss13" +] + +[collectPlans.iosevka-ss14] +from = [ + "iosevka-ss14", + "iosevka-fixed-ss14", + "iosevka-term-ss14" +] + [collectPlans.iosevka-aile] from = ["iosevka-aile"] diff --git a/changes/3.0.0-rc.7.md b/changes/3.0.0-rc.7.md new file mode 100644 index 0000000000..41a1706c4c --- /dev/null +++ b/changes/3.0.0-rc.7.md @@ -0,0 +1,6 @@ + * Fixed phonetic ligatures' shape. Now they are connected more closely (#488). + * Fix shape of U+AB30, U+AB64 and U+1DE7 (#489). + * Fix export of U+478 and U+479. + * Fix shape of U+029A, U+1D08, U+1D4C (#491). + * Add U+AB66 and U+AB67 (#488). + * Fix shape of U+1DF0 (#497). diff --git a/gen/build-font.js b/gen/build-font.js index c2c44487d9..641d91f690 100644 --- a/gen/build-font.js +++ b/gen/build-font.js @@ -10,7 +10,7 @@ const { setFontMetrics } = require("../meta/aesthetics"); const regulateGlyphs = require("../support/regulate-glyph"); const gcFont = require("./gc"); -module.exports = function(para) { +module.exports = function (para) { const font = EmptyFont(); const gs = buildGlyphs(para); diff --git a/gen/empty-font.js b/gen/empty-font.js index f5b2061f0b..000423444b 100644 --- a/gen/empty-font.js +++ b/gen/empty-font.js @@ -1,6 +1,6 @@ "use strict"; -module.exports = function() { +module.exports = function () { return { head: { checkSumAdjustment: 369537602, diff --git a/gen/generator.js b/gen/generator.js index 184c9d30fc..f827673abe 100644 --- a/gen/generator.js +++ b/gen/generator.js @@ -12,7 +12,7 @@ const formLigationData = require("../support/ligation-data"); const regulateGlyphs = require("../support/regulate-glyph"); const toml = require("toml"); -main().catch((e) => { +main().catch(e => { console.error(e); process.exit(1); }); @@ -57,7 +57,7 @@ async function getParameters(argv) { version: argv.ver, weight: argv["menu-weight"] - 0, width: argv["menu-width"] - 0, - slant: argv["menu-slant"], + slant: argv["menu-slant"] }; return para; @@ -108,7 +108,7 @@ async function saveCharMap(font) { glyph.name, glyph.unicode, typographicFeatures, - glyph.featureSelector ? Object.keys(glyph.featureSelector) : [], + glyph.featureSelector ? Object.keys(glyph.featureSelector) : [] ]); } await fs.writeFile(argv.charmap, JSON.stringify(charMap), "utf8"); diff --git a/glyphs/autobuild-accents.ptl b/glyphs/autobuild-accents.ptl index 4a0617e8f6..2776830270 100644 --- a/glyphs/autobuild-accents.ptl +++ b/glyphs/autobuild-accents.ptl @@ -277,6 +277,7 @@ define customDecompositions : object ."\u0384" "\uE09D\u0301" ."\u0385" "\uE09D\u0308\u0301" ."\u037A" "\uE09D\u0345" + ."\uAB30" "\u0251\uE091" # Suppress incorrect slashed arrows... so far ."\u219A" "" diff --git a/glyphs/autobuild-transformed.ptl b/glyphs/autobuild-transformed.ptl index c79f6dacbe..c194beb9c6 100644 --- a/glyphs/autobuild-transformed.ptl +++ b/glyphs/autobuild-transformed.ptl @@ -1,7 +1,7 @@ ###### Automatic builds $$include '../meta/macros.ptl' -import [linreg clamp fallback] from '../support/utils' +import [linreg clamp mix fallback] from '../support/utils' glyph-module @@ -131,7 +131,7 @@ glyph-block Autobuild-Transformed : begin list 0x1D49 'e' list 0x1D4A 'turne' list 0x1D4B 'epsilon' - list 0x1D4C 'cyrze' + list 0x1D4C 'turnepsilon' list 0x1D4D 'g' list 0x1D4E 'turni' list 0x1D4F 'k' @@ -290,7 +290,6 @@ glyph-block Autobuild-Transformed : begin list 0x1D05 'D' list 0x1D06 'Dcroat' list 0x1D07 'E' - list 0x1D08 'cyrZe' list 0x1D0A 'J' list 0x1D0B 'K' list 0x1D0C 'Lslash' @@ -347,14 +346,14 @@ glyph-block Autobuild-Transformed : begin list 0x1DE4 's' list 0x1DE5 'longs' list 0x1DE6 'z' - list 0x1DE7 'alpha' + list 0x1DE7 'scripta' list 0x1DE8 'b' list 0x1DE9 'beta' list 0x1DEA 'turne' list 0x1DEB 'f' list 0x1DEE 'p' list 0x1DEF 'esh' - list 0x1DF0 'mu' + list 0x1DF0 'uWithLightCentralizationStroke' list 0x1DF1 'w' list 0x1DF2 'adieresis' list 0x1DF3 'odieresis' @@ -517,20 +516,11 @@ glyph-block Autobuild-Transformed : begin list 0x1CA 'N' 'J' list 0x1CB 'N' 'j' list 0x1CC 'n' 'j' - list 0x2A3 'd' 'z' list 0x1F1 'D' 'Z' list 0x1F2 'D' 'z' list 0x1F3 'd' 'z' - list 0x2A4 'd' 'ezh' - list 0x2A5 'd' 'zcurlytail' - list 0x2A6 't' 's' - list 0x2A7 't' 'esh' - list 0x2A8 't' 'ccurlytail' - list 0x2A9 'f' 'eng' - list 0x2AA 'l' 's' - list 0x2AB 'l' 'z' - list 0x478 'O' 'y' 'if' - list 0x479 'o' 'y' 'p' + list 0x478 'O' 'yhooktop' + list 0x479 'o' 'yhooktop' list 0x20A7 'P' 's' list 0x20A8 'R' 's' list 0x203c 'exclam' 'exclam' @@ -542,6 +532,70 @@ glyph-block Autobuild-Transformed : begin list 0x2103 'degree' 'C' list 0x2109 'degree' 'F' + define [createPhoneticLigatures _shrink1 _shrink2 wadj1 wadj2 records] : begin + local pendingGlyphs1 : records.map : [record] => record.1 + local pendingGlyphs2 : records.map : [record] => record.2 + local shrink1 : clamp 0 1 _shrink1 + local shrink2 : clamp 0 1 _shrink2 + local kern : SB * shrink1 + SB * shrink2 + 0.5 * STROKE * [mix shrink1 shrink2 0.5] - OX * 2 + local antiScale : (WIDTH * shrink1 + WIDTH * shrink2 - kern) / WIDTH + foreach [cycle : range 0 4] : begin + set kern : SB * shrink1 + SB * shrink2 + 0.5 * STROKE * [mix shrink1 shrink2 0.5] - OX * 2 + local tmp-shrink1 : (shrink1 * WIDTH + kern * shrink1 / (shrink1 + shrink2)) / (WIDTH * shrink1 + WIDTH * shrink2 - kern) * antiScale + local tmp-shrink2 : (shrink2 * WIDTH + kern * shrink2 / (shrink1 + shrink2)) / (WIDTH * shrink1 + WIDTH * shrink2 - kern) * antiScale + set shrink1 : clamp 0 1 tmp-shrink1 + set shrink2 : clamp 0 1 tmp-shrink2 + + local df1 : Thinner pendingGlyphs1 shrink1 + local df2 : Thinner pendingGlyphs2 shrink2 + + foreach [{unicode c1 c2} : items-of records] : begin + local glyphName "\(c1)_\(c2)" + if [query-glyph glyphName] : begin + local j 2 + while [query-glyph (glyphName + j)] : inc j + set glyphName (glyphName + j) + + define [maskOut] : create-glyph : glyph-construction + local s 0 + local step (-OX) + local dist (STROKE * 2) + while (s < dist) : begin + include df2.(c2) + apply-transform : Translate step 0 + set s : s + step + apply-transform : Translate (df1.(c1).advanceWidth * wadj1 - kern) 0 + + sketch + local sumChildrenWidth : df1.(c1).advanceWidth * wadj1 + df2.(c2).advanceWidth * wadj2 + local refW : sumChildrenWidth - kern + include df2.(c2) + include : Translate (df1.(c1).advanceWidth * wadj1 - kern) 0 + include : difference + intersection + Rect (CAP * 2) (DESCENDER * 2) (-WIDTH) (df1.(c1).advanceWidth * wadj1 - kern + df2.(c2).advanceWidth * wadj2 / 2) + glyph-construction : include df1.(c1) + maskOut + include : Upright + include : Translate (-refW / 2) 0 + include : Scale [clamp 0 1 ((WIDTH - SB * 1.25) / (WIDTH - SB * 2) * WIDTH / refW)] 1 + include : Translate (WIDTH / 2) 0 + include : Italify + save glyphName unicode + + if [not recursive] : createPhoneticLigatures stdShrink stdShrink 1 1 : list + list 0x02A3 'd' 'z' + list 0x02A4 'd' 'ezh' + list 0x02A5 'd' 'zcurlytail' + list 0x02A6 't.phoneticLeft' 's.phoneticRight' + list 0x02A7 't.phoneticLeft.extended' 'esh' + list 0x02A8 't.phoneticLeft' 'ccurlytail' + list 0x02A9 'f.phoneticLeft' 'eng' + list 0x02AA 'l.phoneticLeft' 's.phoneticRight' + list 0x02AB 'l.phoneticLeft' 'z' + list 0xAB66 'd' 'zrtailBR' + list 0xAB67 't.phoneticLeft' 'srtail' + define [createAccentedEquals crowd scale records] : begin local pendingGlyphs : records.map : [record] => record.2 diff --git a/glyphs/common-shapes.ptl b/glyphs/common-shapes.ptl index 1e38647145..f32818920b 100644 --- a/glyphs/common-shapes.ptl +++ b/glyphs/common-shapes.ptl @@ -200,7 +200,7 @@ glyph-block CommonShapes : begin define [CircleRingAt x y r] : CircleRing (y + r) (y - r) (x - r) (x + r) define [CircleDotAt x y r] : CircleRing (y + r) (y - r) (x - r) (x + r) true - define [OShape u d l r _width _sma _smb ai] : glyph-construction + define [OShape u d l r _width _sma _smb] : glyph-construction local middle : (l + r) / 2 local width : fallback _width STROKE local sma : fallback _sma SMALLSMOOTHA @@ -211,13 +211,13 @@ glyph-block CommonShapes : begin widths width 0 g4 (middle - mc) (u - O) archv - [if ai flat.ai flat] (l + OX) (u - sma) - [if ai curl.ai curl] (l + OX) (d + smb) + flat (l + OX) (u - sma) + curl (l + OX) (d + smb) arcvh g4 (middle + mc) (d + O) archv - [if ai flat.ai flat] (r - OX) (d + sma) - [if ai curl.ai curl] (r - OX) (u - smb) + flat (r - OX) (d + sma) + curl (r - OX) (u - smb) arcvh close : else : begin @@ -234,7 +234,7 @@ glyph-block CommonShapes : begin g4 (r - OX) ymiddleb arcvh close - define [OShapeOutline u d l r _width _sma _smb ai] : glyph-construction + define [OShapeOutline u d l r _width _sma _smb] : glyph-construction local middle : (l + r) / 2 local width : fallback _width STROKE local sma : fallback _sma SMALLSMOOTHA @@ -244,13 +244,13 @@ glyph-block CommonShapes : begin include : spiro-outline g4 (middle - mc) (u - O) archv - [if ai flat.ai flat] (l + OX) (u - sma) - [if ai curl.ai curl] (l + OX) (d + smb) + flat (l + OX) (u - sma) + curl (l + OX) (d + smb) arcvh g4 (middle + mc) (d + O) archv - [if ai flat.ai flat] (r - OX) (d + sma) - [if ai curl.ai curl] (r - OX) (u - smb) + flat (r - OX) (d + sma) + curl (r - OX) (u - smb) arcvh close : else : begin @@ -280,8 +280,8 @@ glyph-block CommonShapes : begin arcvh g4 (mb) O [widths.heading STROKE 0 {.y (1) .x (-sb)}] archv - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) flat.ai flat] (RIGHTSB - OX) (0 + SMALLSMOOTHA) - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) curl.ai curl] (RIGHTSB - OX) (top - SMALLSMOOTHB) + flat (RIGHTSB - OX) (0 + SMALLSMOOTHA) + curl (RIGHTSB - OX) (top - SMALLSMOOTHB) arcvh g4 (mt) (top - O) [widths.heading STROKE 0 {.y (-1) .x (-st)}] archv @@ -782,26 +782,31 @@ glyph-block CommonShapes : begin include : difference background [union.apply null candidates] include overlay - define [CreateWaveShape dist sw] : begin + define [CreateWaveShape dist sw _phaesShift] : begin define WaveResolution 64 define WaveMagnitude : dist * (3 / 4) - sw / 2 define WaveAdj : TANSLANT * WaveMagnitude * (-0.75) - define [WaveShapeImpl] : params [left right ts te xsJoin xfJoin] : glyph-construction + define phaseShift : fallback _phaesShift 0 + define [WaveShapeImpl] : params [left right ts te xsJoin xfJoin diagJoinS diagJoinF] : glyph-construction local resolution : Math.ceil (WaveResolution * (te - ts)) local knots {} foreach [pr : range 0 till resolution] : begin - local theta : [mix ts te (pr / resolution)] * Math.PI * 2 + local theta : (phaseShift + [mix ts te (pr / resolution)]) * Math.PI * 2 local waveRelY : (-1) * [Math.sin theta] - 0.075 * [Math.sin (theta * 3)] knots.push : g2 (WaveAdj * waveRelY) + [mix left right (pr / resolution)] symbolMid + WaveMagnitude * waveRelY include : dispiro widths.center sw - if (xsJoin !== nothing) {[straight.right.start xsJoin symbolMid]} {} + if (xsJoin === nothing) {} : if diagJoinS + list [g2 xsJoin symbolMid] + list [straight.right.start xsJoin symbolMid] begin knots - if (xfJoin !== nothing) {[straight.right.end xfJoin symbolMid]} {} + if (xfJoin === nothing) {} : if diagJoinF + list [g2 xfJoin symbolMid] + list [straight.right.end xfJoin symbolMid] - define [WaveShape] : params [left right xsJoin xfJoin [waveCount 1] [unitWidth WIDTH]] : WaveShapeImpl (unitWidth * -left) (unitWidth * (1 + right)) (-left * waveCount) ((1 + right) * waveCount) xsJoin xfJoin + define [WaveShape] : params [left right xsJoin xfJoin diagJoinS diagJoinF [waveCount 1] [unitWidth WIDTH]] : WaveShapeImpl (unitWidth * -left) (unitWidth * (1 + right)) (-left * waveCount) ((1 + right) * waveCount) xsJoin xfJoin diagJoinS diagJoinF return WaveShape define [NameUni unicode] : begin diff --git a/glyphs/letters-unified-basic.ptl b/glyphs/letters-unified-basic.ptl index 3747db745c..ac83df68cf 100644 --- a/glyphs/letters-unified-basic.ptl +++ b/glyphs/letters-unified-basic.ptl @@ -492,6 +492,21 @@ glyph-block LetterUnified-Basic : begin set-anchor 'topright' BASE (df.middle + RIGHTSB - MIDDLE) CAP save 'l.italic' + sketch # l.phoneticLeft + local df : DivFrame 1 + set-width df.width + include df.markSet.b + define middle : SB + STROKE * HVCONTRAST + include : dispiro + widths.center + flat middle CAP [heading DOWNWARD] + curl middle HOOK + arcvh + flat (middle + HOOK - HALFSTROKE) HALFSTROKE + curl [Math.max RIGHTSB (middle + [Math.max HOOKX (LONGJUT * 1.05 * df.div)])] HALFSTROKE [heading RIGHTWARD] + set-anchor 'topright' BASE (df.middle + RIGHTSB - MIDDLE) CAP + save 'l.phoneticLeft' + sketch # l.tailed local df : DivFrame para.diversityI set-width df.width @@ -919,28 +934,48 @@ glyph-block LetterUnified-Basic : begin sketch # turnlargescripta include MarkSet.capital - include : OBarRightShape CAP - start-from RIGHTSB 0 - line-to (RIGHTSB - STROKE * HVCONTRAST) 0 - line-to (RIGHTSB - STROKE * HVCONTRAST) (CAP - STROKE / 2) - line-to RIGHTSB (CAP - O) + include : union + OBarRightShape CAP + spiro-outline + corner RIGHTSB 0 + corner (RIGHTSB - STROKE * HVCONTRAST) 0 + corner (RIGHTSB - STROKE * HVCONTRAST) (CAP - STROKE / 2) + corner RIGHTSB (CAP - O) save 'largescripta' 0x2C6D include : FlipAround MIDDLE (CAP / 2) save 'turnlargescripta' 0x2C70 sketch # scripta include MarkSet.e - include : OBarRightShape - start-from RIGHTSB 0 - line-to (RIGHTSB - STROKE * HVCONTRAST) 0 - line-to (RIGHTSB - STROKE * HVCONTRAST) (XH - STROKE / 2) - line-to RIGHTSB (XH - O) + include : union + OBarRightShape + spiro-outline + corner RIGHTSB 0 + corner (RIGHTSB - STROKE * HVCONTRAST) 0 + corner (RIGHTSB - STROKE * HVCONTRAST) (XH - STROKE / 2) + corner RIGHTSB (XH - O) if SLAB : begin include : RightwardBottomSerif RIGHTSB 0 SIDEJUT tag-contour 'serifRB' save 'scripta' 0x0251 + include : FlipAround MIDDLE (XH / 2) + save 'turnscripta' 0x252 + + sketch # invLatinAlpha + include MarkSet.e + include : union + OBarRightShape + spiro-outline + corner RIGHTSB XH + corner (RIGHTSB - STROKE * HVCONTRAST) XH + corner (RIGHTSB - STROKE * HVCONTRAST) (STROKE / 2) + corner RIGHTSB O + if SLAB : begin + include : RightwardTopSerif RIGHTSB XH SIDEJUT + tag-contour 'serifRT' + save 'invLatinAlpha' 0xAB64 + turned 'turna' 0x250 'a.doublestorey' MIDDLE (XH / 2) - turned nothing 0x252 'scripta' MIDDLE (XH / 2) sketch # artail include [refer-glyph 'a.doublestorey'] AS_BASE @@ -1947,33 +1982,63 @@ glyph-block LetterUnified-Basic : begin local midy : top * BARPOS local smb : top - [mix (midy + stroke / 2) (top - O - stroke) (SMOOTHA / (SMOOTHA + SMOOTHB))] + TANSLANT * HVCONTRAST * stroke local sma : [mix (stroke + O) (midy - stroke / 2) (SMOOTHA / (SMOOTHA + SMOOTHB))] - TANSLANT * HVCONTRAST * stroke + local fine : stroke * CTHIN include : dispiro - widths.lhs - flat mid (midy - stroke / 2) [heading RIGHTWARD] - curl MIDDLE (midy - stroke / 2) + widths.lhs fine + flat mid (midy - (stroke - fine) / 2) [heading RIGHTWARD] + curl MIDDLE (midy - (stroke - fine) / 2) [heading RIGHTWARD] archv - g4 (RIGHTSB + O) (top - smb) + g4 (RIGHTSB - OXE) (top - smb) [widths.lhs stroke] arcvh g4 (MIDDLE - CORRECTION_OMIDS) (top - O) archv - flat.ai (SB + O) (top - SMALLSMOOTHA) - curl.ai (SB + O) SMALLSMOOTHB + flat (SB + O) (top - SMALLSMOOTHA) + curl (SB + O) SMALLSMOOTHB arcvh g4 (MIDDLE + CORRECTION_OMIDS) O archv - g4 (RIGHTSB - O) (sma) + g4 (RIGHTSB - OXE - O * 2) (sma) arcvh - flat MIDDLE (midy + stroke / 2) - curl mid (midy + stroke / 2) [heading LEFTWARD] + flat MIDDLE (midy + (stroke - fine) / 2) [widths.heading fine 0 LEFTWARD] + curl mid (midy + (stroke - fine) / 2) [widths.heading fine 0 LEFTWARD] + + define [ClosedEpsilonShape top] : glyph-construction + local stroke : adviceBlackness2 2.875 2 top + local mid : mix SB RIGHTSB 0.65 + local midy : top * BARPOS + local sma : top - [mix (midy + stroke / 2) (top - O - stroke) (SMOOTHB / (SMOOTHA + SMOOTHB))] - TANSLANT * HVCONTRAST * STROKE + local smb : [mix (STROKE + O) (midy - stroke / 2) (SMOOTHB / (SMOOTHA + SMOOTHB))] + TANSLANT * HVCONTRAST * stroke + local fine : stroke * CTHIN + include : dispiro + widths.rhs fine + flat mid (midy - (stroke - fine) / 2) [heading LEFTWARD] + curl MIDDLE (midy - (stroke - fine) / 2) [heading LEFTWARD] + archv + g4 (SB + OXE) (top - sma) [widths.rhs stroke] + arcvh + g4 (MIDDLE - CORRECTION_OMIDS) (top - O) + archv + flat (RIGHTSB - O) (top - SMALLSMOOTHB) + curl (RIGHTSB - O) SMALLSMOOTHA + arcvh + g4 (MIDDLE + CORRECTION_OMIDS) O + archv + g4 (SB + OXE + O * 2) (smb) + arcvh + flat MIDDLE (midy + (stroke - fine) / 2) [widths.heading 0 fine RIGHTWARD] + curl mid (midy + (stroke - fine) / 2) [widths.heading 0 fine RIGHTWARD] + sketch # cyrve.italic include MarkSet.e include : ItalicCyrveShape XH save 'cyrve.italic' save 'closeturnepsilon' 0x25E + sketch # cyrve.BGR include MarkSet.e include : ItalicCyrveShape CAP save 'cyrve.BGR' + sketch # cyrve.upright include MarkSet.e include : BShape XH @@ -1981,6 +2046,11 @@ glyph-block LetterUnified-Basic : begin save 'smcpB' 0x299 italic-variant 'cyrve' 0x432 + sketch # closedepsilon + include MarkSet.e + include : ClosedEpsilonShape XH + save 'closeepsilon' 0x29A + sketch # Bbar include [refer-glyph 'B'] AS_BASE include : HOverlayBar [mix SB 0 0.7] [mix SB RIGHTSB 0.5] [mix 0 CAP 0.3] [Math.min ((CAP - STROKE * 3) / 4) OVERLAYSTROKE] @@ -2684,8 +2754,8 @@ glyph-block LetterUnified-Basic : begin widths.lhs g4 RIGHTSB (XH - HOOK) hookstart XO - flat.ai (SB + OX) (XH - SMALLSMOOTHA) - curl.ai (SB + OX) (0 + SMALLSMOOTHB) + flat (SB + OX) (XH - SMALLSMOOTHA) + curl (SB + OX) (0 + SMALLSMOOTHB) hookend O g4 RIGHTSB HOOK save 'c' 'c' @@ -2746,8 +2816,8 @@ glyph-block LetterUnified-Basic : begin widths.lhs stroke g4 RIGHTSB (XH - HOOK) hookstart XH - flat.ai (SB + OX) (XH - SMALLSMOOTHA) - curl.ai (SB + OX) SMALLSMOOTHB + flat (SB + OX) (XH - SMALLSMOOTHA) + curl (SB + OX) SMALLSMOOTHB arcvh CurlyTail fine rinner m1 0 RIGHTSB x2 y2 linreg 500 (0.5) 375 (-0.25) : Math.min WIDTH 500 @@ -2797,13 +2867,13 @@ glyph-block LetterUnified-Basic : begin flat (MIDDLE + 1) (XH - O) curl MIDDLE (XH - O) archv - flat.ai (SB + OX) (XH - SMALLSMOOTHA) - curl.ai (SB + OX) SMALLSMOOTHB + flat (SB + OX) (XH - SMALLSMOOTHA) + curl (SB + OX) SMALLSMOOTHB arcvh g4 (MIDDLE + CORRECTION_OMIDS) O archv - flat.ai (RIGHTSB - OX * 0.5) SMALLSMOOTHA - curl.ai (RIGHTSB - OX * 0.5) (XH - SMALLSMOOTHB) + flat (RIGHTSB - OX * 0.5) SMALLSMOOTHA + curl (RIGHTSB - OX * 0.5) (XH - SMALLSMOOTHB) arcvh flat MIDDLE (XH - HALFSTROKE - O) [widths HALFSTROKE 0] curl (MIDDLE - 1) (XH - HALFSTROKE - O) @@ -2815,8 +2885,8 @@ glyph-block LetterUnified-Basic : begin widths.lhs g4 RIGHTSB (XH - HOOK) hookstart XH - flat.ai (SB + OX) (XH - SMALLSMOOTHA) - curl.ai (SB + OX) SMALLSMOOTHB + flat (SB + OX) (XH - SMALLSMOOTHA) + curl (SB + OX) SMALLSMOOTHB arcvh g4 (MIDDLE + CORRECTION_OMIDS) 0 alsothru 0.5 0.1353 @@ -3033,7 +3103,7 @@ glyph-block LetterUnified-Basic : begin sketch # o set-width WIDTH include MarkSet.e - include : OShape XH 0 SB RIGHTSB nothing nothing nothing true + include : OShape XH 0 SB RIGHTSB nothing nothing nothing set-anchor 'trailing' BASE MIDDLE 0 save 'o' 'o' save 'omicron' 0x3BF @@ -3053,7 +3123,7 @@ glyph-block LetterUnified-Basic : begin include : HornBaseAnchor RIGHTSB XH (WIDTH / 2) (SMOOTHB) (-1) include : difference HornShape RIGHTSB XH (WIDTH / 2) (SMOOTHB) (-1) - OShapeOutline (XH + O) (0 - O) (SB - O) (RIGHTSB + O) nothing nothing nothing true + OShapeOutline (XH + O) (0 - O) (SB - O) (RIGHTSB + O) nothing nothing nothing include : refer-glyph "o" save 'oHorn' 0x01A1 @@ -3904,21 +3974,33 @@ glyph-block LetterUnified-Basic : begin hookstart (CAP - O - fovershoot2) (tight -- true) flat barleft (CAP - SMOOTHA * 0.8 - fovershoot2) curl barleft 0 [heading DOWNWARD] - include : dispiro - widths.rhs - flat ([mix SB RIGHTSB 0] - HALFSTROKE * TANSLANT) fbar - curl ([mix SB RIGHTSB 0.95] - HALFSTROKE * TANSLANT) fbar branch - save 'f.straight' - save 'lenisf' 0xAB35 + include : dispiro + widths.rhs + flat ([mix SB RIGHTSB 0] - HALFSTROKE * TANSLANT) fbar + curl ([mix SB RIGHTSB 0.95] - HALFSTROKE * TANSLANT) fbar + + branch + save 'f.straight' + save 'lenisf' 0xAB35 + + branch + include : dispiro + widths.lhs + flat ([mix SB RIGHTSB 0.02] + HALFSTROKE * TANSLANT) 0 + curl ([mix SB RIGHTSB 0.875] + HALFSTROKE * TANSLANT) 0 + save 'f.serifed' branch include : dispiro - widths.lhs - flat ([mix SB RIGHTSB 0.02] + HALFSTROKE * TANSLANT) 0 - curl ([mix SB RIGHTSB 0.875] + HALFSTROKE * TANSLANT) 0 - save 'f.serifed' + widths.rhs + flat ([mix SB RIGHTSB 0] - HALFSTROKE * TANSLANT) fbar + curl (RIGHTSB - HALFSTROKE * TANSLANT) fbar + + branch + save 'f.phoneticLeft' + define dfNarrowF : DivFrame para.diversityF sketch # f.narrow @@ -4058,8 +4140,8 @@ glyph-block LetterUnified-Basic : begin arcvh g4 (MIDDLE - CORRECTION_OMIDS) (top - O) archv - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) flat.ai flat] (SB + OX) (top - SMALLSMOOTHA) - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) curl.ai curl] (SB + OX) (0 + SMALLSMOOTHB) + flat (SB + OX) (top - SMALLSMOOTHA) + curl (SB + OX) (0 + SMALLSMOOTHB) hookend O (sw -- stroke) g4 (RIGHTSB - OX * [if para.isItalic 0 0.5]) hook include : HBarBottom (SB + (stroke / 2) + OX) (RIGHTSB - (stroke / 2) - OX) barbottom stroke @@ -4094,8 +4176,8 @@ glyph-block LetterUnified-Basic : begin arcvh g4 MIDDLE (top - O) archv - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) flat.ai flat] (RIGHTSB - OX) (top - SMALLSMOOTHB) - [if ((SMALLSMOOTHA + SMALLSMOOTHB) / top > 0.75) curl.ai curl] (RIGHTSB - OX) SMALLSMOOTHA + flat (RIGHTSB - OX) (top - SMALLSMOOTHB) + curl (RIGHTSB - OX) SMALLSMOOTHA hookend O (sw -- stroke) g4 (SB + O) AHOOK include : HBarBottom (SB + (stroke / 2)) (RIGHTSB - (stroke / 2)) barbottom stroke @@ -4194,27 +4276,46 @@ glyph-block LetterUnified-Basic : begin include MarkSet.b include : SmallTShape CAP 0 save 't.standard' + + define [TFlatShape df m ext] : glyph-construction + local crossLeft : mix 0 SB m + local crossRight : mix df.width df.rightSB m + local barleft : [mix crossLeft crossRight 0.42] - STROKE * 0.375 * HVCONTRAST + local tTurn : Math.max (HOOK * 0.9) (STROKE * 1.375) : Math.min HOOK (STROKE * 1.75) + include : union + dispiro + widths.rhs + flat (crossRight) 0 + curl [Math.min (barleft + tTurn) (crossRight - 1)] 0 + archv + flat barleft tTurn + curl barleft CAP [heading UPWARD] + dispiro + widths.rhs + flat (crossLeft - HALFSTROKE * TANSLANT) XH + curl (crossRight - HALFSTROKE * TANSLANT + ext) XH + set-anchor 'topright' BASE crossRight CAP + sketch # t.narrow local df : DivFrame para.diversityF set-width df.width include df.markSet.b - local crossLeft : mix 0 SB (1 / 2) - local crossRight : mix df.width df.rightSB (1 / 2) - local barleft : [mix crossLeft crossRight 0.42] - STROKE * 0.375 * HVCONTRAST - local tTurn : Math.max (HOOK * 0.9) (STROKE * 1.375) : Math.min HOOK (STROKE * 1.75) - include : dispiro - widths.rhs - flat crossRight 0 - curl [Math.min (barleft + tTurn) (crossRight - 1)] 0 - archv - flat barleft tTurn - curl barleft CAP [heading UPWARD] - include : dispiro - widths.rhs - flat (crossLeft - HALFSTROKE * TANSLANT) XH - curl (crossRight - HALFSTROKE * TANSLANT) XH - set-anchor 'topright' BASE crossRight CAP + include : TFlatShape df 0.5 0 save 't.narrow' + sketch # t.phoneticLeft + local df : DivFrame 1 + set-width df.width + include df.markSet.b + include : TFlatShape df 1 0 + save 't.phoneticLeft' + sketch # t.phoneticLeft.extended + local df : DivFrame 1 + set-width df.width + include df.markSet.b + include : intersection + TFlatShape df 1 WIDTH + Rect CAP 0 SB (MIDDLE + WIDTH) + save 't.phoneticLeft.extended' sketch # t.cross set-width WIDTH include MarkSet.b @@ -4317,6 +4418,22 @@ glyph-block LetterUnified-Basic : begin hookend O (sw -- stroke) (swItalicAdj -- STROKE) g4 (SB - OX / 4) SHOOK + define [sStrokePhoneticRight] : begin + define stroke : adviceBlackness2 2.875 2 XH + define ess : mix stroke (ESS * stroke / STROKE) 0.5 + define strokeCoeff : linreg 18 0 126 1 stroke + define smooth : adviceSSmooth XH (-1) stroke + return : dispiro + widths.lhs stroke + g4 (RIGHTSB + OX / 4) (XH - SHOOK) + hookstart XO (sw -- stroke) (swItalicAdj -- STROKE) + g4 (SB + OX / 8) (XH - smooth) + SNeck stroke (slantCoeff -- -0.01) + g4 (RIGHTSB - OX / 8) (smooth) [widths 0 stroke] + arcvh + flat (MIDDLE - CORRECTION_OMIDS) 0 [widths 0 STROKE] + curl SB 0 + define [RevsStroke] : begin define stroke : adviceBlackness2 2.875 2 XH define ess : ESS * stroke / STROKE @@ -4344,6 +4461,11 @@ glyph-block LetterUnified-Basic : begin save 's' 's' save 'cyrdze' 0x455 + sketch # s + include MarkSet.e + include : sStrokePhoneticRight + save 's.phoneticRight' + sketch # revS include MarkSet.capital include : RevSStroke diff --git a/glyphs/letters-unified-extended.ptl b/glyphs/letters-unified-extended.ptl index f9e0c108d5..8f3cfe24bd 100644 --- a/glyphs/letters-unified-extended.ptl +++ b/glyphs/letters-unified-extended.ptl @@ -28,8 +28,8 @@ glyph-block LetterUnified-Extended : begin bezcontrols k1 k2 k3 1 6 g4.left.mid (middle + CORRECTION_OMIDS) O [widths 0 STROKE] archv - flat.ai (SB + OX * 2) SMALLSMOOTHB - curl.ai (SB + OX * 2) (XH - SMALLSMOOTHA) + flat (SB + OX * 2) SMALLSMOOTHB + curl (SB + OX * 2) (XH - SMALLSMOOTHA) arcvh g4.right.mid (middle - CORRECTION_OMIDS) XO [widths 0 STROKE] bezcontrols (1 - k3) 0 (1 - k1) (1 - k2) 6 @@ -38,7 +38,6 @@ glyph-block LetterUnified-Extended : begin set-anchor 'overlay' BASE (middle - OX) (XH * OVERLAYPOS) save 'alpha' 0x3B1 - save 'latinalpha' 0xAB64 define [GammaShape top] : glyph-construction include : VBarLeft (SB * 1.5) 0 top @@ -143,13 +142,13 @@ glyph-block LetterUnified-Extended : begin arcvh 2 g4 xOTLeft bar [heading RIGHTWARD] alsothruthem : list {0.25 0.05} {0.5 0.13} - flat.ai (RIGHTSB - OX) (bar - smb) - curl.ai (RIGHTSB - OX) sma + flat (RIGHTSB - OX) (bar - smb) + curl (RIGHTSB - OX) sma arcvh g4.left.mid (MIDDLE + CORRECTION_OMIDS) O archv - flat.ai (SB + OX) smb - curl.ai (SB + OX) (bar - sma) + flat (SB + OX) smb + curl (SB + OX) (bar - sma) arcvh g4 xOTLeft (bar - (STROKE - fine) / 2) [widths 0 fine] @@ -168,8 +167,8 @@ glyph-block LetterUnified-Extended : begin arcvh g4 (MIDDLE - CORRECTION_OMIDS) (CAP * 0.7 - O) [widths.rhs STROKE] archv - flat.ai (RIGHTSB - OX) (XH - SMALLSMOOTHB) - curl.ai (RIGHTSB - OX) SMALLSMOOTHA + flat (RIGHTSB - OX) (XH - SMALLSMOOTHB) + curl (RIGHTSB - OX) SMALLSMOOTHA arcvh g4 (MIDDLE + CORRECTION_OMIDS) O archv @@ -206,6 +205,9 @@ glyph-block LetterUnified-Extended : begin include : SmallEpsilonShape XH save 'epsilon' 0x3B5 save 'latinepsilon' 0x25B + include : FlipAround MIDDLE (XH / 2) + save 'turnepsilon' 0x1D08 + sketch # latinEpsilon include MarkSet.capital @@ -254,8 +256,6 @@ glyph-block LetterUnified-Extended : begin include : CyrZeShape XH save 'cyrze' 0x437 save 'revlatinepsilon' 0x25C - turned 'closeepsilon' 0x29A 'closeturnepsilon' MIDDLE (XH / 2) - sketch # Theta include MarkSet.capital @@ -317,7 +317,7 @@ glyph-block LetterUnified-Extended : begin sketch include MarkSet.p - include : refer-glyph "u" + include : refer-glyph "u.withBar" include : dispiro widths.rhs flat SB DESCENDER [heading UPWARD] @@ -327,6 +327,30 @@ glyph-block LetterUnified-Extended : begin include : LeftwardTopSerif SB XH SIDEJUT save 'mu' 0x3BC + sketch + include MarkSet.p + include : refer-glyph "u.withBar" + local fine : adviceBlackness 4 + local outStand : SB * 0.75 + fine * 0.25 + local outStandY : SMALLSMOOTHB / 2 - DESCENDER * 0.6 + local yTurn : SMALLSMOOTHB / 2 + include : difference + dispiro + widths.lhs fine + corner (SB + outStand) (yTurn + outStandY) + corner (SB - outStand) (yTurn - outStandY) + spiro-outline + corner (SB - O) XH + curl (SB - O) SMALLSMOOTHB + arcvh + g4 (MIDDLE + CORRECTION_OMIDS) (-O) + archv + flat (RIGHTSB + O) SMALLSMOOTHA + corner (RIGHTSB + O) XH + if SLAB : begin + include : LeftwardTopSerif SB XH SIDEJUT + + save 'uWithLightCentralizationStroke' sketch include MarkSet.capital @@ -465,7 +489,7 @@ glyph-block LetterUnified-Extended : begin local y1 0 local y2 XH include : VBar df.middle DESCENDER (y1 + HALFSTROKE) - include : OShape y2 y1 df.leftSB df.rightSB df.mvs (SMOOTHA * df.div) (SMOOTHB * df.div) nothing true + include : OShape y2 y1 df.leftSB df.rightSB df.mvs (SMOOTHA * df.div) (SMOOTHB * df.div) nothing include : VBar df.middle y1 y2 df.mvs include : VBar df.middle (y2 - HALFSTROKE) CAP save 'varphi' 0x3D5 @@ -944,8 +968,8 @@ glyph-block LetterUnified-Extended : begin arcvh g4 (MIDDLE - CORRECTION_OMIDS) (CAP * 0.7 - O) [widths.lhs] archv - flat.ai (SB + OX) (XH - SMALLSMOOTHA) - curl.ai (SB + OX) SMALLSMOOTHB + flat (SB + OX) (XH - SMALLSMOOTHA) + curl (SB + OX) SMALLSMOOTHB arcvh g4 (MIDDLE + CORRECTION_OMIDS) O archv diff --git a/glyphs/symbol-arrow.ptl b/glyphs/symbol-arrow.ptl index 0501cffb80..a2c7221beb 100644 --- a/glyphs/symbol-arrow.ptl +++ b/glyphs/symbol-arrow.ptl @@ -33,6 +33,14 @@ glyph-block Symbol-Arrow : begin define doubleArrowStemWidth : arrowSize * 1.1 define waveArrowAmplitude : (WIDTH - SB) * designParameters.arrow_size * 1.1 + # Diagonal arrow params + define diagPropX : 1 / [Math.pow 2 (1 / 4)] + define diagPropY : 1 / [Math.pow 2 (1 / 4)] + define arrowDiagRSB : mix arrowMidX arrowRSB diagPropX + define arrowDiagSB : mix arrowMidX arrowSB diagPropX + define arrowDiagBot : mix arrowMidX arrowBot diagPropY + define arrowDiagTop : mix arrowMidX arrowTop diagPropY + define [ArrowBar x1 y1 x2 y2 halfstroke w] : glyph-construction include : PointingTo x1 y1 x2 y2 : lambda [mag] : begin local p : (mag - o - halfstroke * [fallback w 1.1]) / mag @@ -209,20 +217,21 @@ glyph-block Symbol-Arrow : begin arrow [HookArrowShape 1] [MangleName 'hookarrowleft'] [MangleUnicode 0x21A9] arrowRSB symbolMid arrowSB symbolMid arrow [HookArrowShape (-1)] [MangleName 'hookarrowright'] [MangleUnicode 0x21AA] arrowSB symbolMid arrowRSB symbolMid - arrow [HookArrowShape (-1)] [MangleName 'hookarrowupleft'] [MangleUnicode 0x2923] arrowRSB arrowBot arrowSB arrowTop - arrow [HookArrowShape 1] [MangleName 'hookarrowupright'] [MangleUnicode 0x2924] arrowSB arrowBot arrowRSB arrowTop - arrow [HookArrowShape (-1)] [MangleName 'hookarrowdownright'] [MangleUnicode 0x2925] arrowSB arrowTop arrowRSB arrowBot - arrow [HookArrowShape 1] [MangleName 'hookarrowdownleft'] [MangleUnicode 0x2926] arrowRSB arrowTop arrowSB arrowBot anglearrow ArrowShape [lambda [x1 y1 x2 y2] : VBarLeft x1 y1 y2] [MangleName 'arrow-up-angle-right'] [MangleUnicode 0x21b1] arrowSB arrowBot arrowSB (arrowTop - arrowSize) arrowRSB (arrowTop - arrowSize) anglearrow ArrowShape [lambda [x1 y1 x2 y2] : VBarRight x1 y1 y2] [MangleName 'arrow-up-angle-left'] [MangleUnicode 0x21b0] arrowRSB arrowBot arrowRSB (arrowTop - arrowSize) arrowSB (arrowTop - arrowSize) anglearrow ArrowShape [lambda [x1 y1 x2 y2] : VBarLeft x1 y1 y2] [MangleName 'arrow-down-angle-right'] [MangleUnicode 0x21b3] arrowSB arrowTop arrowSB (arrowBot + arrowSize) arrowRSB (arrowBot + arrowSize) anglearrow ArrowShape [lambda [x1 y1 x2 y2] : VBarRight x1 y1 y2] [MangleName 'arrow-down-angle-left'] [MangleUnicode 0x21b2] arrowRSB arrowTop arrowRSB (arrowBot + arrowSize) arrowSB (arrowBot + arrowSize) - arrow ArrowShape [MangleName 'arrowupleft'] [MangleUnicode 0x2196] arrowRSB arrowBot arrowSB arrowTop - arrow ArrowShape [MangleName 'arrowupright'] [MangleUnicode 0x2197] arrowSB arrowBot arrowRSB arrowTop - arrow ArrowShape [MangleName 'arrowdownright'] [MangleUnicode 0x2198] arrowSB arrowTop arrowRSB arrowBot - arrow ArrowShape [MangleName 'arrowdownleft'] [MangleUnicode 0x2199] arrowRSB arrowTop arrowSB arrowBot + arrow ArrowShape [MangleName 'arrowupleft'] [MangleUnicode 0x2196] arrowDiagRSB arrowDiagBot arrowDiagSB arrowDiagTop + arrow ArrowShape [MangleName 'arrowupright'] [MangleUnicode 0x2197] arrowDiagSB arrowDiagBot arrowDiagRSB arrowDiagTop + arrow ArrowShape [MangleName 'arrowdownright'] [MangleUnicode 0x2198] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + arrow ArrowShape [MangleName 'arrowdownleft'] [MangleUnicode 0x2199] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot + + arrow [HookArrowShape (-1)] [MangleName 'hookarrowupleft'] [MangleUnicode 0x2923] arrowDiagRSB arrowDiagBot arrowDiagSB arrowDiagTop + arrow [HookArrowShape 1] [MangleName 'hookarrowupright'] [MangleUnicode 0x2924] arrowDiagSB arrowDiagBot arrowDiagRSB arrowDiagTop + arrow [HookArrowShape (-1)] [MangleName 'hookarrowdownright'] [MangleUnicode 0x2925] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + arrow [HookArrowShape 1] [MangleName 'hookarrowdownleft'] [MangleUnicode 0x2926] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot arrow [HalfArrowShape RHSHalfArrowHead] [MangleName 'arrowleftHR'] [MangleUnicode 0x21BC] arrowRSB symbolMid arrowSB symbolMid arrow [HalfArrowShape LHSHalfArrowHead] [MangleName 'arrowleftHL'] [MangleUnicode 0x21BD] arrowRSB symbolMid arrowSB symbolMid @@ -279,20 +288,20 @@ glyph-block Symbol-Arrow : begin arrow [ThickArrowShape 'white'] [MangleName 'uni21E7'] [MangleUnicode 0x21E7] arrowMidX arrowBot arrowMidX arrowTop arrow [ThickArrowShape 'white'] [MangleName 'uni21E8'] [MangleUnicode 0x21E8] arrowSB symbolMid arrowRSB symbolMid arrow [ThickArrowShape 'white'] [MangleName 'uni21E9'] [MangleUnicode 0x21E9] arrowMidX arrowTop arrowMidX arrowBot - arrow [ThickArrowShape 'white'] [MangleName 'uni2B00'] [MangleUnicode 0x2B00] arrowSB arrowBot arrowRSB arrowTop - arrow [ThickArrowShape 'white'] [MangleName 'uni2B01'] [MangleUnicode 0x2B01] arrowRSB arrowBot arrowSB arrowTop - arrow [ThickArrowShape 'white'] [MangleName 'uni2B02'] [MangleUnicode 0x2B02] arrowSB arrowTop arrowRSB arrowBot - arrow [ThickArrowShape 'white'] [MangleName 'uni2B03'] [MangleUnicode 0x2B03] arrowRSB arrowTop arrowSB arrowBot + arrow [ThickArrowShape 'white'] [MangleName 'uni2B00'] [MangleUnicode 0x2B00] arrowDiagSB arrowDiagBot arrowDiagRSB arrowDiagTop + arrow [ThickArrowShape 'white'] [MangleName 'uni2B01'] [MangleUnicode 0x2B01] arrowDiagRSB arrowDiagBot arrowDiagSB arrowDiagTop + arrow [ThickArrowShape 'white'] [MangleName 'uni2B02'] [MangleUnicode 0x2B02] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + arrow [ThickArrowShape 'white'] [MangleName 'uni2B03'] [MangleUnicode 0x2B03] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot arrow [ThickArrowShape 'black'] [MangleName 'uni2B05'] [MangleUnicode 0x2B05] arrowRSB symbolMid arrowSB symbolMid arrow [ThickArrowShape 'black'] [MangleName 'uni2B06'] [MangleUnicode 0x2B06] arrowMidX arrowBot arrowMidX arrowTop arrow [ThickArrowShape 'black'] [MangleName 'uni27A1'] [MangleUnicode 0x27A1] arrowSB symbolMid arrowRSB symbolMid arrow [ThickArrowShape 'black'] [MangleName 'uni2B95'] [MangleUnicode 0x2B95] arrowSB symbolMid arrowRSB symbolMid arrow [ThickArrowShape 'black'] [MangleName 'uni2B07'] [MangleUnicode 0x2B07] arrowMidX arrowTop arrowMidX arrowBot - arrow [ThickArrowShape 'black'] [MangleName 'uni2B08'] [MangleUnicode 0x2B08] arrowSB arrowBot arrowRSB arrowTop - arrow [ThickArrowShape 'black'] [MangleName 'uni2B09'] [MangleUnicode 0x2B09] arrowRSB arrowBot arrowSB arrowTop - arrow [ThickArrowShape 'black'] [MangleName 'uni2B0A'] [MangleUnicode 0x2B0A] arrowSB arrowTop arrowRSB arrowBot - arrow [ThickArrowShape 'black'] [MangleName 'uni2B0B'] [MangleUnicode 0x2B0B] arrowRSB arrowTop arrowSB arrowBot + arrow [ThickArrowShape 'black'] [MangleName 'uni2B08'] [MangleUnicode 0x2B08] arrowDiagSB arrowDiagBot arrowDiagRSB arrowDiagTop + arrow [ThickArrowShape 'black'] [MangleName 'uni2B09'] [MangleUnicode 0x2B09] arrowDiagRSB arrowDiagBot arrowDiagSB arrowDiagTop + arrow [ThickArrowShape 'black'] [MangleName 'uni2B0A'] [MangleUnicode 0x2B0A] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + arrow [ThickArrowShape 'black'] [MangleName 'uni2B0B'] [MangleUnicode 0x2B0B] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot arrow ArrowShape [MangleName 'arrowleftK'] null arrowRSB symbolMid (arrowSB + fine) symbolMid arrow ArrowShape [MangleName 'arrowrightK'] null arrowSB symbolMid (arrowRSB - fine) symbolMid @@ -318,15 +327,15 @@ glyph-block Symbol-Arrow : begin arrow [DoubleArrowShape dasw] [MangleName 'dblarrowright'] [MangleUnicode 0x21D2] arrowSB symbolMid arrowRSB symbolMid arrow [DoubleArrowShape dasw] [MangleName 'dblarrowup'] [MangleUnicode 0x21D1] arrowMidX arrowBot arrowMidX arrowTop arrow [DoubleArrowShape dasw] [MangleName 'dblarrowdown'] [MangleUnicode 0x21D3] arrowMidX arrowTop arrowMidX arrowBot - arrow [DoubleArrowShape dasw] [MangleName 'dblarrowupleft'] [MangleUnicode 0x21D6] arrowRSB arrowBot arrowSB arrowTop - arrow [DoubleArrowShape dasw] [MangleName 'dblarrowupright'] [MangleUnicode 0x21D7] arrowSB arrowBot arrowRSB arrowTop - arrow [DoubleArrowShape dasw] [MangleName 'dblarrowdownright'] [MangleUnicode 0x21D8] arrowSB arrowTop arrowRSB arrowBot - arrow [DoubleArrowShape dasw] [MangleName 'dblarrowdownleft'] [MangleUnicode 0x21D9] arrowRSB arrowTop arrowSB arrowBot + arrow [DoubleArrowShape dasw] [MangleName 'dblarrowupleft'] [MangleUnicode 0x21D6] arrowDiagRSB arrowDiagBot arrowDiagSB arrowDiagTop + arrow [DoubleArrowShape dasw] [MangleName 'dblarrowupright'] [MangleUnicode 0x21D7] arrowDiagSB arrowDiagBot arrowDiagRSB arrowDiagTop + arrow [DoubleArrowShape dasw] [MangleName 'dblarrowdownright'] [MangleUnicode 0x21D8] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + arrow [DoubleArrowShape dasw] [MangleName 'dblarrowdownleft'] [MangleUnicode 0x21D9] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot DoubleArrow ArrowShape [MangleName 'arrowleftright'] [MangleUnicode 0x2194] arrowSB symbolMid arrowRSB symbolMid DoubleArrow ArrowShape [MangleName 'arrowupdown'] [MangleUnicode 0x2195] arrowMidX arrowTop arrowMidX arrowBot - DoubleArrow ArrowShape [MangleName 'arrowupleftdownright'] [MangleUnicode 0x2921] arrowSB arrowTop arrowRSB arrowBot - DoubleArrow ArrowShape [MangleName 'arrowuprightdownleft'] [MangleUnicode 0x2922] arrowRSB arrowTop arrowSB arrowBot + DoubleArrow ArrowShape [MangleName 'arrowupleftdownright'] [MangleUnicode 0x2921] arrowDiagSB arrowDiagTop arrowDiagRSB arrowDiagBot + DoubleArrow ArrowShape [MangleName 'arrowuprightdownleft'] [MangleUnicode 0x2922] arrowDiagRSB arrowDiagTop arrowDiagSB arrowDiagBot let [dasw doubleArrowStemWidth] : do DoubleArrow [DoubleArrowShape dasw] [MangleName 'dblarrowleftright'] [MangleUnicode 0x21D4] arrowSB symbolMid arrowRSB symbolMid diff --git a/glyphs/symbol-other.ptl b/glyphs/symbol-other.ptl index 5741b62410..7c25cea10b 100644 --- a/glyphs/symbol-other.ptl +++ b/glyphs/symbol-other.ptl @@ -1139,39 +1139,35 @@ glyph-block Symbol-Other-Ligation : begin local arrowheadsKern : (2 / 3) * [clamp 0 (WIDTH * 0.4) (WIDTH - OPERATORSTROKE * 3)] define arrowheadSlope : 1 / lessSlantness - define [ArrowBarConfig extend kern join] : begin + define [ArrowBarConfig extend kern join doubleBar] : begin define cleft O define cright (WIDTH - O) - define arrowr : WIDTH + extend - define arrowl : 0 - extend + define arrowr : if doubleBar + WIDTH + SB + OPERATORSTROKE * HVCONTRAST + WIDTH + extend + define arrowl : if doubleBar + -WIDTH + RIGHTSB - OPERATORSTROKE * HVCONTRAST + 0 - extend define zleft : cleft - WIDTH + RIGHTSB define zright : cright + SB - define sleft : -WIDTH + RIGHTSB - OPERATORSTROKE * HVCONTRAST - define sright : WIDTH + SB + OPERATORSTROKE * HVCONTRAST define lk : object f SB l arrowl l1 : arrowl - kern - l2 : arrowl - kern * 2 c cleft j (-join) j1 (-join - kern) z zleft - s sleft - s1 : sleft - kern lx : mix arrowl 0 0.5 define rk : object f RIGHTSB r arrowr r1 : arrowr + kern - r2 : arrowr + kern * 2 c cright j (WIDTH + join) j1 (WIDTH + join + kern) z zright - s sright - s1 : sright + kern define result {} foreach [l : items-of : Object.keys lk] : foreach [r : items-of : Object.keys rk] @@ -1180,7 +1176,7 @@ glyph-block Symbol-Other-Ligation : begin local arrowExtend [clamp 0 WIDTH (RIGHTSB - OPERATORSTROKE / 2 * arrowheadSlope)] local arrowJ : clamp 0 WIDTH (SB + OPERATORSTROKE / 2 * arrowheadSlope) - foreach [{subclass left right} : items-of [ArrowBarConfig arrowExtend arrowheadsKern arrowJ]] : sketch + foreach [{subclass left right} : items-of [ArrowBarConfig arrowExtend arrowheadsKern arrowJ false]] : sketch include : HBar left right symbolMid OPERATORSTROKE set currentGlyph.cmpPriority (-3) save ('hyphen.lig.' + subclass) @@ -1192,50 +1188,52 @@ glyph-block Symbol-Other-Ligation : begin local dblExtend : clamp 0 WIDTH (RIGHTSB - (dblArrowD - dblArrowSw / 2) * arrowheadSlope) local dblArrowJ : clamp 0 WIDTH (SB + (dblArrowD - dblArrowSw / 2) * arrowheadSlope) - foreach [{subclass left right} : items-of [ArrowBarConfig dblExtend arrowheadsKern dblArrowJ]] : sketch + foreach [{subclass left right} : items-of [ArrowBarConfig dblExtend arrowheadsKern dblArrowJ true]] : sketch include : HBarTop left right (symbolMid + dblArrowD) dblArrowSw include : HBarBottom left right (symbolMid - dblArrowD) dblArrowSw set currentGlyph.cmpPriority (-3) save ('equal.lig.' + subclass) do "Waves" - define WaveShape : CreateWaveShape dblArrowD dblArrowSw + define WaveShape : CreateWaveShape dblArrowD dblArrowSw (-1 / 4) define LR (2 / 32) define LR1 (9 / 32) define Z (1 / 4) define F (-1 / 4) + define C 0 + define J (-1 / 8) - sketch - include : WaveShape LR LR (xsJoin -- (-arrowExtend)) (xfJoin -- (WIDTH + arrowExtend)) - save 'wave.lr' - sketch - include : WaveShape LR F (xsJoin -- (-arrowExtend)) - save 'wave.lf' - sketch - include : WaveShape LR1 F (xsJoin -- (-arrowExtend - arrowheadsKern)) - save 'wave.l1f' - sketch - include : WaveShape LR Z (xsJoin -- (-arrowExtend)) - save 'wave.lz' - sketch - include : WaveShape Z F - save 'wave.zf' - sketch - include : WaveShape F LR (xfJoin -- (WIDTH + arrowExtend)) - save 'wave.fr' - sketch - include : WaveShape F LR1 (xfJoin -- (WIDTH + arrowExtend + arrowheadsKern)) - save 'wave.fr1' - sketch - include : WaveShape Z LR (xfJoin -- (WIDTH + arrowExtend)) - save 'wave.zr' - sketch - include : WaveShape F Z - save 'wave.fz' - sketch - include : WaveShape Z Z - save 'wave.zz' + define lk : object + l { LR (-arrowExtend) false } + l1 { LR1 (-arrowExtend - arrowheadsKern) false } + f { F nothing false } + z { Z nothing false } + c { C nothing false } + j { J (-arrowJ) true } + j1 { J (-arrowJ - arrowheadsKern) true } + + define rk : object + r { LR (WIDTH + arrowExtend) false } + r1 { LR1 (WIDTH + arrowExtend + arrowheadsKern) false } + f { F nothing false } + z { Z nothing false } + c { C nothing false } + j { J (WIDTH + arrowJ) true } + j1 { J (WIDTH + arrowJ + arrowheadsKern) true } + + foreach [lS : items-of : Object.keys lk] : foreach [rS : items-of : Object.keys rk] : sketch + local {tL jL djL} lk.(lS) + local {tR jR djR} rk.(rS) + include : WaveShape + left -- tL + right -- tR + xsJoin -- jL + xfJoin -- jR + diagJoinS -- djL + diagJoinF -- djR + + save "wave.\(lS)\(rS)" do "Arrowheads" glyph-block-import Symbol-Math-Relation : dH LigationLessShape LigationGreaterShape @@ -1243,12 +1241,14 @@ glyph-block Symbol-Other-Ligation : begin sketch include : LigationLessShape (symbolMid + dH) (symbolMid - dH) SB RIGHTSB OPERATORSTROKE dblArrowSw (dblArrowD * 2 - dblArrowSw * 2) save 'less.lig.dblhead' + save 'less.lig.dblhead.mid' include : Translate (-arrowheadsKern) 0 save 'less.lig.dblhead.shift1' sketch include : LigationGreaterShape (symbolMid + dH) (symbolMid - dH) SB RIGHTSB OPERATORSTROKE dblArrowSw (dblArrowD * 2 - dblArrowSw * 2) save 'greater.lig.dblhead' + save 'greater.lig.dblhead.mid' include : Translate (+arrowheadsKern) 0 save 'greater.lig.dblhead.shift1' @@ -1261,6 +1261,8 @@ glyph-block Symbol-Other-Ligation : begin sketch include [refer-glyph 'greater'] AS_BASE ALSO_METRICS save 'greater.lig.shift0' + save 'greater.lig.shift0.mid' + save 'greater.lig.shift0.anti' include : Translate (arrowheadsKern / 2) 0 save 'greater.lig.shift0h' include : Translate (arrowheadsKern / 2) 0 @@ -1274,6 +1276,7 @@ glyph-block Symbol-Other-Ligation : begin sketch include [refer-glyph 'greater'] AS_BASE ALSO_METRICS save 'greater.lig.shiftN0' + save 'greater.lig.shiftN0.mid' include : Translate (-arrowheadsKern / 2) 0 save 'greater.lig.shiftN0h' include : Translate (-arrowheadsKern / 2) 0 @@ -1287,6 +1290,8 @@ glyph-block Symbol-Other-Ligation : begin sketch include [refer-glyph 'less'] AS_BASE ALSO_METRICS save 'less.lig.shift0' + save 'less.lig.shift0.mid' + save 'less.lig.shift0.anti' include : Translate (-arrowheadsKern / 2) 0 save 'less.lig.shift0h' include : Translate (-arrowheadsKern / 2) 0 @@ -1327,13 +1332,13 @@ glyph-block Symbol-Other-Ligation : begin include : difference glyph-construction : include : refer-glyph "less.lig.shiftN1" ArrowHeadHole - save 'less.lig.shiftN1.hole' + save 'less.lig.hole.shiftN1' sketch include : difference glyph-construction : include : refer-glyph "greater.lig.shiftN1" ArrowHeadHole - save 'greater.lig.shiftN1.hole' + save 'greater.lig.hole.shiftN1' do "Equal and Inequal" : if [not recursive] : begin glyph-block-import Symbol-Math-Relation : EqualShape EqualHole IdentShape IdentHole diff --git a/images/charvars.png b/images/charvars.png index abd1558783..47fe21a7d2 100644 Binary files a/images/charvars.png and b/images/charvars.png differ diff --git a/images/languages.png b/images/languages.png index 004d1cb6f4..f0afae5dd0 100644 Binary files a/images/languages.png and b/images/languages.png differ diff --git a/images/ligations.png b/images/ligations.png index 49cc89ac3f..69eae2ead1 100644 Binary files a/images/ligations.png and b/images/ligations.png differ diff --git a/images/matrix.png b/images/matrix.png index ff5bf820ae..13dc9c52e9 100644 Binary files a/images/matrix.png and b/images/matrix.png differ diff --git a/images/preview-all.png b/images/preview-all.png index 3cb5edea63..b07e35d194 100644 Binary files a/images/preview-all.png and b/images/preview-all.png differ diff --git a/images/stylesets.png b/images/stylesets.png index b8ee5e05fd..761c087f00 100644 Binary files a/images/stylesets.png and b/images/stylesets.png differ diff --git a/images/weights.png b/images/weights.png index f9a79df110..8b29c5e173 100644 Binary files a/images/weights.png and b/images/weights.png differ diff --git a/ligation-set.toml b/ligation-set.toml index b692f99558..440a63e9be 100644 --- a/ligation-set.toml +++ b/ligation-set.toml @@ -78,6 +78,10 @@ desc = 'Enable ligation for `/\` and `\/`' ligGroup = "llgg" desc = 'Enable ligation for `<<`, `>>` and other angle-bracket chaining' +[simple.calt-llggeq] +ligGroup = "llggeq" +desc = 'Enable ligation for `<<=`, `>>=` as shift operator' + [simple.calt-dotoper] ligGroup = "dotoper" desc = 'Treat dot (`.`) as operator and perform chained centering' @@ -95,9 +99,9 @@ ligGroup = "html-comment" desc = 'Enable ligation for ` - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lc'] - hyphen ~> [only 'arrow' : lsx 'cc'] - hyphen ~> [only 'arrow' : lsx 'cc'] - hyphen ~> [only 'arrow' : lsx 'cr'] - greater ~> preserved - chain-rule # <===> - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'sc'] - equal ~> [only 'arrow' : lsx 'cc'] - equal ~> [only 'arrow' : lsx 'cs'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # <---> - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lc'] - hyphen ~> [only 'arrow' : lsx 'cc'] - hyphen ~> [only 'arrow' : lsx 'cr'] - greater ~> preserved - chain-rule # <==> - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'sc'] - equal ~> [only 'arrow' : lsx 'cs'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # <--> - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lc'] - hyphen ~> [only 'arrow' : lsx 'cr'] - greater ~> preserved - chain-rule # <=> - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'ss'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # <-> - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lr'] - greater ~> preserved - chain-rule # <~> - less ~> preserved - anyWave ~> [only 'arrow' : just 'wave.lr'] - greater ~> preserved - chain-rule # <--< - less ~> preserved - hyphen ~> [only 'arrow2' : lsx 'lc'] - hyphen ~> [only 'arrow2' : lsx 'cj'] - less ~> preserved - chain-rule # <==< - less ~> [only 'arrow2' : lsx 'dblhead'] - equal ~> [only 'arrow2' : lsx 'sc'] - equal ~> [only 'arrow2' : lsx 'cj'] - less ~> [only 'arrow2' : lsx 'hole'] - chain-rule # <-< - less ~> preserved - hyphen ~> [only 'arrow2' : lsx 'lj'] - less ~> preserved - chain-rule # <=< - less ~> [only 'arrow2' : lsx 'dblhead'] - equal ~> [only 'arrow2' : lsx 'sj'] - less ~> [only 'arrow2' : lsx 'hole'] - chain-rule # <=== - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'sc'] - equal ~> [only 'arrow' : lsx 'cc'] - equal ~> [only 'arrow' : lsx 'cf'] - chain-rule # <--- - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lc'] - hyphen ~> [only 'arrow' : lsx 'cc'] - hyphen ~> [only 'arrow' : lsx 'cf'] - chain-rule # <=| - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'sj'] - anyBar ~> preserved - chain-rule # <-| - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lj'] - anyBar ~> preserved - chain-rule # <== - less ~> [only 'arrow' : lsx 'dblhead'] - equal ~> [only 'arrow' : lsx 'sc'] - equal ~> [only 'arrow' : lsx 'cf'] - chain-rule # <-- - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lc'] - hyphen ~> [only 'arrow' : lsx 'cf'] - chain-rule # <<= - less ~> [only 'arrow' : lsx 'shift0'] - less ~> [only 'arrow' : lsx 'dblhead.shift1'] - equal ~> [only 'arrow' : lsx 's1f'] - chain-rule # <<- - less ~> [only 'arrow' : lsx 'shift0'] - less ~> [only 'arrow' : lsx 'shift1'] - hyphen ~> [only 'arrow' : lsx 'l1f'] - chain-rule # <<- - less ~> [only 'arrow' : lsx 'shift0'] - less ~> [only 'arrow' : lsx 'shift1'] - anyWave ~> [only 'arrow' : just 'wave.l1f'] - chain-rule # <- - less ~> preserved - hyphen ~> [only 'arrow' : lsx 'lf'] - chain-rule # <~ - less ~> preserved - anyWave ~> [only 'arrow' : just 'wave.lf'] - chain-rule # <= - less ~> preserved - equal ~> [only 'arrowZALE' : lsx 'sf'] - chain-rule # - greater ~> preserved - hyphen ~> [only 'arrow2' : lsx 'jc'] - hyphen ~> [only 'arrow2' : lsx 'cr'] - greater ~> preserved - chain-rule # >==> - greater ~> [only 'arrow2' : lsx 'hole'] - equal ~> [only 'arrow2' : lsx 'jc'] - equal ~> [only 'arrow2' : lsx 'cs'] - greater ~> [only 'arrow2' : lsx 'dblhead'] - chain-rule # >-> - greater ~> preserved - hyphen ~> [only 'arrow2' : lsx 'jr'] - greater ~> preserved - chain-rule # >=> - greater ~> [only 'arrow2' : lsx 'hole'] - equal ~> [only 'arrow2' : lsx 'js'] - greater ~> [only 'arrow2' : lsx 'dblhead'] - chain-rule # >- - greater ~> preserved - hyphen ~> [only 'arrow2' : lsx 'jf'] - chain-rule # ===> - equal ~> [only 'arrow': lsx 'fc'] - equal ~> [only 'arrow': lsx 'cc'] - equal ~> [only 'arrow': lsx 'cs'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # ---> - hyphen ~> [only 'arrow': lsx 'fc'] - hyphen ~> [only 'arrow': lsx 'cc'] - hyphen ~> [only 'arrow': lsx 'cr'] - greater ~> preserved - chain-rule # ==> - equal ~> [only 'arrow': lsx 'fc'] - equal ~> [only 'arrow': lsx 'cs'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # --> - hyphen ~> [only 'arrow': lsx 'fc'] - hyphen ~> [only 'arrow': lsx 'cr'] - greater ~> preserved - chain-rule # |=> - anyBar ~> preserved - equal ~> [only 'arrow': lsx 'js'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # |-> - anyBar ~> preserved - hyphen ~> [only 'arrow': lsx 'jr'] - greater ~> preserved - chain-rule # =>= - equal ~> [only 'arrow2' : lsx 'fs'] - greater ~> [only 'arrow2' : lsx 'dblhead'] - equal ~> [only 'arrow2' : lsx 'jf'] - chain-rule # ->- - hyphen ~> [only 'arrow2' : lsx 'fr'] - greater ~> preserved - hyphen ~> [only 'arrow2' : lsx 'jf'] - chain-rule # =>> - equal ~> [only 'arrow' : lsx 'fs1'] - greater ~> [only 'arrow' : lsx 'dblhead.shift1'] - greater ~> [only 'arrow' : lsx 'shift0'] - chain-rule # ->> - hyphen ~> [only 'arrow' : lsx 'fr1'] - greater ~> [only 'arrow' : lsx 'shift1'] - greater ~> [only 'arrow' : lsx 'shift0'] - chain-rule # ->> - anyWave ~> [only 'arrow' : just 'wave.fr1'] - greater ~> [only 'arrow' : lsx 'shift1'] - greater ~> [only 'arrow' : lsx 'shift0'] - chain-rule # => - equal ~> [only 'arrow' : lsx 'fs'] - greater ~> [only 'arrow' : lsx 'dblhead'] - chain-rule # -> - hyphen ~> [only 'arrow' : lsx 'fr'] - greater ~> preserved - chain-rule # ~> - anyWave ~> [only 'arrow' : just 'wave.fr'] - greater ~> preserved - chain-rule # =<= - equal ~> [only 'arrow2' : lsx 'fj'] - less ~> [only 'arrow2' : lsx 'dblhead'] - equal ~> [only 'arrow2' : lsx 'sf'] - chain-rule # -<- - hyphen ~> [only 'arrow2' : lsx 'fj'] - less ~> preserved - hyphen ~> [only 'arrow2' : lsx 'lf'] - chain-rule # -<< - hyphen ~> [only 'arrow2' : lsx 'fj1'] - less ~> [only 'arrow2' : lsx 'shiftN1'] - less ~> preserved - chain-rule # =<< - equal ~> [only 'arrow2' : lsx 'fj1'] - less ~> [only 'arrow2' : lsx 'shiftN1.hole'] - less ~> preserved - chain-rule # =< - equal ~> [only 'arrow2' : lsx 'fj'] - less ~> [only 'arrow2' : lsx 'hole'] - chain-rule # -< - hyphen ~> [only 'arrow2' : lsx 'fj'] - less ~> preserved - chain-rule # >= - greater ~> [only 'arrowZAGE' : lsx 'hole'] - equal ~> [only 'arrowZAGE' : lsx 'jf'] - - # <<, >>, <<<, >>> - includeLookup - .type 'gsub_chaining' - .subtables : list - # Disable regular expression lookaheads - chain-rule - {'parenLeft'} ~> preserved - {'question'} ~> preserved - regexLookAround ~> advance - regexLookAround ~> advance - regexLookAround ~> advance - regexLookAround ~> advance - chain-rule - {'parenLeft'} ~> preserved - {'question'} ~> preserved - regexLookAround ~> advance - regexLookAround ~> advance - regexLookAround ~> advance - chain-rule - {'parenLeft'} ~> preserved - {'question'} ~> preserved - regexLookAround ~> advance - regexLookAround ~> advance - chain-rule # <<< - less ~> [only 'llgg' : lsx 'shiftN0h'] - less ~> preserved - less ~> [only 'llgg' : lsx 'shift0h'] - chain-rule # >>> - greater ~> [only 'llgg' : lsx 'shift0h'] - greater ~> preserved - greater ~> [only 'llgg' : lsx 'shiftN0h'] - chain-rule # << - less ~> [only 'llgg' : lsx 'shiftN0h'] - less ~> [only 'llgg' : lsx 'shift0h'] - chain-rule # >> - greater ~> [only 'llgg' : lsx 'shift0h'] - greater ~> [only 'llgg' : lsx 'shiftN0h'] - - # Cancel alternates of < and > shapes if there are more after them - local lAll {"less" "less.lig.shift0h" "less.lig.shiftN0h"} - local lNeut {"less" "less" "less"} - local gAll {"greater" "greater.lig.shift0h" "greater.lig.shiftN0h"} - local gNeut {"greater" "greater" "greater"} - local lgAll : lAll.concat gAll - local lgNeut : lNeut.concat gNeut - includeLookup - .type 'gsub_chaining' - .subtables : list - chain-rule - lgAll ~> [only 'llgg' lgNeut] - lgAll ~> [only 'llgg' lgNeut] - lgAll ~> [only 'llgg' lgNeut] - lgAll ~> preserved - includeLookup - .type 'gsub_chaining' - .subtables : list - chain-rule - lgAll ~> preserved - lgAll ~> preserved - lgAll ~> preserved - lgAll ~> [only 'llgg' lgNeut] - includeLookup # Cleanup mixes - .type 'gsub_chaining' - .subtables : list - chain-rule - lAll ~> [only 'llgg' lNeut] - lAll ~> [only 'llgg' lNeut] - gAll ~> [only 'llgg' gNeut] - chain-rule - gAll ~> [only 'llgg' gNeut] - gAll ~> [only 'llgg' gNeut] - lAll ~> [only 'llgg' lNeut] - chain-rule - lAll ~> [only 'llgg' lNeut] - gAll ~> [only 'llgg' gNeut] - gAll ~> [only 'llgg' gNeut] - chain-rule - gAll ~> [only 'llgg' gNeut] - lAll ~> [only 'llgg' lNeut] - lAll ~> [only 'llgg' lNeut] - - # Extended arrow sticks - # ---------------------> - includeLookup - .type 'gsub_reverse' - .subtables : list - object - match {{'hyphen' 'equal'} [stickClass 'fr']} - to [stickClass 'fz'] - inputIndex 0 - object - match {{'hyphen' 'equal'} [stickClass 'fc']} - to [stickClass 'fz'] - inputIndex 0 - object - match {{'hyphen' 'equal'} [stickClass 'fz']} - to [stickClass 'fz'] - inputIndex 0 - object - match {anyWave {'wave.fr' 'wave.fz'}} - to [waveClass 'fz'] - inputIndex 0 - # <--------------------, <-------------------> - includeLookup - .type 'gsub_chaining' - .subtables : list - chain-rule ([stickClass 'cf'] ~> [stickClass 'cc']) ([stickClass 'fc'] ~> [stickClass 'cc']) - chain-rule ([stickClass 'zf'] ~> [stickClass 'zc']) ([stickClass 'fr'] ~> [stickClass 'cr']) - chain-rule ([stickClass 'zf'] ~> [stickClass 'zc']) ([stickClass 'fc'] ~> [stickClass 'cc']) - chain-rule ([stickClass 'lf'] ~> [stickClass 'lc']) ([stickClass 'fz'] ~> [stickClass 'cz']) - chain-rule ([stickClass 'cf'] ~> [stickClass 'cc']) ([stickClass 'fz'] ~> [stickClass 'cz']) - chain-rule ([stickClass 'zf'] ~> [stickClass 'zc']) ([stickClass 'fz'] ~> [stickClass 'cz']) - chain-rule [stickClass 'lf'] [stick 'zf'] - chain-rule [stickClass 'cf'] [stick 'zf'] - chain-rule [stickClass 'zf'] [stick 'zf'] - chain-rule ({'wave.lf' 'wave.zf'} ~> preserved) (anyWave ~> [just 'wave.zf']) - chain-rule ({'wave.lf'} ~> {'wave.lz'}) ({'wave.fr' 'wave.fz'} ~> preserved) - - # /\ and \/ - do "logical" : includeLookup - .type 'gsub_chaining' - .subtables : list + CreateLigationLookup : keep-if 'plusplus' : list + # +++++++++ chain-rule - slash ~> [only 'logic' : csx 'left'] - backslash ~> [only 'logic' : csx 'right'] + {'plus.lig.cr' 'plus.lig.jr'} ~> preserved + {'plus'} ~> [lsx 'jr'] chain-rule - backslash ~> [only 'logic' : csx 'left'] - slash ~> [only 'logic' : csx 'right'] + {'plus'} ~> [lsx 'lc'] + {'plus'} ~> [lsx 'cc'] + {'plus'} ~> [lsx 'cc'] + {'plus'} ~> [lsx 'cr'] chain-rule - bar ~> preserved - hyphen ~> [only 'logic' : lsx 'jf'] + {'plus'} ~> [lsx 'lc'] + {'plus'} ~> [lsx 'cc'] + {'plus'} ~> [lsx 'cr'] chain-rule - hyphen ~> [only 'logic' : lsx 'fj'] - bar ~> preserved + {'plus'} ~> [lsx 'lc'] + {'plus'} ~> [lsx 'cr'] + CreateLigationLookup : keep-if 'plusplus' : list + chain-rule # +++ + {'plus.lig.lc'} ~> {'plus.lig.lc.s'} + {'plus.lig.cc'} ~> preserved + {'plus.lig.cr'} ~> {'plus.lig.cr.s'} + chain-rule # ++ + {'plus.lig.lc'} ~> {'plus.lig.lc.s'} + {'plus.lig.cr'} ~> {'plus.lig.cr.s'} + + do "triangles" : begin + CreateLigationLookup : keep-if 'trig' : list + chain-rule # <| + less ~> [lsx 'trig'] + {'bar'} ~> [lsx 'trig'] + chain-rule # |> + {'bar'} ~> [lsx 'trig'] + greater ~> [lsx 'trig'] + chain-rule # |> + [[lsx 'trig'] {'bar'}] ~> preserved + greater ~> [lsx 'trig'] + chain-rule # <|||| + [[lsx 'trig'] {'bar'}] ~> preserved + {'bar'} ~> [lsx 'trig'] + CreateReverseLigationLookup : keep-if 'trig' : list + reverse-rule + {'bar'} ~> [[lsx 'trig'] {'bar'}] + [[lsx 'trig'] {'bar'}] ~> preserved + + do "shift-eq operators (<<= and >>=)" + CreateLigationLookup : keep-if "llggeq" : list + chain-rule # =<<<= + equal ~> preserved + less ~> advance + less ~> advance + less ~> advance + equal ~> preserved + chain-rule # <<<== + less ~> advance + less ~> advance + less ~> advance + equal ~> preserved + equal ~> preserved + chain-rule # <<<= + less ~> [lsx 'shiftN0h'] + less ~> preserved + less ~> [lsx 'shift0h'] + equal ~> preserved + chain-rule # =>>>= + equal ~> preserved + greater ~> advance + greater ~> advance + greater ~> advance + equal ~> preserved + chain-rule # >>>== + greater ~> advance + greater ~> advance + greater ~> advance + equal ~> preserved + equal ~> preserved + chain-rule # >>>= + greater ~> [lsx 'shift0h'] + greater ~> preserved + greater ~> [lsx 'shiftN0h'] + equal ~> preserved + chain-rule # =<<= + equal ~> preserved + less ~> advance + less ~> advance + equal ~> preserved + chain-rule # <<== + less ~> advance + less ~> advance + equal ~> preserved + equal ~> preserved + chain-rule # <<= + less ~> [lsx 'shiftN0h'] + less ~> [lsx 'shift0h'] + equal ~> preserved + chain-rule # =>>= + equal ~> preserved + greater ~> advance + greater ~> advance + equal ~> preserved + chain-rule # >>== + greater ~> advance + greater ~> advance + equal ~> preserved + equal ~> preserved + chain-rule # >>= + greater ~> [lsx 'shift0h'] + greater ~> [lsx 'shiftN0h'] + equal ~> preserved + + do "HTML Comment" + CreateLigationLookup : keep-if 'html-comment' : list + chain-rule # \n\n` + + `\n` + + `\n\n` + this.data + `\n\n` ); @@ -152,7 +153,7 @@ async function processLigSetPreDef() { const md = new MdCol("Section-Cherry-Picking-Predefined"); md.log(`* Styles for ligation sets, include:\n`); for (const gr in ligData.rawSets) { - if (ligData.rawSets[gr].disableHives) continue; + if (ligData.rawSets[gr].isOptOut) continue; const longDesc = ligData.rawSets[gr].longDesc || `Default ligation set would be assigned to ${ligData.rawSets[gr].desc}`; diff --git a/utility/export-data/ligation-data.js b/utility/export-data/ligation-data.js index cb76bca4fa..3e7af0b5a5 100644 --- a/utility/export-data/ligation-data.js +++ b/utility/export-data/ligation-data.js @@ -23,6 +23,8 @@ const logc = TAG("logic"); const brst = TAG("brst"); const trig = TAG("trig"); const ltgt = TAG("ltgt-diamond", "ltgt-ne"); +const llggeq_a = TAG("arrow", "llggeq"); +const llggeq_b = TAG("arrow2", "llggeq"); const dotOper = TAG("dotoper"); const kernDotty = TAG("kern-dotty"); const htmlComment = TAG("html-comment"); @@ -48,7 +50,7 @@ const ligationSamples = [ arrow("<-->"), arrow("<--->"), arrow("<---->"), - htmlComment(""), arrow("--->"), - htmlComment(""), arrow("<--->"), - arrow("<---->"), + arrow("<---->") ], [ arrow("<=="), arrow("<==="), - arrow("<<="), + llggeq_a("<<="), ineq("<="), arrow("<=>"), arrow("=>"), arrow("=>>"), arrow("==>"), arrow("===>"), - htmlComment("