我希望了解字体的粗细度,以便从Google Fonts请求特定的字体粗细。
我已在Ubuntu 16上安装了所有Google字体(全部为TrueType格式),如果我执行以下操作:
fc-list : family : weight
然后我得到了这样的结果:
Nunito,Nunito Black:weight=210
Nunito,Nunito ExtraBold:weight=205
Nunito,Nunito ExtraLight:weight=48
Nunito,Nunito Light:weight=50
Nunito,Nunito SemiBold:weight=180
Nunito Sans,Nunito Sans Black:weight=210
Nunito Sans,Nunito Sans ExtraBold:weight=205
Nunito Sans,Nunito Sans ExtraLight:weight=48
Nunito Sans,Nunito Sans Light:weight=50
Nunito Sans,Nunito Sans SemiBold:weight=180
Nunito Sans:weight=200
Nunito Sans:weight=80
Nunito:weight=200
Nunito:weight=80
OdorMeanChey:weight=80
Offside:weight=80
OFL Sorts Mill Goudy TT:weight=100
Oldenburg:weight=80
Old Standard TT:weight=200
Old Standard TT:weight=80
Oleo Script Swash Caps:weight=200
Oleo Script Swash Caps:weight=80
Oleo Script:weight=200
Oleo Script:weight=80
Open Sans Condensed,Open Sans Condensed Light:weight=50
Open Sans Condensed:weight=200
Open Sans Hebrew Condensed,Open Sans Hebrew Condensed Extra Bold:weight=205
Open Sans Hebrew Condensed,Open Sans Hebrew Condensed Light:weight=50
Open Sans Hebrew Condensed:weight=200
Open Sans Hebrew Condensed:weight=80
Open Sans Hebrew,Open Sans Hebrew Extra Bold:weight=205
Open Sans Hebrew,Open Sans Hebrew Light:weight=50
Open Sans Hebrew:weight=200
Open Sans Hebrew:weight=80
Open Sans,Open Sans ExtraBold:weight=205
Open Sans,Open Sans Light:weight=50
Open Sans,Open Sans SemiBold:weight=180
Open Sans:weight=200
Open Sans:weight=80
Oranienbaum:weight=80
Orbitron,Orbitron Black:weight=210
Orbitron,Orbitron Medium:weight=100
Orbitron:weight=200
Orbitron:weight=80
Oregano:weight=80
Orienta:weight=80
Original Surfer:weight=80
Oswald,Oswald ExtraLight:weight=48
Oswald,Oswald Light:weight=50
Oswald,Oswald Medium:weight=100
Oswald,Oswald SemiBold:weight=180
在许多情况下,似乎默认的字重是80(我原以为默认值应该是400 normal),而其他字重则千差万别。
我曾期望fc-list报告的字重与此页面上的“常用字重名称映射”相对应:https://developer.mozilla.org/en-US/docs/Web/CSS/font-weight,但显然它们并不一致。
Value Common weight name
100 Thin (Hairline)
200 Extra Light (Ultra Light)
300 Light
400 Normal
500 Medium
600 Semi Bold (Demi Bold)
700 Bold
800 Extra Bold (Ultra Bold)
900 Black (Heavy)
我的第一个问题是,为什么报告的字体粗细与上面的映射表不对应?
第二个问题是,既然它们不匹配,而且我的TrueType字体直接来自Google Fonts,如果我想从Google Fonts请求字体,我应该指定哪种字体粗细 - 来自上面的映射表还是来自fc-list报告的字体粗细?