CSS Learning Notes

Source: Internet
Author: User

1, the HTML and CSS color specification defines 147 color names (17 standard colors plus 130 other colors).
Http://www.w3school.com.cn/cssref/css_colornames.asp (these colors are listed in link)

2, the size of the CSS (Http://www.baidu.com/s?wd=%E8%8B%B1%E5%AF%B8 can check):
Unit description
Percent%
in inch
CM cm
mm mm
Em
1em equals the current font size.
2em equals twice times the current font size.
For example, if an element is displayed in 12pt, then 2EM is 24pt.
In CSS, EM is a very useful unit because it automatically adapts to the font that the user uses.
Ex An ex is a font of x-height. (X-height is usually half the size of the font.) )
PT lb (1 pt equals 1/72 inch)
PC 12-point movable (1 pc equals 12 points)
px Pixels (a point on the computer screen)

3, CSS inside the attributes (http://www.w3school.com.cn/cssref/index.asp#)
Attributes used by advanced use:
@keyframes specify animations.
Animation The shorthand properties of all animated properties, except for the Animation-play-state property.
ANIMATION-NAME Specifies the name of the @keyframes animation.
Animation-duration specifies the seconds or milliseconds that the animation takes to complete a cycle.
animation-timing-function Specifies the speed curve of the animation.
Animation-delay Specifies when the animation starts.
ANIMATION-ITERATION-COUNT specifies the number of times the animation is played.
Animation-direction Specifies whether the animation will play backwards in the next cycle.
ANIMATION-PLAY-STATE Specifies whether the animation is running or paused.
ANIMATION-FILL-MODE specifies the state outside the animation time of the object.

Display parameters are different because of different browsers
Div
{
width:350px;
height:100px;
BORDER:1PX solid black;

/ Firefox /
Display:-moz-box;
-moz-box-orient:horizontal;

/ Safari, Opera and Chrome /
Display:-webkit-box;
-webkit-box-orient:horizontal;

/ /
Display:box;
Box-orient:horizontal;
}

Show different on different devices:
@media screen
{
p.test {font-family:verdana,sans-serif; font-size:14px}
}

@media Print
{
p.test {font-family:times,serif; font-size:10px}
}

@media Screen,print
{
p.test {Font-weight:bold}
}

CSS Learning Notes

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.