Closed
Bug 67690
Opened 24 years ago
Closed 24 years ago
aReflowState.mComputedWidth/Height incorrectly computed when absolutely positioned
Categories
(Core :: Layout: Form Controls, defect)
Core
Layout: Form Controls
Tracking
()
VERIFIED
FIXED
mozilla0.8.1
People
(Reporter: jsp, Assigned: attinasi)
Details
(Whiteboard: [fix in hand])
Attachments
(5 files)
|
3.23 KB,
text/html
|
Details | |
|
47.61 KB,
image/png
|
Details | |
|
420 bytes,
text/html
|
Details | |
|
2.86 KB,
patch
|
Details | Diff | Splinter Review | |
|
12.58 KB,
patch
|
Details | Diff | Splinter Review |
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; m18) Gecko/20010125
BuildID: 2001012504
Checkbox and radio button controls are larger when positioned absolutely than
when they are not so positioned. Size and position should not be related.
Reproducible: Always
Steps to Reproduce:
Create a form with an absolutely positioned checkbox or radio button and another
that is not absolutely positioned. See the attachment for an example.
Actual Results: The positioned control is +/- 25% larger than the unpositioned
control.
Expected Results: Both controls should be the same size.
The same behavior occurs on Macintosh build 2001020208.
Comment 3•24 years ago
|
||
The label positioning may actually be right... The top of the controls lines up
with the top of the text if you ignore ascenders.
But the sizing issue is weird.
I think the label positioning is correct; it's the positioning of the oversized
radio button that's suspect. See the new screen shot attachment.
Comment 6•24 years ago
|
||
Just as it says, I will attach an example using div. Checkboxes and radiobutton
use nsLeafFrame:Reflow which eventually gets the size from
aReflowState.mComputedWidth and it is there that it is already calculated
incorrectly.
Assignee: rods → attinasi
Summary: Form controls sized incorrectly if positioned absolutely → aReflowState.mComputedWidth/Height incorrectly computed when absolutely positioned
Comment 7•24 years ago
|
||
| Assignee | ||
Comment 8•24 years ago
|
||
Interestingly, relative positioning is OK. I'm investigating this now...
Status: NEW → ASSIGNED
| Assignee | ||
Comment 9•24 years ago
|
||
Problem is actually with box-sizing in absolute positioned items. I have a patch
for it now, will attach. Basically, box-sizing was being ignored in
nsHTMLReflowState::InitAbsoluteConstraints.
| Assignee | ||
Comment 10•24 years ago
|
||
Comment 11•24 years ago
|
||
Should make two functions (one for width, one for height) that incorporate this
with the code which respects the min/max width/height? (Possibly inline.) Also,
how about ``apply padding and borders unless unconstrained'' instead of ``MJA -
from CompueBlockBoxData''. :-)
Comment 12•24 years ago
|
||
yep, what chris said
| Assignee | ||
Comment 13•24 years ago
|
||
OK - thanks. I'll consolidate the code, and there are a few other places that
can use it too.
| Assignee | ||
Comment 14•24 years ago
|
||
Comment 15•24 years ago
|
||
looks good to me. run them regression tests, and r=waterson
| Assignee | ||
Comment 16•24 years ago
|
||
Regerssion tests are OK - one meaningful difference was found,
* file:///s:/mozilla/layout/html/tests/block/bugs/55874.html
The rendering is different but more correct. I'm also checking in the testcase
for this bug for future regerssion testing.
| Assignee | ||
Comment 17•24 years ago
|
||
Marking Mozilla 0.9 since I have a reviewed, approved patch in hand.
| Assignee | ||
Comment 18•24 years ago
|
||
Milestone shift --> Moz 0.8.1
Target Milestone: mozilla0.9 → mozilla0.8.1
Comment 19•24 years ago
|
||
sr=hyatt
| Assignee | ||
Comment 20•24 years ago
|
||
Fix checked in: nsHTMLReflowState.h/cpp
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Comment 21•24 years ago
|
||
Verified build 20010724& 20010730trunk os:mac8.6/win98/linux7
Status: RESOLVED → VERIFIED
You need to log in
before you can comment on or make changes to this bug.
Description
•