CSS Application Basics Tutorial: Basic knowledge

Source: Internet
Author: User

Basic knowledge of application

The application of CSS is not difficult, but please refer to the basic understanding here, some words have a little basic concepts, for you look at the back of the teaching will be helpful, it looks like it will not be too strenuous!

I. Understanding of BASIC terminology:

Symbol (Element): the tag (tag) in the HTML basic syntax.

attribute: An attribute used to describe a label attribute.

For example:

   , HR is the label, width is the attribute, and 80% is the value of the Width property.

Property: Used to describe the characteristics of a component. Equivalent to the attributes in the basic HTML syntax.

Style: A property of a group or array that describes the characteristics of a component.

Selector (selector): A component of the applied style.

For example:

h3{Color:blue}, H3 is the pick, color is the property, BLUE is a color value.

Second, the basic unit of understanding:

There are two units of relative units and absolute units to express the way.

Relative units:

"em": the proportional factor relative to the letter height.

"EN": proportional factor relative to the font size.

"%": an example of a percentage relative to the length unit (usually the size of the current font).

Absolute Unit:

' In ': inches.

"cm": cm.

"MM": mm.

"px": Pixel (System preset unit).

"PC": Pica, printing type unit.

"PT": Like Dot.

Relative relationship: 1in= 6pc= 72pt= 2.54cm= 25.4mm

Third, the use of color awareness:

There are five different ways to represent colors.

"#RRGGBB":

The values of the red, green, and blue primaries of 0 to 2,550 values, respectively, are represented by a value of three 00 to FF 16.

"#RGB":

The abbreviated notation, which uses only three 0 to F 16 values, respectively, to represent the red, green, and blue primary values. In fact, the browser automatically expands to six-16-digit values, such as "#ABC" will change to "#AABBCC". However, it is not obvious that such a notation is accurate.

"RGB (R,G,B)":

Color is represented by the values of red, green, and blue primaries of 0 to 2,550.

"RGB (r%,g%,b%)":

A color, such as "RGB (60%,100%,75%)", that is relative to each other in red, green, and blue.

"Color_name":

Color is directly represented by the color name, and there are 141 standard color names.

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.