Detailed CSS common operation classification method

Source: Internet
Author: User
This article is mainly for everyone to explain the CSS common operation classification method, interested in small partners can refer to

One, size operation

Height set Element Heights

Line-height Setting Row Height

. p1{    width:400px;    Line-height:normal;} . p2{    width:400px;    line-height:200%;} . p3{    width:400px;    line-height:50%;}
<! DOCTYPE html>

Max-height Setting the maximum height of an element

Max-width Setting the maximum width of an element

. p1{    Line-height:normal;    max-width:250px;}

Min-width set Element Minimum width

Min-height setting element Minimum height

Width setting element widths

Second, classification operation

Clear sets whether other floating elements are allowed on the side of an element

CURSOR specifies the type of pointer to display when pointing to an element

p{    Cursor:auto;}
p{    Cursor:alias;}
p{    Cursor:cell;}

Display settings whether and when elements are displayed

li{    Display:inline;} <ul>    <li>Hello</li>    <li>Hello</li>    <li>Hello</li>    <li>Hello</li></ul>

float defines in which direction the element floats

Position placing elements in a static, relative, absolute, fixed position

Visibility setting whether an element is visible or invisible

li{    Display:inline;    Visibility:hidden;}
li{    Display:inline;    visibility:visible;}
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.