Closed
Bug 47149
Opened 24 years ago
Closed 23 years ago
[LBL]label element is treated as inline-block
Categories
(Core :: Layout, defect, P1)
Core
Layout
Tracking
()
VERIFIED
FIXED
mozilla0.9.4
People
(Reporter: ian, Assigned: dbaron)
References
()
Details
(Keywords: css1, testcase, Whiteboard: [Hixie-P3] [nsbeta3-] hit during nsbeta2 standards compliance testing (py8ieh: file new bug))
Attachments
(3 files)
4.49 KB,
text/html
|
Details | |
21.23 KB,
patch
|
Details | Diff | Splinter Review | |
1.04 KB,
text/html
|
Details |
It appears that we are treating the <label> element as an inline-block of sorts.
This predates October 1998 according to the CVS logs, so it's no regression...
This causes the rather amusing problems shown in the attached test case.
TO REPRODUCE:
Open the testcase.
TESTED ON:
Windows 2000 commercial bits 6.0.17.2000072920.
This is probably due to two things. One, the 'display:block' line in html.css;
originally added to ua.css by Troy in January 1998 (rev 3.81 of ua.css). Two,
the "LabelHack" function in
http://lxr.mozilla.org/mozilla/source/layout/html/forms/src/nsLabelFrame.cpp
...which starts off:
// XXX a hack until the reflow state does this correctly
// XXX when it gets fixed, leave in the printf statements or add an assertion
static
void LabelHack(nsHTMLReflowState& aReflowState, char* aMessage)
I'd suggest it may (if I'm right) be time to "fix" that function...
BTW, there is another bug with radio buttons visible in that test case, namely
the strange vertical alignment in the span. That will be filed separately.
Nominating for beta3. This is a CSS1 and HTML4 compliance issue that can
actually be seen in the CSS ImportTest, one of the testcases quoted by the Web
Standards Project.
Reporter | ||
Comment 1•24 years ago
|
||
Reporter | ||
Updated•24 years ago
|
Blocks: html4.01
QA Contact: petersen → py8ieh=bugzilla
Summary: <label> element causes radio button acrobatics → <label> element causes radio button acrobatics
Whiteboard: hit during nsbeta2 standards compliance testing
Comment 4•24 years ago
|
||
Marking as future for now, this is lower priority. I have looked at the
LabelHack method and I am still not quite sure why Troy put it in. It needs
another look.
marking as nsbeta3- for now
Status: NEW → ASSIGNED
Priority: P3 → P2
Whiteboard: hit during nsbeta2 standards compliance testing → [nsbeta3-]hit during nsbeta2 standards compliance testing
Target Milestone: --- → Future
Reporter | ||
Comment 5•24 years ago
|
||
Our creative handling of <label> elements is probably preventing them from
being drag&dropped, too (bug 49906).
Blocks: 49906
Whiteboard: [nsbeta3-]hit during nsbeta2 standards compliance testing → [nsbeta3-] hit during nsbeta2 standards compliance testing (py8ieh: file new bug)
Reporter | ||
Updated•24 years ago
|
Summary: <label> element causes radio button acrobatics → <label> element causes radio button acrobatics [INLINE]
Reporter | ||
Updated•24 years ago
|
OS: Windows 2000 → All
Hardware: PC → All
Summary: <label> element causes radio button acrobatics [INLINE] → <label> element causes radio button acrobatics [INLINE] (a label tag within a table cell doesn't get word wrapped)
Updated•24 years ago
|
Summary: <label> element causes radio button acrobatics [INLINE] (a label tag within a table cell doesn't get word wrapped) → [LBL]<label> element causes radio button acrobatics [INLINE] (a label tag within a table cell doesn't get word wrapped)
Comment 8•24 years ago
|
||
Ok, I give up. What exactly is wrong with the rendering of the testcase? Please
describe what I am looking for.
Target Milestone: Future → ---
Reporter | ||
Comment 9•24 years ago
|
||
Rod: Sections 1 and 2 of the testcase:
http://bugzilla.mozilla.org/showattachment.cgi?attach_id=12211
...should look identical (the second section is the right rendering).
Currently they look rather different.
Comment 10•24 years ago
|
||
Nomination for 0.9. Still occurs in tip build on linux from a couple days ago.
Keywords: mozilla0.9
Comment 11•24 years ago
|
||
Ok, so the point here is that a label should act like a span? Or I guess what
Troy was trying to fake was an inline-block.
Marc, what is going on with inline-blocks these days? I know it was something
somebody was always going to get to.
Reporter | ||
Updated•24 years ago
|
QA Contact: ian → amar
Comment 13•24 years ago
|
||
See also bug 76117, checkbox label doesn't unwrap when resizing browser window.
Comment 14•24 years ago
|
||
See also bug 77141, table's colspan is ignored because of label.
Reporter | ||
Updated•24 years ago
|
Whiteboard: [nsbeta3-] hit during nsbeta2 standards compliance testing (py8ieh: file new bug) → [Hixie-P3] [nsbeta3-] hit during nsbeta2 standards compliance testing (py8ieh: file new bug)
Assignee | ||
Comment 15•23 years ago
|
||
*** Bug 85306 has been marked as a duplicate of this bug. ***
Assignee | ||
Updated•23 years ago
|
Summary: [LBL]<label> element causes radio button acrobatics [INLINE] (a label tag within a table cell doesn't get word wrapped) → [LBL]label element is treated as inline-block
Comment 16•23 years ago
|
||
I logged bug 85306, which has been marked as a duplicate of this bug. In light
of the fact that this is not just an academic standards complience issue, but
results in a real problem with the layout of all HTML forms which support
accessibility, is there a target milestone for this bug? "Target Milestone:
Future" doesn't fill me with confidence that it's ever going to be fixed.
I don't want to bitch too much (Mozilla generally rocks), but the internal
Oracle javatools bug logging application looks like a pile of crap because of
this bug, yet it has to use <label> tags in order to comply with our
accessibility policies. I usually do a good job of convincing people in my group
at Oracle to use Mozilla rather than IE, but I can't in all good faith recommend
Mozilla while it still has bugs like this.
If bugzilla was properly accessible and used <label> as it was intended, this
bug would get fixed pretty quickly.
Comment 17•23 years ago
|
||
there is no more label{display:block;} in html.css or even quirk.css
Assignee | ||
Comment 18•23 years ago
|
||
*** Bug 89432 has been marked as a duplicate of this bug. ***
Comment 19•23 years ago
|
||
To echo Brian Duff, this bug also makes our web-based product look broken, but we
can't remove the label tags because of government accessibility requirements.
Please! This is a CSS1 compliance issue with high priority. Can we get a
reasonably soon target milestone for this?
Keywords: mozilla0.9.4
Assignee | ||
Comment 20•23 years ago
|
||
Assignee | ||
Comment 21•23 years ago
|
||
The basic idea of the patch is that label doesn't need to be all that special.
So it removes a lot of code that made label different. All it leaves is the
hacked GetFrameForPoint that is needed to forward clicks to the controls and the
accesskey registration/unregistration.
Assignee | ||
Comment 22•23 years ago
|
||
taking
Assignee: rods → dbaron
Status: ASSIGNED → NEW
Priority: P2 → P1
Target Milestone: Future → mozilla0.9.4
Assignee | ||
Comment 23•23 years ago
|
||
This patch makes label inline-only (i.e., 'display: block' fails), which isn't
great, but it's better than what we have now. The real long-term solution would
be to move this form control stuff into content so that we don't need a special
frame class for label. (And moving form control content model stuff into the
content model would fix a lot of bugs in general.)
Assignee | ||
Comment 24•23 years ago
|
||
Comment 25•23 years ago
|
||
Wow, a lot of code gone, that isn't a bad thing. I applied the patch and it
looks good r=rods (thanks for taking the bug and fixing it)
Comment 26•23 years ago
|
||
sr=attinasi
Comment 27•23 years ago
|
||
Retested the test cases for bug 85306 with the patch. The layout of labels is
still completely broken. Please advise whether 85306 was closed as a duplicate
in error and should be reopened.
Assignee | ||
Comment 28•23 years ago
|
||
Bug 85306 sure looks fixed to me. Are you sure you applied the patch correctly
and rebuilt correctly?
Comment 29•23 years ago
|
||
Terribly sorry, I haven't been building my own mozilla for long. Did a rebuild
from the top, and the patch seems to have done the trick. Thanks David!
Comment 30•23 years ago
|
||
a=asa on behalf of drivers
Assignee | ||
Comment 31•23 years ago
|
||
Fix checked in 2001-08-24 06:58 PDT.
Filed bug 96813 on additional problems.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 32•23 years ago
|
||
Reopening, since I forgot to check in the forms.css half of the change!
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 33•23 years ago
|
||
forms.css change checked in too, 2001-08-27 13:56 PDT.
Status: REOPENED → RESOLVED
Closed: 23 years ago → 23 years ago
Resolution: --- → FIXED
Comment 34•23 years ago
|
||
*** Bug 77141 has been marked as a duplicate of this bug. ***
Comment 35•23 years ago
|
||
The two sections look identical now... The patch checked in did fix the
problem..
Tested with Platform : win2K
build ID : 2001-09-21
and
Platform : Linux 7.1
Build ID : 2001-09-24
Status: RESOLVED → VERIFIED
Comment 36•23 years ago
|
||
jkeiser, see dbaron's comments from 2001-08-22 17:53
Just something to keep in mind as you move form controls into content....
Assignee | ||
Updated•23 years ago
|
Attachment #46836 -
Attachment is patch: false
Attachment #46836 -
Attachment mime type: text/plain → text/html
You need to log in
before you can comment on or make changes to this bug.
Description
•