CSS3 box-orient 屬性

來源:互聯網
上載者:User

標籤:style   http   java   get   width   javascript   

CSS3 box-orient 屬性

CSS 參考手冊

執行個體

水平排列 div 元素的子項目:

div{width:350px;height:100px;border:1px solid black;/* Firefox */display:-moz-box;-moz-box-orient:horizontal;/* Safari、Opera 以及 Chrome */display:-webkit-box;-webkit-box-orient:horizontal;/* W3C */display:box;box-orient:horizontal;}

親自試一試

瀏覽器支援

目前沒有瀏覽器支援 box-orient 屬性。

Firefox 支援替代的 -moz-box-orient 屬性。

Safari、Opera 以及 Chrome 支援替代的 -webkit-box-orient 屬性。

定義和用法

box-orient 屬性規定框的子項目應該被水平或垂直排列。

提示:水平框中的子項目從左向右進行顯示,而垂直框的子項目從上向下進行顯示。不過,box-direction 和 box-ordinal-group 能夠改變這種順序。

預設值: inline-axis
繼承性: no
版本: CSS3
JavaScript 文法: object.style.boxOrient="vertical"
文法
box-orient: horizontal|vertical|inline-axis|block-axis|inherit;
值 描述 測試
horizontal 在水平行中從左向右排列子項目。 測試
vertical 從上向下垂直排列子項目。 測試
inline-axis 沿著行內軸來排列子項目(映射為 horizontal)。 測試
block-axis 沿著塊軸來排列子項目(映射為 vertical)。 測試
inherit 應該從父元素繼承 box-orient 屬性的值。  
http://www.w3school.com.cn/cssref/pr_box-orient.asp  

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

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.