Closed
Bug 1802
Opened 26 years ago
Closed 25 years ago
<tr align=left/right/center> not working
Categories
(Core :: Layout: Tables, defect, P2)
Tracking
()
VERIFIED
FIXED
M14
People
(Reporter: unapersson, Assigned: karnaze)
References
Details
(Whiteboard: [PDT+])
Attachments
(2 files)
In the below example the text in the second row should be centered, and the third row should be aligned to the right:
<table border=1>
<tr><td>AAA<td>BBB
<tr align=center><td>A<td>B
<tr align=right><td>A<td>B
</table>
The solution has multiple steps.
1. Change UA.CSS.
TD,TH
* set text align to "default" value. May need to invent a default
value to set it to.
* change valign to inherit
TH
* remove text align
TR, TBODY, THEAD, TFOOT
* valign inherit
COL
* valign, background, border, width, visibility all inherit
* change "COL" selector to "COL, :TABLE-COLUMN"
* probably change other table selectors to include their pseudo-style
selector as well?
2. Change style struct so the init value of valign is "unset".
All uses of valign need to be fixed up to account for "unset"
3. Table code needs to change.
valign
Cells need to check their own style struct valign and use it if it is
set.
Else, look at the cell's COL valign and use it if it is set.
Else, use a hard coded default of "middle"
align
Cells need to check their own style struct align and use it if not
"default"
Else, look at the cell's ROW align and use it if set.
Else, look at the cell's COL align and use it if set.
Else, use a hard coded default based on the content tag ("left" for
TD, "center" for TH)
Implementation Strategy
Peter will do steps 1 and 2 when the coast is clear.
I have just done 3, since it does no harm at this point. The proper inheritence
will just work once Peter does the first 2 steps, although part of the code is
#ifdef'd out right now. Remove the #ifdef after Peter's change.
Comment 2•26 years ago
|
||
I have been writing test cases for the THEAD, TBODY and TFOOT elements. The
ALIGN-center and ALIGN-right attribute/values do not work. Is this the same bug?
Comment 5•26 years ago
|
||
per leger, assigning QA contacts to all open bugs without QA contacts according
to list at http://bugzilla.mozilla.org/describecomponents.cgi?product=Browser
Updated•26 years ago
|
Status: NEW → ASSIGNED
Target Milestone: M4 → M6
Comment 7•26 years ago
|
||
This behavior is seen at http://www.amazon.com. There is an align=center
attribute value in both of the TR element tags in the first table. This is
causing the two images (contained in the table) to not align properly.
Updated•26 years ago
|
Summary: <tr> left/right/center alignment not working → [4.xP]<tr> left/right/center alignment not working
Comment 8•26 years ago
|
||
Adding Product Parity code at beginning of Summary section in regards to the
Amazon.com page. Bug occurs on all platforms (4/8 build) in Seamonkey but not in
Comm 4.51 or IE.
Here is an isolated case:
<html>
<head>
<title>1802</title>
</head>
<body>
<table border=0 width=100% cellspacing=0 cellpadding=0>
<tr align=center bgcolor="yellow">
<td>Some text
</td>
</tr>
<tr align=center bgcolor="lime">
<td>Some text
</td>
</tr>
</table>
</body>
</html>
Updated•26 years ago
|
Hardware: PC → All
Updated•25 years ago
|
Target Milestone: M6 → M7
Comment 10•25 years ago
|
||
*** Bug 5819 has been marked as a duplicate of this bug. ***
Comment 11•25 years ago
|
||
*** Bug 709 has been marked as a duplicate of this bug. ***
Comment 12•25 years ago
|
||
*** Bug 7392 has been marked as a duplicate of this bug. ***
Comment 13•25 years ago
|
||
*** Bug 6731 has been marked as a duplicate of this bug. ***
Comment 14•25 years ago
|
||
*** Bug 3733 has been marked as a duplicate of this bug. ***
Comment 15•25 years ago
|
||
*** Bug 2386 has been marked as a duplicate of this bug. ***
Comment 16•25 years ago
|
||
*** Bug 11225 has been marked as a duplicate of this bug. ***
Comment 17•25 years ago
|
||
Deferring to M10
Assignee | ||
Comment 18•25 years ago
|
||
*** Bug 14317 has been marked as a duplicate of this bug. ***
Assignee | ||
Comment 19•25 years ago
|
||
Comment 20•25 years ago
|
||
*** Bug 16323 has been marked as a duplicate of this bug. ***
Comment 21•25 years ago
|
||
*** Bug 16184 has been marked as a duplicate of this bug. ***
Comment 22•25 years ago
|
||
Reassigning peterl's bugs to myself.
Comment 23•25 years ago
|
||
Accepting peterl's bugs that have a Target Milestone
Updated•25 years ago
|
Blocks: html4.01
Summary: [4.xP]<tr> left/right/center alignment not working → [4.xP]<tr align=left/right/center> not working
Comment 24•25 years ago
|
||
[Adjusting summary to be easier to find. Adding HTML4 compliance dependency.]
Comment 25•25 years ago
|
||
*** Bug 18401 has been marked as a duplicate of this bug. ***
Comment 26•25 years ago
|
||
Pushing my M15 bugs to M16
Updated•25 years ago
|
Target Milestone: M16 → M15
Comment 27•25 years ago
|
||
Moving table bugs to M15 just to see how many we have.
Besides, it may help to find duplicates.
Comment 28•25 years ago
|
||
in html.css remove text-align:left from td,th
td, th {
vertical-align: inherit;
display: table-cell;
}
and this works just fine.
testet on winnt,9x with build 1999122808.
any comments ?
Reporter | ||
Comment 29•25 years ago
|
||
Works for me as well, is removing this likely to cause any problems elsewhere?
It looks as though the stylesheet defaults in html.css have priority in the
cascade over presentational HTML. Should this be the case? If not, is this
another more serious bug?
Comment 30•25 years ago
|
||
Deleting those lines also fixes the problem for me. I don't see anything else
affected by this, but I don't know.
Comment 31•25 years ago
|
||
Removing this single line from html.css works for me also.
Changing 'left' to 'inherit' also seems to correct the problem.
Comment 32•25 years ago
|
||
Deleting those lines is not the complete solution. See buster's comment dated
1999-03-01.
Comment 33•25 years ago
|
||
Deleting this line or changing to text-align: inherit works for me.
another problem is that the table!! gets the text-align value from the
inherit element (another known bug) -> possible solution
adding text-align: left to the table element.
changing text-align: inherit at the td, th elements
Comment 34•25 years ago
|
||
*** Bug 24620 has been marked as a duplicate of this bug. ***
Comment 35•25 years ago
|
||
*** Bug 19521 has been marked as a duplicate of this bug. ***
Comment 36•25 years ago
|
||
*** Bug 24772 has been marked as a duplicate of this bug. ***
Comment 38•25 years ago
|
||
*** Bug 25648 has been marked as a duplicate of this bug. ***
Comment 39•25 years ago
|
||
*** Bug 25788 has been marked as a duplicate of this bug. ***
Comment 40•25 years ago
|
||
*** Bug 25801 has been marked as a duplicate of this bug. ***
Comment 41•25 years ago
|
||
A warning: default text alignment would be right, not left, if the user is using
a right-to-left language. Coding left alignments in multiple places in the style
sheet might not be a good idea.
Updated•25 years ago
|
Summary: [4.xP]<tr align=left/right/center> not working → <tr align=left/right/center> not working
Comment 42•25 years ago
|
||
*** Bug 26837 has been marked as a duplicate of this bug. ***
Comment 43•25 years ago
|
||
Comment 44•25 years ago
|
||
The behavior of 4.x is rather tricky to duplicate using CSS. See the above
attachment. However, this needs to be worked on. See related bug 7112.
(Why didn't I know about this bug a year ago?)
Comment 45•25 years ago
|
||
Adding 'beta1' keyword - HTML 4.0 elements and attributes should work in beta1
per beta criteria document.
Keywords: beta1
Comment 46•25 years ago
|
||
looks like PDT+ based on dup count. Rick G. please re-review. Please add
estimated completion date pierre.
Whiteboard: [PDT+]
Assignee | ||
Comment 47•25 years ago
|
||
Pierre, I'm going to take this one and try to make it work within the confines
of the table code while considering bugs 915 and 7112. Later, if there is a more
elegant style solution, we can deal with it. These align bugs have been in the
system far too long.
Assignee: pierre → karnaze
Severity: normal → major
Status: ASSIGNED → NEW
Target Milestone: M15 → M14
Assignee | ||
Comment 48•25 years ago
|
||
Ignore the last half of my previous comments regarding a non elegant solution.
This was fixed by changing html.css and adding a custom style rule to the style
code.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Comment 49•25 years ago
|
||
Verified FIXED with build 2000021708 on Windows NT 4.0 sp6.
From the top:
All code snippets and attachments in this bug works fine.
bug 2962: URL works fine. Code snippet works fine.
bug 3260: Code snippet works fine.
http://www.amazon.com works fine.
bug 5285: Crash consistently on the URL. Created bug 28397.
bug 5819: URL (amazon.com) and code snippet works fine.
bug 709: Code snippet works fine.
bug 7392: URL does NOT look good - reopened bug 25630.
bug 6731: URL works fine.
bug 3733: URL works fine.
bug 2386: URL and testcase works fine.
bug 11225: URL and testcase works fine.
bug 14317: URL and testcase works fine.
bug 16323: URL works fine.
bug 16184: URL works fine.
bug 18401: URL and testcase works fine.
bug 24620: URL shows minor 4xp problem but TR align works. Created bug 28410.
bug 19521: URL and testcase works fine.
bug 24772: Testcase works fine.
bug 25648: Testcase relating to TR align works fine, rest is dup of bug 7471.
bug 25788: URL works fine.
bug 25801: URL works fine.
bug 26837: URL works fine.
Status: RESOLVED → VERIFIED
Assignee | ||
Comment 50•25 years ago
|
||
*** Bug 26198 has been marked as a duplicate of this bug. ***
You need to log in
before you can comment on or make changes to this bug.
Description
•