首页 > 解决方案 > 获取分为 unicode 范围的 json 格式的 google 字体列表

问题描述

我使用https://developers.google.com/fonts/docs/developer_api获取 google 字体列表。

格式是这样的

{
 "kind": "webfonts#webfontList",
 "items": [



[...]


{
   "kind": "webfonts#webfont",
   "family": "Anonymous Pro",
   "variants": [
    "regular",
    "italic",
    "700",
    "700italic"
   ],
   "subsets": [
    "greek",
    "greek-ext",
    "cyrillic-ext",
    "latin-ext",
    "latin",
    "cyrillic"
   ],
   "version": "v3",
   "lastModified": "2012-07-25",
   "files": {
    "regular": "http://themes.googleusercontent.com/static/fonts/anonymouspro/v3/Zhfjj_gat3waL4JSju74E-V_5zh5b-_HiooIRUBwn1A.ttf",
    "italic": "http://themes.googleusercontent.com/static/fonts/anonymouspro/v3/q0u6LFHwttnT_69euiDbWKwIsuKDCXG0NQm7BvAgx-c.ttf",
    "700": "http://themes.googleusercontent.com/static/fonts/anonymouspro/v3/WDf5lZYgdmmKhO8E1AQud--Cz_5MeePnXDAcLNWyBME.ttf",
    "700italic": "http://themes.googleusercontent.com/static/fonts/anonymouspro/v3/_fVr_XGln-cetWSUc-JpfA1LL9bfs7wyIp6F8OC9RxA.ttf"
   }
  },
  {
   "kind": "webfonts#webfont",
   "family": "Antic",

在 github 存储库 https://github.com/asadkn 我发现了一个列表,其中包含 google 字体分为 unicode 范围: https ://raw.githubusercontent.com/asadkn/selfhost-google-fonts/master/inc/data/google -fonts-src.json

谷歌也提供这种格式吗?还有其他方法可以下载这种格式的数据吗?

标签: unicodegoogle-font-apigoogle-fonts

解决方案


推荐阅读