@font-face
/*font-face 格式
@font-face{
font-family:SingleMaltaRegular;
src: <source> [<format>][,<source> [<format>]]*;
font-weight: normal;
font-style: normal;
}
*取值说明:
*YourWebFontName:此值指的就是你自定义的字体名称,最好是使用你下载的默认字体,他将被引用到你的Web元素中的font-family。如“font-family:"YourWebFontName";”
*source:此值指的是你自定义的字体的存放路径,可以是相对路径也可以是绝路径;
*format:此值指的是你自定义的字体的格式,主要用来帮助浏览器识别,其值主要有以下几种类型:truetype,opentype,truetype-aat,embedded-opentype,avg等;
*weight和style:这两个值大家一定很熟悉,weight定义字体是否为粗体,style主要定义字体样式,如斜体。
*页面调用方法:
第一种方法:<i class="icon-index-max" aria-hidden="true" data-icon=""></i>
第二种方法:<i class="icon-podcast icon-index-max"></i>
*/
@font-face {
font-family: 'icomoon';
src: url('../fontface/icomoon.eot');/* IE9 Compat Modes */
src: url('../fontface/icomoon.eot?#iefix') format('embedded-opentype'),/* IE6-IE8 */
url('../fontface/icomoon.woff') format('woff'),/* Modern Browsers */
url('../fontface/icomoon.ttf') format('truetype'),/* Safari, Android, iOS */
url('../fontface/icomoon.dev.svg#icomoon') format('svg');/* Legacy iOS */
font-weight: normal;
font-style: normal;
}
/* Use the following CSS code if you want to use data attributes for inserting your icons */
[data-icon]:before {
font-family: 'icomoon';
content: attr(data-icon);
speak: none;
font-weight: normal;
font-variant: normal;
text-transform: none;
font-style: normal;
line-height: 1;
-webkit-font-smoothing: antialiased;
}
/*
*font-family:设置文本的字体名称
*font-style:设置文本样式
*font-variant:设置文本是否大小写。设置文本是否大小写,设置小型大写字母的字体显示文本,这意味着所有的小写字母均会被转换为大写,但是所有使用小型大写字体的字母与其余文本相比,其字体尺寸更小
*text-transform:属性控制文本的大小写
*font-weight:设置文本的粗细
*font-stretch:设置文本是否横向的拉伸变形
*font-size:设置文本字体大小
*src:设置自定义字体的相对路径或者绝对路径,注意,此属性只能在@font-face规则里使用
*-webkit-font-smoothing: 设置字体的抗锯齿或者说光滑度的属性
*/
/* Use the following CSS code if you want to have a class per icon */
/*
Instead of a list of all class selectors,
you can use the generic selector below, but it's slower:
[class*="icon-"] {
*/
.icon-home, .icon-office, .icon-pencil, .icon-pencil-2, .icon-connection, .icon-bullhorn, .icon-newspaper, .icon-images, .icon-camera, .icon-file, .icon-profile, .icon-file-2, .icon-library, .icon-books, .icon-book, .icon-feed, .icon-podcast, .icon-pacman, .icon-folder, .icon-folder-open, .icon-tags, .icon-qrcode, .icon-cart, .icon-cart-2, .icon-credit, .icon-coin, .icon-support, .icon-calendar, .icon-calendar-2, .icon-alarm, .icon-alarm-2, .icon-map, .icon-map-2, .icon-location, .icon-location-2, .icon-pushpin, .icon-envelop, .icon-notebook, .icon-address-book, .icon-phone-hang-up, .icon-phone, .icon-print, .icon-keyboard, .icon-screen, .icon-laptop, .icon-mobile, .icon-mobile-2, .icon-tablet, .icon-tv, .icon-box-add, .icon-box-remove, .icon-disk, .icon-users, .icon-bubbles, .icon-bubbles-2, .icon-bubbles-3, .icon-reply, .icon-forward, .icon-redo, .icon-undo, .icon-spinner, .icon-binoculars, .icon-zoom-in, .icon-expand, .icon-contract, .icon-expand-2, .icon-contract-2, .icon-key, .icon-lock, .icon-unlocked, .icon-food, .icon-glass, .icon-gift, .icon-bars, .icon-stats, .icon-cog, .icon-cogs, .icon-cog-2, .icon-equalizer, .icon-settings, .icon-fire, .icon-remove, .icon-remove-2, .icon-briefcase, .icon-airplane, .icon-truck, .icon-road, .icon-accessibility, .icon-power-cord, .icon-eye-blocked, .icon-eye, .icon-attachment, .icon-flag, .icon-lightning, .icon-link, .icon-globe, .icon-upload, .icon-download, .icon-cloud-upload, .icon-cloud-download, .icon-cloud, .icon-eye-2, .icon-bookmarks, .icon-bookmark, .icon-star, .icon-star-2, .icon-star-3, .icon-heart, .icon-heart-2, .icon-heart-broken, .icon-thumbs-up, .icon-thumbs-up-2, .icon-forward-2, .icon-backward {
font-family: 'icomoon';
speak: none;
font-style: normal;
font-weight: normal;
font-variant: normal;
text-transform: none;
line-height: 1;
font-style: normal;
-webkit-font-smoothing: antialiased;
}
.icon-home:before {
content: "\e000";
}
.icon-office:before {
content: "\e001";
}
.icon-pencil:before {
content: "\e002";
}
.icon-pencil-2:before {
content: "\e003";
}
.icon-connection:before {
content: "\e004";
}
.icon-bullhorn:before {
content: "\e005";
}
.icon-newspaper:before {
content: "\e006";
}
.icon-images:before {
content: "\e007";
}
.icon-camera:before {
content: "\e008";
}
.icon-file:before {
content: "\e009";
}
.icon-profile:before {
content: "\e00a";
}
.icon-file-2:before {
content: "\e00b";
}
.icon-library:before {
content: "\e00c";
}
.icon-books:before {
content: "\e00d";
}
.icon-book:before {
content: "\e00e";
}
.icon-feed:before {
content: "\e00f";
}
.icon-podcast:before {
content: "\e010";
}
.icon-pacman:before {
content: "\e013";
}
.icon-folder:before {
content: "\e011";
}
.icon-folder-open:before {
content: "\e012";
}
.icon-tags:before {
content: "\e014";
}
.icon-qrcode:before {
content: "\e015";
}
.icon-cart:before {
content: "\e016";
}
.icon-cart-2:before {
content: "\e017";
}
.icon-credit:before {
content: "\e018";
}
.icon-coin:before {
content: "\e019";
}
.icon-support:before {
content: "\e01a";
}
.icon-calendar:before {
content: "\e01b";
}
.icon-calendar-2:before {
content: "\e01c";
}
.icon-alarm:before {
content: "\e01d";
}
.icon-alarm-2:before {
content: "\e01e";
}
.icon-map:before {
content: "\e01f";
}
.icon-map-2:before {
content: "\e020";
}
.icon-location:before {
content: "\e021";
}
.icon-location-2:before {
content: "\e022";
}
.icon-pushpin:before {
content: "\e023";
}
.icon-envelop:before {
content: "\e024";
}
.icon-notebook:before {
content: "\e025";
}
.icon-address-book:before {
content: "\e026";
}
.icon-phone-hang-up:before {
content: "\e027";
}
.icon-phone:before {
content: "\e028";
}
.icon-print:before {
content: "\e029";
}
.icon-keyboard:before {
content: "\e02a";
}
.icon-screen:before {
content: "\e02b";
}
.icon-laptop:before {
content: "\e02c";
}
.icon-mobile:before {
content: "\e02d";
}
.icon-mobile-2:before {
content: "\e02e";
}
.icon-tablet:before {
content: "\e02f";
}
.icon-tv:before {
content: "\e030";
}
.icon-box-add:before {
content: "\e031";
}
.icon-box-remove:before {
content: "\e032";
}
.icon-disk:before {
content: "\e033";
}
.icon-users:before {
content: "\e034";
}
.icon-bubbles:before {
content: "\e035";
}
.icon-bubbles-2:before {
content: "\e036";
}
.icon-bubbles-3:before {
content: "\e037";
}
.icon-reply:before {
content: "\e038";
}
.icon-forward:before {
content: "\e039";
}
.icon-redo:before {
content: "\e03a";
}
.icon-undo:before {
content: "\e03b";
}
.icon-spinner:before {
content: "\e03c";
}
.icon-binoculars:before {
content: "\e03d";
}
.icon-zoom-in:before {
content: "\e03e";
}
.icon-expand:before {
content: "\e03f";
}
.icon-contract:before {
content: "\e040";
}
.icon-expand-2:before {
content: "\e041";
}
.icon-contract-2:before {
content: "\e042";
}
.icon-key:before {
content: "\e043";
}
.icon-lock:before {
content: "\e044";
}
.icon-unlocked:before {
content: "\e045";
}
.icon-food:before {
content: "\e046";
}
.icon-glass:before {
content: "\e047";
}
.icon-gift:before {
content: "\e048";
}
.icon-bars:before {
content: "\e049";
}
.icon-stats:before {
content: "\e04a";
}
.icon-cog:before {
content: "\e04b";
}
.icon-cogs:before {
content: "\e04c";
}
.icon-cog-2:before {
content: "\e04d";
}
.icon-equalizer:before {
content: "\e04e";
}
.icon-settings:before {
content: "\e04f";
}
.icon-fire:before {
content: "\e050";
}
.icon-remove:before {
content: "\e051";
}
.icon-remove-2:before {
content: "\e052";
}
.icon-briefcase:before {
content: "\e053";
}
.icon-airplane:before {
content: "\e054";
}
.icon-truck:before {
content: "\e055";
}
.icon-road:before {
content: "\e056";
}
.icon-accessibility:before {
content: "\e057";
}
.icon-power-cord:before {
content: "\e058";
}
.icon-eye-blocked:before {
content: "\e059";
}
.icon-eye:before {
content: "\e05a";
}
.icon-attachment:before {
content: "\e05b";
}
.icon-flag:before {
content: "\e05c";
}
.icon-lightning:before {
content: "\e05d";
}
.icon-link:before {
content: "\e05e";
}
.icon-globe:before {
content: "\e05f";
}
.icon-upload:before {
content: "\e060";
}
.icon-download:before {
content: "\e061";
}
.icon-cloud-upload:before {
content: "\e062";
}
.icon-cloud-download:before {
content: "\e063";
}
.icon-cloud:before {
content: "\e064";
}
.icon-eye-2:before {
content: "\e065";
}
.icon-bookmarks:before {
content: "\e066";
}
.icon-bookmark:before {
content: "\e067";
}
.icon-star:before {
content: "\e068";
}
.icon-star-2:before {
content: "\e069";
}
.icon-star-3:before {
content: "\e06a";
}
.icon-heart:before {
content: "\e06b";
}
.icon-heart-2:before {
content: "\e06c";
}
.icon-heart-broken:before {
content: "\e06d";
}
.icon-thumbs-up:before {
content: "\e06e";
}
.icon-thumbs-up-2:before {
content: "\e06f";
}
.icon-forward-2:before {
content: "\e070";
}
.icon-backward:before {
content: "\e071";
}
@font-face的更多相关文章
- CSS3与页面布局学习总结(五)——Web Font与Sprite
一.web font web font是应用在web中的一种字体技术,在CSS中使用font-face定义新的字体.先了解操作系统中的字体: a).安装好操作系统后,会默认安装一些字体,这些字体文件描 ...
- 把UI图里的小图标制作成icon font
一个交互比较多的UI图里面可能会有很多小图标,一般可用sprites图将多个小图标弄成一张大图,或者其它的办法,各种方法的比较可参见博主的另外一篇博客使用css3新属性clip-path制作小图标,本 ...
- [函数] Firemonkey Windows 重新计算 Font Baseline
计算字型 Baseline 是一个不常用的函数,但如果想要显示不同大小文字下方对齐,就得用它来计算字型的 Baseline 才行,如果计算不准,显示的文字就会高高低低不整齐. 在 Firemonkey ...
- Html中<font>标签的使用
Html中<font>标签的使用 <!doctype html> <html lang="en"> <head> <meta ...
- 关于firefox对font awesome本地环境无法加载问题
问题描述 昨天尝试使用font awesome加载字体图标,直接在本地引入相关文件,测试发现图标在chrome和IE环境支持,但是在firefox上怎么都显示不出来. 解决方法 通过测试发现通过htt ...
- CSS3使用Font Awesome字体图标的控件样例(按钮,工具栏,输入框)
按钮上加入font awesome图标,用原生的input button标签无法实现,查看网上的只能通过<a><li></li></a>实现此功能,通过 ...
- CSS 中Font Awesome 图标(附码表)
HTML中缩放的矢量图标,您可以使用CSS所提供的所有特性对它们进行更改,包括:大小.颜色.阴影或者其它任何支持的效果. Font Awesome 传送门:http://fontawesome.das ...
- Font Squirrel
Font Squirrel FontSquirrel:国外免费字体下载网是一个提供高质量商业字体下载网站,提供海量的英文字体库,用户可以随意下载并应用于各种商业用字,无需考虑其版权问题. 官网地址:h ...
- <web Font的使用>
使用font-face将字体引入web中 先将字体文件复制到项目的font文件夹中,CSS样式如下: @font-face { font-family: 'iconfont'; /*字体名称*/ sr ...
- java 引入自定义字体font后出现的硬盘吃光的问题
有个需求要用美术字体在图片上写字 用自定义的文字有两个方法: 1. Font dynamicFont = Font.createFont(Font.TRUETYPE_FONT, InputStream ...
随机推荐
- javascript函数的4种调用方式
在javascript中一共有4种函数调用模式,分别是:方法调用模式.函数调用模式.构造函数调用模式和apply(call)调用模式,这4种模式的主要差异在于如何初始化关键参数this. 方法调用模式 ...
- hdoj 5522 Numbers
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=5522 水题:暴力过 #include<stdio.h> #include<strin ...
- 用Quartus II 建立一个工程模板,以后新建工程时无需再配置参数
以前用Quartus II 每次新建工程时,都要设置工程名,选择工程路径,选择芯片型号等等,好麻烦呀!可不可以建一个工程模板,以后新建工程时直接改相应文件名就可以呀!后来我一琢磨,感觉也不是不可以.因 ...
- visual studio 2015提示IE10未安装
将以下代码写入文本: @ECHO OFF :IE10HACK REG ADD "HKLM\SOFTWARE\Wow6432Node\Microsoft\Internet Explorer&q ...
- 理解C# Attribute
1.Attribute与Property Attribute是特性,Property是属性. 2.Attribute与注释 注释:是给程序员看的,编译的时候会去掉这些信息,也就是说,程序集中没有注释的 ...
- iOS开发中WebP格式的64位支持处理
几个月前我们项目中添加了对webp格式的处理.期间遇到了一些问题,这是当中的一个小的记录. 官方下载地址:https://code.google.com/p/webp/downloads/list 对 ...
- dubbo使用方法
dubbo使用方法. Dubbo采用全Spring配置方式,透明化接入应用,对应用没有任何API侵入,只需用Spring加载Dubbo的配置即可,Dubbo基于Spring的Schema扩展进行加载. ...
- perl 线程创健
http://www.cnblogs.com/zhangchaoyang/articles/2057178.html
- Java基础知识强化之集合框架笔记68:Collections类概述和成员方法(备注:Collection 和 Collections区别)
1. Collections类概述: 针对集合操作的工具类,都是静态方法. 2. Collection 和 Collections的区别: Collections是个java.util下的类,它包含 ...
- C++ notes for beginners(2)
作者:马 岩(Furzoom) (http://www.cnblogs.com/furzoom/)版权声明:本文的版权归作者与博客园共同所有.转载时请在明显地方注明本文的详细链接,未经作者同意请不要删 ...