-
Notifications
You must be signed in to change notification settings - Fork 561
/
sha.ptl
123 lines (102 loc) · 4.23 KB
/
sha.ptl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
$$include '../../../meta/macros.ptl'
import [mix barmixL linreg clamp fallback] from '../../../support/utils'
import [DesignParameters] from '../../../meta/aesthetics'
import '../../../support/point' as Point
glyph-module
glyph-block Letter-Cyrillic-Sha : begin
glyph-block-import CommonShapes
glyph-block-import Common-Derivatives
glyph-block-import Letter-Shared-Shapes : RightwardTailedBar CyrDescender
define [CyrShaShape top df] : glyph-proc
include : union
HBarBottom df.leftSB df.rightSB 0
VBarLeft df.leftSB 0 top df.mvs
VBarRight df.rightSB 0 top df.mvs
VBar df.middle 0 top df.mvs
if SLAB : begin
include : tagged 'serifLB' : LeftwardBottomSerif df.leftSB 0 SideJut
include : tagged 'serifRB' : RightwardBottomSerif df.rightSB 0 SideJut
local jut : Jut * df.mvs / Stroke + O
if (df.width > 7 * para.refJut) : begin
include : tagged 'serifLT'
CenterTopSerif (df.leftSB + 0.5 * df.mvs * HVContrast) top jut df.mvs
include : tagged 'serifMT'
CenterTopSerif df.middle top jut df.mvs
include : tagged 'serifRT'
CenterTopSerif (df.rightSB - 0.5 * df.mvs * HVContrast) top jut df.mvs
: else : begin
include : tagged 'serifLT' : LeftwardTopSerif df.leftSB top SideJut
include : tagged 'serifRT' : RightwardTopSerif df.rightSB top SideJut
create-glyph 'cyrl/Sha' 0x428 : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include : df.markSet.capital
include : CyrShaShape CAP df
create-glyph 'cyrl/sha.upright' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include : df.markSet.e
include : CyrShaShape XH df
turned 'cyrl/sha.italic.toothed' null 'm.normal' [DivFrame para.diversityM 3].middle (XH / 2)
create-glyph 'cyrl/sha.italic.tailed' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'm.normal'] AS_BASE
eject-contour 'barL'
eject-contour 'serifLT'
include : FlipAround df.middle (XH / 2)
include : RightwardTailedBar df.rightSB 0 XH (sw -- df.mvs)
turned 'cyrl/sha.italic.motionSerifed' null 'm.topLeftAndBottomRightSerifed' [DivFrame para.diversityM 3].middle (XH / 2)
create-glyph 'cyrl/sha.italic.tailedMotionSerifed' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'm.topLeftAndBottomRightSerifed'] AS_BASE
eject-contour 'barL'
eject-contour 'serifLT'
include : FlipAround df.middle (XH / 2)
include : RightwardTailedBar df.rightSB 0 XH (sw -- df.mvs)
create-glyph 'cyrl/sha.italic.bottomRightSerifed' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'm.topLeftAndBottomRightSerifed'] AS_BASE
eject-contour 'serifRB'
include : FlipAround df.middle (XH / 2)
create-glyph 'cyrl/sha.italic.motionSerifedShachaBase' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'm.topLeftAndBottomRightSerifed'] AS_BASE
eject-contour 'serifLT'
include : FlipAround df.middle (XH / 2)
select-variant 'cyrl/sha.italic'
alias 'cyrl/sha.BGR' null 'cyrl/sha.italic'
define [CyrShchaShape top df] : glyph-proc
include : CyrShaShape top df
#eject-contour 'serifRB'
include : CyrDescender df.rightSB
create-glyph 'cyrl/Shcha' 0x429 : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include : df.markSet.capital
include : CyrShchaShape CAP df
create-glyph 'cyrl/shcha.upright' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include : df.markSet.e
include : CyrShchaShape XH df
create-glyph 'cyrl/shcha.italic.toothed' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'cyrl/sha.italic.toothed'] AS_BASE
include : CyrDescender df.rightSB
create-glyph 'cyrl/shcha.italic.motionSerifed' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'cyrl/sha.italic.motionSerifedShachaBase'] AS_BASE
include : CyrDescender df.rightSB
select-variant 'cyrl/shcha.italic'
alias 'cyrl/shcha.BGR' null 'cyrl/shcha.italic'
create-glyph 'cyrl/te.SRB' : glyph-proc
local df : DivFrame para.diversityM 3
set-width df.width
include [refer-glyph 'cyrl/sha.italic.toothed'] AS_BASE
include : refer-glyph "macronAbove"