mozilla

Revision 27990 of column-count

  • Revision slug: CSS/column-count
  • Revision title: column-count
  • Revision id: 27990
  • Created:
  • Creator: teoli
  • Is current revision? No
  • Comment 1 words added, 1 words removed

Revision Content

Summary

The column-count CSS property describes the number of columns of the element.

  • {{ Xref_cssinitial() }}: {{ Cssxref("auto") }}
  • Applies to: non-replaced block-level elements (except table elements), table cells, and inline-blocks elements
  • {{ Xref_cssinherited() }}: no
  • Percentages: n/a
  • Media: {{ Xref_cssvisual() }}
  • {{ Xref_csscomputed() }}: specified value

Syntax

column-count: integer     or
column-count: auto

where :

auto
Is a keyword indicating that the number of columns should be determined by other CSS properties, like {{ cssxref("column-width") }}.
integer
Is a strictly positive {{ xref_cssinteger() }} describing the ideal number of columns into which the content of the element will be flowed. If the {{ cssxref("column-width") }} is also set to a non-auto value, it merely indicates the maximum allowed number of columns.

Examples

.content-box {
  border: 10px solid #000000;
  column-count:3;
}

Specifications

Specification Status Comment
CSS Multi-column Layout Module Level 3 {{ Spec2('CSS3 Multicol') }}  

Browser compatibility

Browser Lowest Version Support of
CSS3 Candidate Rec. column-count
Internet Explorer 10 column-count
Firefox (Gecko) 1.5 (1.8) -moz-column-count
Opera 11.1 column-count
Safari (Webkit) 3.0 (522) -webkit-column-count

See also

{{ CSS_Reference:Columns() }}

{{ languages( { "ja": "ja/CSS/-moz-column-count" } ) }}

Revision Source

<h2>Summary</h2>
<p>The <code>column-count </code>CSS property describes the number of columns of the element.</p>
<ul> <li>{{ Xref_cssinitial() }}: {{ Cssxref("auto") }}</li> <li>Applies to: non-replaced block-level elements (except table elements), table cells, and inline-blocks elements</li> <li>{{ Xref_cssinherited() }}: no</li> <li>Percentages: n/a</li> <li>Media: {{ Xref_cssvisual() }}</li> <li>{{ Xref_csscomputed() }}: <a href="/en/CSS/specified_value" title="specified value">specified value</a></li>
</ul>
<h2 name="Syntax">Syntax</h2>
<pre class="eval">column-count: <em>integer</em>     or
column-count: auto
</pre>
<p>where :</p>
<dl> <dt style="margin-left: 40px;">auto</dt> <dd style="margin-left: 40px;">Is a keyword indicating that the number of columns should be determined by other CSS properties, like {{ cssxref("column-width") }}.</dd> <dt style="margin-left: 40px;"><em>integer</em></dt> <dd style="margin-left: 40px;">Is a strictly positive {{ xref_cssinteger() }} describing the ideal number of columns into which the content of the element will be flowed. If the {{ cssxref("column-width") }} is also set to a non-<strong>auto</strong> value, it merely indicates the maximum allowed number of columns.</dd>
</dl>
<h2 name="Examples">Examples</h2>
<pre class="eval">.content-box {
  border: 10px solid #000000;
  column-count:3;
}
</pre>
<h2 name="Specifications">Specifications</h2>
<table class="standard-table"> <thead> <tr style="background-color: rgb(255, 204, 255);"> <th scope="col">Specification</th> <th scope="col">Status</th> <th scope="col">Comment</th> </tr> </thead> <tbody> <tr> <td><a class="external" href="http://www.w3.org/TR/css3-multicol/#cc" title="http://www.w3.org/TR/css3-multicol/#cc">CSS Multi-column Layout Module Level 3</a></td> <td>{{ Spec2('CSS3 Multicol') }}</td> <td> </td> </tr> </tbody>
</table>
<h2>Browser compatibility</h2>
<table class="standard-table"> <tbody> <tr> <th>Browser</th> <th>Lowest Version</th> <th>Support of</th> </tr> <tr> <td colspan="2">CSS3 Candidate Rec.</td> <td><code>column-count</code></td> </tr> <tr> <td>Internet Explorer</td> <td><strong>10</strong></td> <td><code>column-count</code></td> </tr> <tr> <td>Firefox (Gecko)</td> <td><strong>1.5</strong> (1.8)</td> <td><code>-moz-column-count</code></td> </tr> <tr> <td>Opera</td> <td><strong>11.1</strong></td> <td><code>column-count</code></td> </tr> <tr> <td>Safari (Webkit)</td> <td><strong>3.0</strong> (522)</td> <td><code>-webkit-column-count</code></td> </tr> </tbody>
</table>
<h2 name="See_also">See also</h2>
<p>{{ CSS_Reference:Columns() }}</p>
<div class="noinclude"> <p>{{ languages( { "ja": "ja/CSS/-moz-column-count" } ) }}</p>
</div>
Revert to this revision