8.15. CSS3 user interface

发布时间 : 2025-10-25 13:34:13 UTC      

Page Views: 10 views

8.15.1. CSS3 user interface

In CSS3, some new user interface features have been added to resize elements, boxes, and borders.

In this chapter, you will learn about the following user interface properties:

  • Resize

  • Box-sizing

  • Outline-offset

8.15.2. Browser support

The number in the table represents the first browser version number that supports the property.

The number immediately preceding -webkit- , -ms- , or -moz- is the first browser version number that supports the prefix attribute.

Attribute

Resize

4.0

79.0

5.0 4.0-moz-

4.0

15.0

Box-sizing

10.04.0-webkit-

8.0

29.02.0-moz-

5.1 3.1-webkit-

9.5

Outline-offset

4.0

15.0

5.0 4.0-moz-

4.0

9.5

8.15.3. CSS3 Resize (Resizing)

In CSS3 resize property specifies whether an element should be resized by the user. This div element is resized by the user. (in Firefox 4, Chrome, and Safari)

The CSS code is as follows:

Example

A div element size is specified by the user:

div { resize:both; overflow:auto; } 

8.15.4. CSS3 box resizing (Box Sizing)

box-sizing property allows you to define specific content that fits an area in an exact way.

Example

Specify two side-by-side boxes with borders:

div { border:2px solid black; outline:2px solid red; outline-offset:15px; } 

8.15.5. CSS3 shape Modification (outline-offset)

outline-offset property to offset the outline and draw the outline beyond the edge of the border.

An outline differs from a border in two things:

  • The outline does not take up space.

  • The outline may be non-rectangular

The div has an outline 15 pixels outside the border.

The CSS code is as follows:

Example

Specify the outline at 15 pixels outside the edge of the border:

div { border:2px solid black; outline:2px solid red; outline-offset:15px; } 

8.15.6. New user interface features

Attribute

Description

CSS

appearance

Allows you to make an element look like a standard user interface element

3

box-sizing

Allows you to define certain elements in some way by adapting to the region

3

icon

Provides creators with the ability to set elements as icon equivalents.

3

nav-down

Specify where to use the arrow down navigation keys to navigate

3

nav-index

Specify the order of the Tab of an element

3

nav-left

Specify where to navigate using the arrow navigation keys on the left

3

nav-right

Specify where to navigate using the arrow navigation keys on the right

3

nav-up

Specify where to use the arrow up navigation keys to navigate

3

outline-offset

The outer outline modifies and draws the edge beyond the border

3

resize

Specifies whether an element is resized by the user

3

《地理信息系统原理、技术与方法》  97

最近几年来,地理信息系统无论是在理论上还是应用上都处在一个飞速发展的阶段。 GIS被应用于多个领域的建模和决策支持,如城市管理、区划、环境整治等等,地理信息成为信息时代重要的组成部分之一; “数字地球”概念的提出,更进一步推动了作为其技术支撑的GIS的发展。 与此同时,一些学者致力于相关的理论研究,如空间感知、空间数据误差、空间关系的形式化等等。 这恰好说明了地理信息系统作为应用技术和学科的两个方面,并且这两个方面构成了相互促进的发展过程。