#10988 closed bug (invalid)
outerHeight is less than height for <table> children when <table> has a negative margin
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | low | Milestone: | None |
Component: | dimensions | Version: | 1.7.1 |
Keywords: | ie7 ie8 | Cc: | |
Blocked by: | Blocking: |
Description
Change History (8)
comment:1 Changed 11 years ago by
Owner: | set to [email protected]… |
---|---|
Status: | new → pending |
comment:2 Changed 11 years ago by
Status: | pending → new |
---|
win xp. ie 7, 8. if you like jsFiddle see http://jsfiddle.net/UHDaG/ if table has margin less than 0 (for example margin-top: -100px) outerHeight will be broken (for example 0px)
comment:3 Changed 11 years ago by
Component: | unfiled → dimensions |
---|---|
Priority: | undecided → low |
Summary: | outerHeight is less than height → outerHeight is less than height for <table> children when <table> has a negative margin |
comment:4 Changed 11 years ago by
Status: | new → open |
---|
comment:5 Changed 11 years ago by
Keywords: | ie7 ie8 added |
---|
comment:6 Changed 11 years ago by
Status: | open → pending |
---|
please read: http://www.w3.org/TR/CSS2/tables.html#height-layout and http://www.w3.org/TR/CSS2/tables.html#table-layout
"Internal table elements do not have margins."
"The height of a 'table-row' element's box is calculated once the user agent has all the cells in the row available: it is the maximum of the row's computed 'height', the computed 'height' of each cell in the row, and the minimum height (MIN) required by the cells."
In short, while TR's can have height (which is not wholely determined by the css provided), they can not have margin. Some browsers inherit the margin from the parent TABLE and others allow setting the property on a TR, but neither value is the correct one. Simply don't user outerheight on a TR.
Please let me know what the use case here is on why you were trying to measure margin on a TR.
comment:7 Changed 11 years ago by
Resolution: | → invalid |
---|---|
Status: | pending → closed |
Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!
comment:8 Changed 11 years ago by
I know this got autoclosed... needs docs maybe? Don't try to measure margin on a TR?
Thanks for taking the time to contribute to the jQuery project! Please provide a complete reduced test case on jsFiddle to help us assess your ticket.
Additionally, be sure to test against the jQuery Edge version to ensure the issue still exists. To get you started, use this boilerplate: http://jsfiddle.net/FrKyN/ Open the link and click to "Fork" (in the top menu) to get started.
I get 100 on both on Chrome. So please also specify which browser you're using.