Add feature XV__, and ligation for \/ and /\
This commit is contained in:
parent
cbe1871848
commit
b7eefb1136
|
@ -516,24 +516,41 @@ export : define [apply] : begin
|
||||||
include : VBar [mix SB RIGHTSB 0.7] (parenBot + fine) (parenTop - fine) fine
|
include : VBar [mix SB RIGHTSB 0.7] (parenBot + fine) (parenTop - fine) fine
|
||||||
save 'numbersign' '#'
|
save 'numbersign' '#'
|
||||||
|
|
||||||
sketch # slash
|
define [SlashShape l r] : glyph-construction
|
||||||
local cor : HVCONTRAST / [Math.sqrt (1 - [Math.pow ((RIGHTSB - SB - STROKE) / (parenTop - parenBot)) 2])]
|
local cor : (1 / 2) * HVCONTRAST / [Math.sqrt (1 - [Math.pow ((r - l - STROKE) / (parenTop - parenBot)) 2])]
|
||||||
start-from SB parenBot
|
start-from (l - STROKE * cor) parenBot
|
||||||
line-to (SB + STROKE * cor) parenBot
|
line-to (l + STROKE * cor) parenBot
|
||||||
line-to RIGHTSB parenTop
|
line-to (r + STROKE * cor) parenTop
|
||||||
line-to (RIGHTSB - STROKE * cor) parenTop
|
line-to (r - STROKE * cor) parenTop
|
||||||
reverse-last
|
reverse-last
|
||||||
save 'slash' '/'
|
|
||||||
alias 'solidus' 0x2044 'slash'
|
|
||||||
|
|
||||||
|
sketch # slash
|
||||||
|
include : SlashShape SB RIGHTSB
|
||||||
|
save 'slash' '/'
|
||||||
|
save 'solidus' 0x2044
|
||||||
|
sketch # slash.left
|
||||||
|
include : SlashShape SB WIDTH
|
||||||
|
save 'slash.left'
|
||||||
|
sketch # slash.right
|
||||||
|
include : SlashShape 0 RIGHTSB
|
||||||
|
save 'slash.right'
|
||||||
|
|
||||||
|
define [BackslashShape l r] : glyph-construction
|
||||||
|
local cor : (1 / 2) * HVCONTRAST / [Math.sqrt (1 - [Math.pow ((r - l - STROKE) / (parenTop - parenBot)) 2])]
|
||||||
|
start-from (l - STROKE * cor) parenTop
|
||||||
|
line-to (l + STROKE * cor) parenTop
|
||||||
|
line-to (r + STROKE * cor) parenBot
|
||||||
|
line-to (r - STROKE * cor) parenBot
|
||||||
|
local backslashWidth : (RIGHTSB - SB) * (1 + TANSLANT * 2)
|
||||||
sketch # backslash
|
sketch # backslash
|
||||||
local width : (RIGHTSB - SB) * (1 + TANSLANT * 2)
|
include : BackslashShape (MIDDLE - backslashWidth / 2) (MIDDLE + backslashWidth / 2)
|
||||||
local cor : HVCONTRAST / [Math.sqrt (1 - [Math.pow ((width - STROKE) / (parenTop - parenBot)) 2])]
|
|
||||||
start-from (MIDDLE - width / 2) parenTop
|
|
||||||
line-to (MIDDLE - width / 2 + STROKE * cor) parenTop
|
|
||||||
line-to (MIDDLE + width / 2) parenBot
|
|
||||||
line-to (MIDDLE + width / 2 - STROKE * cor) parenBot
|
|
||||||
save 'backslash' "\\"
|
save 'backslash' "\\"
|
||||||
|
sketch # backslash.left
|
||||||
|
include : BackslashShape (MIDDLE - backslashWidth / 2) WIDTH
|
||||||
|
save 'backslash.left'
|
||||||
|
sketch # backslash.right
|
||||||
|
include : BackslashShape 0 (MIDDLE + backslashWidth / 2)
|
||||||
|
save 'backslash.right'
|
||||||
|
|
||||||
|
|
||||||
### 'Dashes'
|
### 'Dashes'
|
||||||
|
|
|
@ -177,6 +177,7 @@ export : define [apply para glyphList] : begin
|
||||||
local progLigNameMap
|
local progLigNameMap
|
||||||
.XHS_ 'hask'
|
.XHS_ 'hask'
|
||||||
.XPTL 'hask'
|
.XPTL 'hask'
|
||||||
|
.XV__ 'hask'
|
||||||
foreach
|
foreach
|
||||||
: ligationFeatureName : items-of : {'calt'}.concat [Object.keys progLigNameMap]
|
: ligationFeatureName : items-of : {'calt'}.concat [Object.keys progLigNameMap]
|
||||||
: do
|
: do
|
||||||
|
@ -210,19 +211,24 @@ export : define [apply para glyphList] : begin
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # :::*
|
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # :::*
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # ::*
|
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # ::*
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # :*
|
chain-rule ({'colon'} ~> {'colon.mid'}) ({'asterisk'} ~> {'asterisk.low'}) # :*
|
||||||
chain-rule {'asterisk.low'} ({'asterisk'} ~> {'asterisk.low'}) # **
|
|
||||||
chain-rule ({'asterisk'} ~> {'asterisk.low'}) ({'colon'} ~> {'colon.mid'}) # *:
|
chain-rule ({'asterisk'} ~> {'asterisk.low'}) ({'colon'} ~> {'colon.mid'}) # *:
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # :::> :::- :::= :::< :::+
|
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # :::> :::- :::= :::< :::+
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # ::> ::- ::= ::< ::+
|
chain-rule ({'colon'} ~> {'colon.mid'}) ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # ::> ::- ::= ::< ::+
|
||||||
chain-rule ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # :> :- := :< :+
|
chain-rule ({'colon'} ~> {'colon.mid'}) {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} # :> :- := :< :+
|
||||||
chain-rule {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} ({'colon'} ~> {'colon.mid'}) # <: >: -: =: +:
|
chain-rule {'greater' 'less' 'hyphen' 'equal' 'plus' 'colon.mid'} ({'colon'} ~> {'colon.mid'}) # <: >: -: =: +:
|
||||||
chain-rule {'colon.mid'} ({'colon'} ~> {'colon.mid'}) # ::
|
|
||||||
|
|
||||||
# Colon chains
|
# Colon chains
|
||||||
chain-rule {'colon.dright' 'colon.dmid'} ({'colon'} ~> {'colon.dmid'}) {'colon'}
|
chain-rule {'colon.dright' 'colon.dmid'} ({'colon'} ~> {'colon.dmid'}) {'colon'}
|
||||||
chain-rule {'colon.dright' 'colon.dmid'} ({'colon'} ~> {'colon.dleft'})
|
chain-rule {'colon.dright' 'colon.dmid'} ({'colon'} ~> {'colon.dleft'})
|
||||||
chain-rule ({'colon'} ~> {'colon.dright'}) {'colon'}
|
chain-rule ({'colon'} ~> {'colon.dright'}) {'colon'}
|
||||||
|
|
||||||
|
# Trailings
|
||||||
|
includeLookup
|
||||||
|
.type 'gsub_chaining'
|
||||||
|
.subtables : list
|
||||||
|
chain-rule {'colon.mid'} ({'colon'} ~> {'colon.mid'}) # ::
|
||||||
|
chain-rule {'asterisk.low'} ({'asterisk'} ~> {'asterisk.low'}) # **
|
||||||
|
|
||||||
includeLookup
|
includeLookup
|
||||||
.type 'gsub_chaining'
|
.type 'gsub_chaining'
|
||||||
.subtables : list
|
.subtables : list
|
||||||
|
@ -256,7 +262,10 @@ export : define [apply para glyphList] : begin
|
||||||
:> only {'hask'}
|
:> only {'hask'}
|
||||||
chain-rule (stick ~> [lsx 'fj']) less # -<, =<
|
chain-rule (stick ~> [lsx 'fj']) less # -<, =<
|
||||||
:> only {'hask'}
|
:> only {'hask'}
|
||||||
|
chain-rule ({'slash'} ~> {'slash.left'}) ({'backslash'} ~> {'backslash.right'}) # /\
|
||||||
|
:> only {'hask'}
|
||||||
|
chain-rule ({'backslash'} ~> {'backslash.left'}) ({'slash'} ~> {'slash.right'}) # \/
|
||||||
|
:> only {'hask'}
|
||||||
|
|
||||||
#opbd
|
#opbd
|
||||||
local fwclose {'fwlcloseDoubleQuote' 'fwlcloseSingleQuote' 'dwlcjkSingleQuoteRight' 'dwlcjkDoubleQuoteRight' 'dwlparenRight'}
|
local fwclose {'fwlcloseDoubleQuote' 'fwlcloseSingleQuote' 'dwlcjkSingleQuoteRight' 'dwlcjkDoubleQuoteRight' 'dwlparenRight'}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user