html引入思源黑體 通過Link標簽在網頁頭部引用Google Web Font: <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Noto+Sans+SC:100,300,400,500,700,900"> ...
html引入思源黑體
通過Link標簽在網頁頭部引用Google Web Font:
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Noto+Sans+SC:100,300,400,500,700,900">
- 字體:Noto Sans SC
- 大小:100, 300, 400, 500, 700, 900
在需要使用思源黑體的地方設置CSS樣式:
font-family: "Noto Sans SC";
font-weight: 100;
TIP:Link標簽的rel屬性的全稱是relationship,表示引用內容與當前HTML的關係。
Regular、Normal、Medium、Light 對應的font-weight值
字體粗細:‘font-weight’屬性
名稱: font-weight
取值: normal | bold | bolder | lighter | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900
初始: normal
100 - Thin
200 - Extra Light (Ultra Light)
300 - Light
400 - Regular (Normal、Book、Roman)
500 - Medium
600 - Semi Bold (Demi Bold)
700 - Bold
800 - Extra Bold (Ultra Bold)
900 - Black (Heavy)
normal、regular與'400'相同。
bold與'700'相同。
bolder指定外觀的重量大於繼承的值。
lighter 指定外觀的重量小於繼承的值。
詳見W3C Fonts節章的規範標準