1. Introduction@font-face is used to customize font styles, to obtain a font style from the server side, so that the browser can display a style effect that the client does not exist, giving the user a better presentation experience. @font-face is not a new feature of CSS3, as early as 98 was written in the CSS2 specification, which is currently supported in IE6.2. Syntax @font-Face{ font-family: // Custom font names SRC: // font file path [Font-weight: // whether or not to add bold
Using Google-hosted JavaScript libraries in projects
Author: chszs, reprinted with note.Author blog homepage: http://blog.csdn.net/chszs
Google provides many open-source JavaScript libraries, including jquery, dojo, mootools, prototype, swfobject, webfont loader, script. aculo. Us, jquery UI, and angularjs.
To use the libraries provided by Google, simply use label.
The libraries provided by Google are stable, reliable, fast, and glob
, and the transparency effect cannot be achieved with CSS.4, If the page has more small icon, first consider the use of Webfont, if the Webfont can not meet the requirements, you must use CSS sprite to merge the picture, to compress the overall picture size, while reducing the page request to improve access speed. In addition to the PNG image compression, in addition to adjust the maximum index color, this
code in the resources option in Chrome's console, it is recommended to use Chrome's "pretty print" feature, which is to click on the "{}" icon.WhatfontTo see which fonts are used for the current page, Firebug and WebKit Inspector can also view the fonts, but far from being webfont convenient, webfont can view the fonts by hovering over the elements. It also supports viewing network fonts, such as Typekit a
which kind of use.After the conversion, you can write the CSS code:@font-face { font-family: ' Hooray '; /* Name the custom font * /src:url (' Hooray.eot '); Src:url (' Hooray.eot #iefix ') format (' EoT '), url (' Hooray.woff '), Format (' Woff '), url (' hooray.ttf ') format (' TrueType '), url (' hooray.svg#webfontjkg17vre ') format (' SVG ');}As for the call, as usual, define font-family where needed, and the name of the font is just the name just right: fo
One";Src:url ("Http://xxxxxxxxxx/xxx.woff"),Src:url ("Http://xxxxxxxxxx/xxx.ttf");}H1 {Font-family: "Emblema one", Sans-serif;}Fontsquirrel provides web font hosting services;The Font-size property controls the font size by using pixel px, percent% (relative to parent element), EM (relative to parent element), keyword Four ways to specify font size, for example:Body {FONT-SIZE:14PX (150%, 1.2em, small)}keywords, mainly using small and medimu, you can
font, there are two ways: one is to find the paid website to buy the font, and the other is to download the font to the free website. Of course, I don't think everyone will do this kind of silly thing, so we will get a free download. Where can we find it? I usually go to Google Web Fonts and dafont.com to find the fonts I need. Of course, there are other places to download the fonts on the Internet. This demo uses the single Malta font of dafont.com, in this way, you can download single Malta h
Firefox 3.5, Safari, and opera
. EOT, applicable to Internet Explorer 4.0 +
. SVG, applicable to chrome and iPhone
The following describes how to obtain the three types of files in a certain font. Generally, some type of file with the font on hand (or found on the design resource site) is the most common. TTF file, we need to convert this file format to the other two file formats. You can use the online font conversion service provided by fontsq
do, then we will get free places to download, where there? I usually go to Google Web fonts and dafont.com to find their own fonts, of course, there are other places on the Internet to download fonts, this demo uses the dafont.com single Malta font, so you can download a single Malta:Once the single Malta is downloaded, it needs to be decompressed:Second, get the font format required for @font-face:The special font is already in your computer, and now we need to find a way to get the @font-face
font:To get a single Malta font, there are two ways, one to find paid websites to buy fonts, the other is to the free site download fonts. Of course to give money this stupid I think we will not do, then we will get free places to download, where there? I usually go to Google Web fonts and dafont.com to find their own fonts, of course, there are other places on the Internet to download fonts, this demo uses the dafont.com single Malta font, so you can download a single Malta:Once the single Mal
to give money this stupid I think we will not do, then we will get free places to download, where there? I usually go to Google Web fonts and dafont.com to find their own fonts, of course, there are other places on the Internet to download fonts, this demo uses the dafont.com single Malta font, so you can download a single Malta:Once the single Malta is downloaded, it needs to be decompressed:Second, get the font format required for @font-face:The special font is already in your computer, and n
Fontsquirrel or Onlinefontconverter.
. TTF or. OTF for Firefox 3.5, Safari, Opera
. EOT for Internet Explorer 4.0+
. SVG for Chrome, IPhone
3. use @font-face to define the font. if you are converting fonts in fontsquirrel.com, then even the steps to define a font are free. After conversion he will provide a download package that contains the required font format and a CSS file stylesheet.css that defines the font style, as well
MODERNIZR: Detection of the browser to HTML5 and CSS3 features support JS Library, elegant downgrade is the choice
Code Generation Tools:
Css3please: Auto-populate browser prefixes and test CSS3 effects online
CSS Gradient Generator: Quickly create gradients
Free fonts: Fontsquirrel: Lots of English fonts that can be downloaded for free
CSS3 Tutorials/Documentation: CSS3 Info, Foreign forum, article updated slo
), most commonly. TTF file, We need to convert this file format to the remaining two file Formats. The conversion of font file format can be obtained through the online font conversion service provided by the website Fontsquirrel or onlinefontconverter. The first site is recommended Here.About getting special fonts:2 recommended sites: Google Web fonts and Dafont.com. Of course you can also choose Other.For font conversion , click here to set the main
the dafont.com single Malta font, so you can download a single Malta:Once the single Malta is downloaded, it needs to be decompressed:Second, get the font format required for @font-face:The special font is already in your computer, and now we need to find a way to get the @font-face. Eot,.woff,.ttf,.svg font format. To get these font formats, we also need third-party tools or software to implement, below I recommend a tool I commonly used fontsquirrel
complete example of the full:First, get special fonts:Let's take this single Malta font:To get a single Malta font, there are two ways, one to find paid websites to buy fonts, the other is to the free site download fonts. Of course to give money this stupid I think we will not do, then we will get free places to download, where there? I usually go to Google Web fonts and dafont.com to find their own fonts, of course, there are other places on the Internet to download fonts, this demo uses the d
of the new functionality, but again, its flaws come from the cloud, Css3ps needs to connect to the Internet, because everything needs to be generated and then exported on the server.
Composer
Applicable version: CS5, CS6, CC
This plugin, called composer, allows you to perform the same operation on several different layers at the same time, freeing the designer from the dreaded tedious work. Although it has a limited number of operands, it will overwrite any changes you make.
Reprint http://www.cnblogs.com/Kummy/p/4442142.html?? If you want to display a special Chinese font in a Web page when you don't know this way before, Need to import the entire. TTF font file, and the file up to several megabytes, is not advisable at all, by chance to see the above linked articles, new ideas new method, the Web page needs to use special fonts in Chinese text, packaging compression.1. Installing Font-spidernpm install font-spider -g2. Using W
How do I introduce an external font?1. Get Related DocumentsMost of the font packages we download on our web site are files that end in TTF, but we typically need four of files for our front-end development.The font suffix is related to the browser, as shown below
. TTF or. OTF for Firefox 3.5, Safari, Opera
. EOT, for Internet Explorer 4.0+
. SVG, for Chrome, IPhoneSo how do we get these four kinds of documents? This is a recommended online font conversion software, with the followi
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.