Add options for increasing width.
This commit is contained in:
parent
8658cdc23b
commit
74c3cdf62b
|
@ -5,7 +5,7 @@ codename = 'Calibum'
|
|||
copyright = 'Copyright (c) 2015 Belleve Invis.'
|
||||
licence = '''This font software is licenced under the SIL Open Font Licence, Version 1.1. This is licence is avaliable with a FAQ at: http://scripts.sil.org/OFL. This font software is distributes on an 'AS IS' basis, without warranties or conditions of any kind, either express or implied. See the SIL Open Font licence fot the specific language, premissions and limitations governing your use of this font software.'''
|
||||
|
||||
width = 500
|
||||
width = 500 # Increase this if you think that Iosevka is too narrow
|
||||
cap = 735
|
||||
xheight = 530
|
||||
#descender = -205 # Unnecessary
|
||||
|
|
|
@ -40,7 +40,11 @@ function writettf(ttf, file){
|
|||
|
||||
var ttf = readttf(process.argv[2]);
|
||||
// Fixes xAvgCharWidth
|
||||
ttf['OS/2'].xAvgCharWidth = ttf.head.unitsPerEm / 2; // 0.5em
|
||||
var spacewidth = ttf.head.unitsPerEm / 2;
|
||||
for(var j = 0; j < ttf.glyf.length; j++) if(ttf.glyf[j] && ttf.glyf[j].unicode && ttf.glyf[j].unicode[0] === 0x20) {
|
||||
spacewidth = ttf.glyf[j].advanceWidth
|
||||
}
|
||||
ttf['OS/2'].xAvgCharWidth = spacewidth; // 0.5em
|
||||
ttf['OS/2'].sxHeight = param.iosevka.xheight
|
||||
ttf['OS/2'].sCapHeight = param.iosevka.cap
|
||||
ttf['OS/2'].fsSelection |= (ttf['OS/2'].usWeightClass > 400 ? 1 << 5 : 0) | (ttf.post.italicAngle ? 1 : 0)
|
||||
|
|
Loading…
Reference in New Issue
Block a user