languageexpand_more
English Deutsch Español Français Русский язык Italiano 한어 简体中文 繁體中文 日本語

离线使用Google Material Icons

引用:https://stackoverflow.com/questions/37270835/how-to-host-material-icons-offline

1. 前往https://github.com/google/material-design-icons/releases下载最新的Releases包。

2. 解压后,将font文件夹整个上传到你的站点根目录。

3. 添加网站对字体格式的支持,在.htaccess文件里加入以下代码:

<FilesMatch ".(eot|ttf|otf|woff|woff2)">
Header set Access-Control-Allow-Origin "*"
</FilesMatch>

4. 创建一个css文件,来定义字体,(最新版本里只有ttf和otf两种格式):

文件结构

@font-face {
font-family: 'Material Icons';
font-style: normal;
font-weight: 400;
src: url(iconfont/MaterialIcons-Regular.eot); /* For IE6-8 */
src: local('Material Icons'),
local('MaterialIcons-Regular'),
url(iconfont/MaterialIcons-Regular.woff2) format('woff2'),
url(iconfont/MaterialIcons-Regular.woff) format('woff'),
url(iconfont/MaterialIcons-Regular.ttf) format('truetype');
}

.material-icons {
font-family: 'Material Icons';
font-weight: normal;
font-style: normal;
font-size: 24px; /* Preferred icon size */
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;

/* Support for all WebKit browsers. */
-webkit-font-smoothing: antialiased;
/* Support for Safari and Chrome. */
text-rendering: optimizeLegibility;

/* Support for Firefox. */
-moz-osx-font-smoothing: grayscale;

/* Support for IE. */
font-feature-settings: 'liga';
}

5. 最后在HTML里调用图标
<span class="material-icons">face</span>
显示效果:


face

手机安装和更新Google服务

本文最后更新于1年前(2017-2-15 17:03:21),链接可能失效,内容可能难以复现。请注意甄别。

© Sunplace,2017

如今的国产机哪个还有Google服务这种东西?

方法一(推荐,需要ROOT)

1.安装第三方recovery。

2.在https://opengapps.org/中选择并下载相应的刷机包。(可以用CPU-Z查看CPU类型)

3.卡刷后即可使用。

方法二(需要ROOT)

1.安装GO谷歌安装器

2.直接运行安装Google服务。

3.如果弹出Google Play停止运行,请下载谷歌服务FC修复工具

不要在第三方应用商店安装或更新Google Play服务。

更新Google Play Service

1.架好梯子

2.查看已经安装的Google Play Service(Google Play服务)的应用信息。

上图的版本号为12.8.72(040408-202717283),只需要记下040408(旧版本通常只有三位,如448)。

3.(需要梯子)访问APKMirror,找到Google PLay Service的下载页(如果你不是在更新TV版本或者可穿戴设备,可以访问这里)。

点击ALL VARIANTS

点击相应的版本号

最上的版本最新,点击右边的下载图标

点击DOWNLOAD APK

4.安装到手机即可