CSS unit, cssem Unit

Source: Internet
Author: User

CSS unit, cssem Unit
Number

CSS has two types of numbers: integer and real number (decimal)

 

Percentage

The percentage is always relative to a value.


Color

[1] keywords
17 valid naming colors (Standard colors ):

Aqua/fuchsia/lime/olive/red/white/black/gray/maroon/orange/silver/yellow/blue/green/navy/purple/teal
[Note] the browser supports 140 colors


[2] RGB mode

Rgb (x %, y %, z %) or rgb (a, B, c)

[NOTE 1] The range of a, B, and c is (0-255)

[NOTE 2] If the value is smaller than the minimum value 0, the default value is 0. If the maximum value is 255, the default value is 255.


[3] hexadecimal Mode

  #abcdef

[Note] If the numbers of three hexadecimal groups are paired, they can be abbreviated as three digits.

# Aabbcc <=> # abc // red <=> rgb (100%, 0, 0) <=> rgb (,) <=> # ff0000 <=> # f00

 

[Supplement]

Web Security Color refers to the color that can always avoid jitter in the 256 color computer system, expressed as a multiple of RGB value 20% and 51 (the corresponding hexadecimal value is 33. Therefore, when hexadecimal is used, 00 \ 33 \ 66 \ 99 \ cc \ ff is regarded as a Web security color.


Length

Each length unit is followed by a two-letter abbreviation, indicating the specific length unit specified (when the length is 0, it does not need to be followed by the Unit)


[1] absolute length unit
Inch (in)
[Note] 1 inch <=> 2.54 cm <=> 72 points <=> 6-card
Cm)
Mm)
Point (pt)
DISPATCHER (pc)


[2] unit of Relative Length
Em-> em-height indicates the font-size value of a given font.
Ex-> x-height indicates the value of x in the font, but in practice, half of the em value is usually used.
Pixel (px)-> indicates a point on the computer display. The point size depends on the resolution of the display device.

 

URL

URLs are classified into absolute URLs and relative URLs. There cannot be spaces between URLs and start brackets. If space exists, the entire statement is invalid.

url("test.jpg")

 

Related Article

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.