Closed Bug 291078 Opened 19 years ago Closed 18 years ago

[FIX]editable text of form input elements rendered outside of element object

Categories

(Core :: Layout: Block and Inline, defect, P3)

defect

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: daniel, Assigned: bzbarsky)

References

Details

(Keywords: testcase)

Attachments

(3 files, 2 obsolete files)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.7) Gecko/20050414 Firefox/1.0.3
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.7) Gecko/20050414 Firefox/1.0.3

In the HTML/CSS supplied, the editable text shown in the text boxes (file upload
fields as well) is rendered at the left of the page rendering area. The text
should be rendered within the input element -- it also renders the text in other
extremities (not visible) based on the left/right alignment of the table
wrapping the input elements.

Occurs in Firefox and Mozilla browser. 
respectively:
(Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.7) Gecko/20050414
Firefox/1.0.3)
(Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8b2) Gecko/20050419).

Reproducible: Always

Steps to Reproduce:
1. view HTML attached -- text inputs display correctly
2. with HTML attached -- remove the /* */ from around the css class selector:
".type:first-line"
3. view HTML attached -- text inputs display incorrectly

Actual Results:  
1. text of input elements appears within the actual input elements
2. --
3. text of input elements appears at top left of rendering area, or not visible
at all. physical text elements are in the correct position

Expected Results:  
Should have rendered text of input elements within the physical input element

Perhaps something to do with nesting lists within tables?

Nesting as follows:
table -> tr -> td -> [ul -> li's ->] ul -> li's -> input element
                      ^
                      I have tried removing these and rendering is still incorrect.
See instructions to reproduce bug... This HTML displays correctly without
".type:first-line " being used...
Attachment #181236 - Attachment description: HTML file of input elements rendering text incorrectly → HTML file of input elements rendering text correctly
A minimal testcase would be nice...
Attachment #181236 - Attachment is obsolete: true
Attachment #181237 - Attachment is obsolete: true
Keywords: testcase
Attached patch FixSplinter Review
The problem is that when we put the input inside the first-line we don't set the HAS_CHILD_WITH_VIEW flag on it, so we don't reposition the view when we reposition the inner table.  As a result, OffsetTo() lies all over, and when painting we decide that some frames are just outside the dirty region... and don't paint them (used to paint them in totally the wrong place).

It might be worth fixing this on 1.8, I think....
Attachment #245372 - Flags: superreview?(roc)
Attachment #245372 - Flags: review?(roc)
Daniel, sorry this took so long to get to.  :(  The testcase was incredibly helpful, though!
Status: UNCONFIRMED → NEW
Component: Layout: Form Controls → Layout: Block and Inline
Ever confirmed: true
QA Contact: layout.form-controls → layout.block-and-inline
Assignee: nobody → bzbarsky
OS: Windows XP → All
Priority: -- → P3
Hardware: PC → All
Summary: editable text of form input elements rendered outside of element object → [FIX]editable text of form input elements rendered outside of element object
Target Milestone: --- → mozilla1.9alpha
Attachment #245372 - Flags: superreview?(roc)
Attachment #245372 - Flags: superreview+
Attachment #245372 - Flags: review?(roc)
Attachment #245372 - Flags: review+
Fixed.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Added the tests to reftest.
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: