Closed
Bug 189367
Opened 22 years ago
Closed 17 years ago
Form elements cause reflow in nested <div> with width less than 100%
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
People
(Reporter: coop, Unassigned)
References
()
Details
(Keywords: testcase)
Attachments
(5 files, 1 obsolete file)
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3a) Gecko/20021207 Phoenix/0.5 Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.3a) Gecko/20021207 Phoenix/0.5 If you click on the <select> boxes or the submit or reset buttons on the example page, the width of the <div> will gradually shrink as reflow events occur. If you view the source of this page, you will see that there is a <div class="entry"> with a width of 90% nested inside a <div class="main"> with position=absolute. The reflow in question does not occur if: * position attribute is not set for <div class="main"> * width=100% for <div class="entry"> * there is not enough text inside <div class="entry"> that it requires line wrapping Reproducible: Always Steps to Reproduce: 1.Click on <select> box or form buttons on affected page. Actual Results: <div> is dynamically resized (get smaller) each time a new item is selected in the <select> boxes, or the form buttons (submit or reset) are pressed. Expected Results: No reflow should occur.
Reporter | ||
Comment 1•22 years ago
|
||
This is the same page as listed in the URL field, if you would like to download and test locally.
Reporter | ||
Comment 2•22 years ago
|
||
Symptoms are similar to those listed in bug #162268.
Comment 3•22 years ago
|
||
->layout
Assignee: blaker → other
Component: General → Layout
Product: Phoenix → Browser
QA Contact: asa → ian
Version: unspecified → Trunk
Updated•22 years ago
|
Priority: -- → P3
Updated•20 years ago
|
Comment 4•20 years ago
|
||
See it happening: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041109 Firefox/1.0
Updated•20 years ago
|
Assignee: nobody → mats.palmgren
Updated•20 years ago
|
Assignee: mats.palmgren → nobody
Status: UNCONFIRMED → NEW
Ever confirmed: true
Updated•20 years ago
|
Component: Layout: R & A Pos → Layout
QA Contact: core.layout.r-and-a-pos → core.layout
Comment 5•20 years ago
|
||
The shrinking width part of the problem was fixed by bug 201897. The remaining problem that form control elements move when you click on them is reported elsewhere I think. Possibly bug 147558?
Depends on: 147558
Comment 6•19 years ago
|
||
In the simple testcase, the width of the <div> will shrink half as reflow events occur, since the incremental reflow measures only a line of "ccccc ddddd".
Updated•19 years ago
|
OS: Linux → All
Priority: P3 → --
Hardware: PC → All
Comment 7•19 years ago
|
||
The test patch is able to reflow all lines.
Comment on attachment 183405 [details] [diff] [review] test patch This patch is so obviously wrong. How many times does a frame get a initial reflow, as the word says initial => once. So what does the patch do? It simply forces another unconstrained reflow by changing the reflowreason to initial. The chances to get this reviewed are 0.
Comment 9•19 years ago
|
||
I mixed two patches that is 1. the changes for absolutely positioned frame with 'auto' width and 2. the changes for changing the line layout as reflow events occur. The changes for 1. causes to mark all lines dirty and the changes for 2. causes to mark the previous line dirty. I think that the changes for 2. concerns with Bug 92217.
Updated•19 years ago
|
Attachment #183405 -
Attachment is obsolete: true
Comment 10•19 years ago
|
||
Comment 11•19 years ago
|
||
Updated•19 years ago
|
Attachment #183583 -
Flags: review?(bernd_mozilla)
Comment 12•19 years ago
|
||
Comment on attachment 183583 [details] [diff] [review] patch For me this patch is not better than the first one. It will mark lines dirty if the parent has auto width. The following is a repetition from a another review denial but it applies here as well: 1. No hacks, please 2. I believe this is a hack, in order to convince me that this is not the case please provide a reflow log and show where it goes wrong and how this patch fixes the situation. Please pay special attention to the maximumWidth. Looking at attachment 183402 [details], it probably first requests the maximumwidth and sets that as the outerdiv width as it shrinks around the container. When the link is focussed it wraps as it probably uses the previous width instead of the maximumwidth. This patch reinforces a new maximumwidth computation by marking all lines dirty. However I am not a block specialist like roc or dbaron are but I am pretty confident that this is wrong.
Attachment #183583 -
Flags: review?(bernd_mozilla) → review-
Comment 13•19 years ago
|
||
s/this is/this patch is/
Comment 14•17 years ago
|
||
This problem is already fixed from build of seamonkey-1.5a-20061208-trunk/WinXP and later, I think this is fixed by the fix for Bug 300030.
Updated•17 years ago
|
Flags: in-testsuite?
You need to log in
before you can comment on or make changes to this bug.
Description
•