218 lines
No EOL
5.5 KiB
Text
218 lines
No EOL
5.5 KiB
Text
|
|
###### NUMBERS
|
|
|
|
create-glyph 'zero.slashed' : glyph-construction {
|
|
set-width WIDTH
|
|
|
|
put-shapes glyphs.O.contours
|
|
|
|
local bar : create-stroke :.start-from [SB + STROKE / 2] [CAP * [1 - 0.65]] :.line-to [RIGHTSB - STROKE / 2] [CAP * 0.65]
|
|
put-shapes : bar.to-outline [STROKE / 2] [STROKE / 2]
|
|
}
|
|
create-glyph 'zero.unslashed' : glyph-construction {
|
|
include glyphs.O
|
|
}
|
|
create-glyph 'zero.dotted' : glyph-construction {
|
|
include glyphs.O
|
|
put-shapes : list {
|
|
Ring [CAPMIDDLE + DOTRADIUS] [CAPMIDDLE - DOTRADIUS] [MIDDLE + DOTRADIUS] [MIDDLE - DOTRADIUS]
|
|
}
|
|
}
|
|
create-glyph 'zero' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '0'
|
|
include glyphs.[match variantSelector.zero {
|
|
'slashed' 'zero.slashed'
|
|
'dotted' 'zero.dotted'
|
|
'unslahsed' 'zero.unslashed'
|
|
otherwise 'zero.slashed'
|
|
}]
|
|
}
|
|
|
|
create-glyph 'one' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '1'
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from [MIDDLE + JBALANCE * 0.6] 0
|
|
:.set-width HALFSTROKE HALFSTROKE
|
|
:.heads-to UPWARD
|
|
:.line-to [MIDDLE + JBALANCE * 0.6] CAP
|
|
:.heads-to UPWARD
|
|
:.to-outline
|
|
put-shapes : create-stroke
|
|
:.start-from [MIDDLE - HALFSTROKE + JBALANCE * 0.6] CAP
|
|
:.set-width STROKE 0
|
|
:.line-to [MIDDLE - HOOK * 1.5 + JBALANCE * 0.5] [CAP - HOOK * 0.75]
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'two' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '2'
|
|
|
|
put-shapes : twoHookUpper CAP SMOOTHB HOOK
|
|
put-shapes : sStrand STROKE [CAP - SMOOTHB]
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from SB 0
|
|
:.set-width STROKE 0
|
|
:.heads-to RIGHTWARD
|
|
:.line-to RIGHTSB 0
|
|
:.heads-to RIGHTWARD
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'three' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '3'
|
|
|
|
local threeRadius [CAPMIDDLE + HALFSTROKE - SMOOTH]
|
|
|
|
put-shapes : twoHookUpper CAP SMOOTHB HOOK
|
|
put-shapes : sHookLower 0 SMOOTHA HOOK
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from RIGHTSB [CAP - SMOOTHB]
|
|
:.set-width 0 STROKE
|
|
:.arc-vh-to [RIGHTSB - threeRadius] [CAPMIDDLE - HALFSTROKE]
|
|
:.heads-to LEFTWARD
|
|
:.to-outline
|
|
put-shapes : create-stroke
|
|
:.start-from RIGHTSB SMOOTHA
|
|
:.set-width STROKE 0
|
|
:.arc-vh-to [RIGHTSB - threeRadius] [CAPMIDDLE + HALFSTROKE]
|
|
:.heads-to LEFTWARD
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'four' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '4'
|
|
|
|
local bar [CAP * 0.4]
|
|
local vert [WIDTH * 0.55]
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from SB bar
|
|
:.set-width 0 STROKE
|
|
:.heads-to RIGHTWARD
|
|
:.line-to RIGHTSB bar
|
|
:.heads-to RIGHTWARD
|
|
:.to-outline
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from vert 0
|
|
:.set-width 0 STROKE
|
|
:.heads-to UPWARD
|
|
:.line-to vert CAP
|
|
:.heads-to UPWARD
|
|
:.to-outline
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from SB bar
|
|
:.set-width 0 STROKE
|
|
:.line-to vert CAP
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'five' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '5'
|
|
|
|
put-shapes : sHookLower 0 [[CAP * FIVEBARPOS + STROKE] / 2] HOOK
|
|
put-shapes : create-stroke
|
|
:.start-from RIGHTSB [[CAP * FIVEBARPOS + STROKE] / 2]
|
|
:.set-width STROKE 0
|
|
:.arc-vh-to MIDDLE [CAP * FIVEBARPOS + STROKE]
|
|
:.line-to [SB + TBALANCE / 2] [CAP * FIVEBARPOS + STROKE]
|
|
:.heads-to LEFTWARD
|
|
:.to-outline
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from [SB + TBALANCE / 2] CAP
|
|
:.set-width 0 STROKE
|
|
:.heads-to RIGHTWARD
|
|
:.line-to [RIGHTSB - TBALANCE / 2] CAP
|
|
:.heads-to RIGHTWARD
|
|
:.to-outline
|
|
put-shapes : create-stroke
|
|
:.start-from [SB + TBALANCE / 2] [CAP * FIVEBARPOS + STROKE]
|
|
:.set-width 0 STROKE
|
|
:.heads-to UPWARD
|
|
:.line-to [SB + TBALANCE / 2] CAP
|
|
:.heads-to UPWARD
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'six' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '6'
|
|
|
|
put-shapes : smallo [CAP * 0.6] 0 SB RIGHTSB
|
|
local ymiddlea : [CAP * 0.6 - SMALLSMOOTHA + SMALLSMOOTHB] / 2
|
|
put-shapes : create-stroke
|
|
:.start-from [SB + O] ymiddlea
|
|
:.set-width 0 STROKE
|
|
:.curve-to [SB + O] [mix ymiddlea CAP 0.8] [RIGHTSB - STROKE * 1.1] CAP
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'seven' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '7'
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from SB CAP :.heads-to RIGHTWARD :.set-width 0 STROKE
|
|
:.line-to RIGHTSB CAP :.heads-to RIGHTWARD :.to-outline
|
|
|
|
local cor 1.15
|
|
local x : mix SB RIGHTSB 0.15
|
|
|
|
start-from x 0
|
|
line-to [x + STROKE * cor] 0
|
|
line-to RIGHTSB [CAP - STROKE]
|
|
line-to [RIGHTSB - STROKE * cor] [CAP - STROKE]
|
|
reverse-last
|
|
}
|
|
|
|
create-glyph 'eight' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '8'
|
|
|
|
local sma : SMOOTHA * 0.975
|
|
local smb : SMOOTHB * 0.975
|
|
|
|
put-shapes : sStrand [CAP - sma] sma
|
|
put-shapes : sStrand smb [CAP - smb]
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from RIGHTSB [CAP - smb]
|
|
:.set-width STROKE 0
|
|
:.arc-vh-to MIDDLE [CAP - O]
|
|
:.heads-to LEFTWARD
|
|
:.arc-hv-to SB [CAP - sma]
|
|
:.to-outline
|
|
|
|
put-shapes : create-stroke
|
|
:.start-from SB smb
|
|
:.set-width STROKE 0
|
|
:.arc-vh-to MIDDLE O
|
|
:.heads-to RIGHTWARD
|
|
:.arc-hv-to RIGHTSB sma
|
|
:.to-outline
|
|
}
|
|
|
|
create-glyph 'nine' : glyph-construction {
|
|
set-width WIDTH
|
|
assign-unicode '9'
|
|
|
|
put-shapes : smallo CAP [CAP * 0.4] SB [RIGHTSB + O]
|
|
local ymiddlea : [CAP - SMALLSMOOTHB + CAP * 0.4 + SMALLSMOOTHA] / 2
|
|
put-shapes : create-stroke
|
|
:.start-from RIGHTSB ymiddlea
|
|
:.set-width 0 STROKE
|
|
:.line-to RIGHTSB [CAP * 0.4]
|
|
:.to-outline
|
|
put-shapes : sHookLower 0 [CAP * 0.4] HOOK [xgrid 0.48]
|
|
} |