Skip to content

Commit 9c1e809

Browse files
committed
Dimensions: normalize outerWidth and outerHeight
1 parent 9257b80 commit 9c1e809

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

entries/outerHeight.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0"?>
22
<entries>
3-
<desc>Get the current computed height for the first element in the set of matched elements, including padding, border, and optionally margin. Returns a number (without "px") representation of the value or null if called on an empty set of elements.</desc>
3+
<desc>Get the current computed outer height (including padding, border, and optionally margin) for the first element in the set of matched elements or set the outer height of every matched element.</desc>
44
<entry type="method" name="outerHeight" return="Number">
55
<title>.outerHeight()</title>
66
<signature>
@@ -9,10 +9,10 @@
99
<desc>A Boolean indicating whether to include the element's margin in the calculation.</desc>
1010
</argument>
1111
</signature>
12-
<desc>Get the current computed height for the first element in the set of matched elements, including padding, border, and optionally margin. Returns a number (without "px") representation of the value or null if called on an empty set of elements.</desc>
12+
<desc>Get the current computed outer height (including padding, border, and optionally margin) for the first element in the set of matched elements.</desc>
1313
<longdesc>
14-
<p>The top and bottom padding and border are always included in the <code>.outerHeight()</code> calculation; if the <code>includeMargin</code> argument is set to <code>true</code>, the margin (top and bottom) is also included.</p>
15-
<p>This method is not applicable to <code>window</code> and <code>document</code> objects; for these, use <code><a href="/height/">.height()</a></code> instead.</p>
14+
<p>Returns the height of the element, including top and bottom padding, border, and optionally margin, in pixels.</p>
15+
<p>This method is not applicable to <code>window</code> and <code>document</code> objects; for these, use <code><a href="/height/">.height()</a></code> instead. Although <code>.outerHeight()</code> can be used on table elements, it may give unexpected results on tables using the <code>border-collapse: collapse</code> CSS property.</p>
1616
<figure>
1717
<img src="/resources/0042_04_03.png"/>
1818
<figcaption>Figure 1 - Illustration of the measured height</figcaption>
@@ -60,7 +60,7 @@ $( "p:last" ).text(
6060
<desc>A function returning the outer height to set. Receives the index position of the element in the set and the old outer height as arguments. Within the function, <code>this</code> refers to the current element in the set.</desc>
6161
</argument>
6262
</signature>
63-
<desc>Set the CSS outer Height of each element in the set of matched elements.</desc>
63+
<desc>Set the CSS outer height of each element in the set of matched elements.</desc>
6464
<longdesc>
6565
<p>When calling <code>.outerHeight(value)</code>, the value can be either a string (number and unit) or a number. If only a number is provided for the value, jQuery assumes a pixel unit. If a string is provided, however, any valid CSS measurement may be used (such as <code>100px</code>, <code>50%</code>, or <code>auto</code>).</p>
6666
</longdesc>

entries/outerWidth.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0"?>
22
<entries>
3-
<desc>Get the current computed width for the first element in the set of matched elements, including padding and border.</desc>
3+
<desc>Get the current computed outer width (including padding, border, and optionally margin) for the first element in the set of matched elements or set the outer width of every matched element.</desc>
44
<entry type="method" name="outerWidth" return="Number">
55
<title>.outerWidth()</title>
66
<signature>
@@ -9,10 +9,9 @@
99
<desc>A Boolean indicating whether to include the element's margin in the calculation.</desc>
1010
</argument>
1111
</signature>
12-
<desc>Get the current computed width for the first element in the set of matched elements, including padding and border.</desc>
12+
<desc>Get the current computed outer width (including padding, border, and optionally margin) for the first element in the set of matched elements.</desc>
1313
<longdesc>
14-
<p>Returns the width of the element, along with left and right padding, border, and optionally margin, in pixels.</p>
15-
<p>If <code>includeMargin</code> is omitted or <code>false</code>, the padding and border are included in the calculation; if <code>true</code>, the margin is also included.</p>
14+
<p>Returns the width of the element, including left and right padding, border, and optionally margin, in pixels.</p>
1615
<p>This method is not applicable to <code>window</code> and <code>document</code> objects; for these, use <code><a href="/width/">.width()</a></code> instead. Although <code>.outerWidth()</code> can be used on table elements, it may give unexpected results on tables using the <code>border-collapse: collapse</code> CSS property.</p>
1716
<figure>
1817
<img src="/resources/0042_04_06.png"/>
@@ -45,6 +44,7 @@ $( "p:last" ).text(
4544
<category slug="manipulation/style-properties"/>
4645
<category slug="version/1.2.6"/>
4746
</entry>
47+
4848
<entry type="method" name="outerWidth" return="jQuery">
4949
<signature>
5050
<added>1.8.0</added>

0 commit comments

Comments
 (0)