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

RESOLVED FIXED in mozilla1.9alpha1

Status

()

Core
Layout: Block and Inline
P3
normal
RESOLVED FIXED
13 years ago
10 years ago

People

(Reporter: Daniel Herbert, Assigned: bz)

Tracking

({testcase})

Trunk
mozilla1.9alpha1
testcase
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(3 attachments, 2 obsolete attachments)

(Reporter)

Description

13 years ago
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.
(Reporter)

Comment 1

13 years ago
Created attachment 181236 [details]
HTML file of input elements rendering text correctly 

See instructions to reproduce bug... This HTML displays correctly without
".type:first-line " being used...
(Reporter)

Updated

13 years ago
Attachment #181236 - Attachment description: HTML file of input elements rendering text incorrectly → HTML file of input elements rendering text correctly
(Reporter)

Comment 2

13 years ago
Created attachment 181237 [details]
HTML file of input elements rendering text incorrectly
A minimal testcase would be nice...
(Reporter)

Comment 4

13 years ago
Created attachment 183796 [details]
minimal failing test case
Attachment #181236 - Attachment is obsolete: true
Attachment #181237 - Attachment is obsolete: true

Updated

13 years ago
Keywords: testcase
Created attachment 245372 [details] [diff] [review]
Fix

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)
Created attachment 245373 [details]
Testcase without form controls that shows views are the only problem
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
Last Resolved: 11 years ago
Resolution: --- → FIXED
Duplicate of this bug: 235914
Added the tests to reftest.
Flags: in-testsuite+
You need to log in before you can comment on or make changes to this bug.