1.@import

bolt another stylesheet onto your existing one.

@import url(**.css);

must be placed at the top of a stylesheet, before any other rules.

2.@media

screen, print, projection, handheld, and all, or a comma-separated list of more than one,variables relating to that media

eg:@media screen,projection

3.@font-face

eg1:@font-face{

font-family:"font of all knowledge";

src:url(fontofallknowledge.woff");

}

create a font named “font of all knowledge” using the font-family descriptor and links the font file “fontofallknowledge.woff” to that name using the src descriptor. “font of all knowledge” can then be used in a standard font rule

The font will be downloaded (in this case from the same directory as the CSS file) and applied to paragraphs

eg2:Checking to see if a font is already present on a user’s computer,removing the need to download it,specify which one you’re interested in.

Could use Google Web Fonts


@font-face {
font-family: "font of all knowledge";
src: local("font of all knowledge"), local(fontofallknowledge), url(fontofallknowledge.woff);
font-weight: 400;
font-style: normal;
}


【CSS3】Advanced5:At Rules:@import, @media, and @font-face的更多相关文章

  1. 【CSS3】Advanced3:Universal, Child, and Adjacent Selectors

    1.Universal selectors eg:#target*{ } 2.Child selectors < something immediately nested within some ...

  2. 【HTML】Advanced5:Accessible Forms

    1.label <form> <label for="yourName">Your Name</label> <input name=&q ...

  3. 【CSS3】Advanced11:Media Queries

    1.Browser-size specific CSS @media screen and (max/min-width:1000px){} 2.Orientation-specific CSS? @ ...

  4. 【CSS3】Advanced10:Gradient

    1.background:linear-gradient(20deg/(to) bottom right,orange,red,hsl(60,100%,50%)); 2.-webkit-chrome/ ...

  5. 【CSS3】Advanced9:Transformation

    1.transform:rotate(-10deg) skew(20deg,10deg) scaling(2/1,2) translate/移动(100px,200px) 2.transform:ma ...

  6. 【CSS3】Advanced8:CSS Backgrounds: Multiples, Size, and Origin

    1.Multiples,Size,and Origin eg:background-image:url(bg.png),url(bullet.png) 0 50% no-repeat,url(arro ...

  7. 【CSS3】Advanced7:CSS Transitions

    1.animate parts of your design without the need for the likes of JavaScrip 2.allowing smooth animati ...

  8. 【CSS3】Advanced6:Attribute Selectors

    1.with the attribute abbr[title]{color:red} 2.with the attribute and it's value input[type=text][dis ...

  9. 【CSS3】Advanced4:Advanced Colors

    1.rgba(red,green,blue,alpha(不透明度0.0(完全透明)与 1.0(完全不透明)) 2.HSLa(hue(色调 0red 120green 240blue),saturati ...

随机推荐

  1. 面试题(C#算法编程题)

    1>用C#写一段选择排序算法,要求用自己的编程风格.答:private int min;    public void xuanZhe(int[] list)//选择排序    {        ...

  2. 自定义弹出div对话框

    <style type="text/css"> html,body{height:100%;overflow:hidden;} body,div,h2{margin:0 ...

  3. rm排除指定文件或指定文件夹下文件

    3.方法3,当前文件夹中结合使用grep和xargs来处理文件名: ls | grep -v keep | xargs rm #删除keep文件之外的所有文件 说明: ls先得到当前的所有文件和文件夹 ...

  4. php中的preg系列函数

    mixed preg_replace ( mixed $pattern , mixed $replacement , mixed $subject [, int $limit = -1 [, int ...

  5. 【Ubuntu12.04】安装搜狗输入法

    我的系统版本是Ubuntu12.04 32位 卸载Ibus输入法 sudo apt-get remove ibus 注意: 安装ibus的命令是  sudo apt-get install fcitx ...

  6. MVC-登录并设置角色

    1.新建一个类,设置角色: using System; using System.Collections.Generic; using System.Linq; using System.Text; ...

  7. HTTP - PUT 上传文件/Shell (二)

    上一篇文章 HTTP - PUT 上传文件/Shell 讲到自己搭了一个环境,去测试HTTP - PUT上传Shell.最近又遇到几个PUT上传的例子,也成功上传了几次,来分享一下思密达. 0x00 ...

  8. cocos2dx伸缩式列表效果

    效果: 代码: ElasticListView.h #pragma once //std #include <string> #include <map> //cocos #i ...

  9. mvc3.0中[ValidateInput(false)]失效的问题

    在asp.net mvc3.0中[ValidateInput(false)]特性失效了,只需要在网站根目录中的web.config中做如下配置即可: <system.web> <ht ...

  10. asp.net中下载功能

    //流方式下载 protected void ButtonButtonDownload_Click(object sender, EventArgs e) { //string fileName = ...