Closed
Bug 18545
Opened 26 years ago
Closed 24 years ago
[FLOAT] Problem Centering <TABLE> with <DIV> tag
Categories
(Core :: Layout, defect, P3)
Tracking
()
VERIFIED
WORKSFORME
Future
People
(Reporter: unapersson, Assigned: buster)
References
()
Details
(Keywords: testcase)
Attachments
(4 files)
Applying align=center or text-align: center to a DIV tag does not center tables
within it. Using a <center> tag, which is a "shortcut" for <div align=center>,
however does work.
See testcase for examples
Reporter | ||
Comment 1•26 years ago
|
||
Reporter | ||
Updated•26 years ago
|
Updated•26 years ago
|
Assignee: karnaze → kipp
Comment 2•26 years ago
|
||
This is a block or line problem. Reassigning.
Why are you re-reassing layout bugs? Do NOT touch layout bugs.
The bugs are assigned to Kipp so they can stay neatly organized until we have a
new owner for the block/inline code.
Updated•26 years ago
|
QA Contact: petersen → chrisd
mass moving all Kipp's pre-beta bugs to M15. Nisheeth and I will
prioritize these and selectively move high-priority bugs into M13 and M14.
Summary: Problem Centering <TABLE> with <DIV> tag → [FLOAT] Problem Centering <TABLE> with <DIV> tag
mine! mine mine mine! all mine! whoo-hoo!
Assignee: kipp → buster
the fix for this is to account for both NS_STYLE_TEXT_ALIGN_MOZ_CENTER and
NS_STYLE_TEXT_ALIGN_CENTER in nsBlockReflowContext::AlignBlockHorizontally().
Same for NS_STYLE_TEXT_ALIGN_MOZ_RIGHT, while I'm at it.
Status: NEW → ASSIGNED
Whiteboard: fix in hand
Assignee | ||
Comment 10•25 years ago
|
||
fix checked in. should be able to verify against 4/17/00 build.
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Whiteboard: fix in hand
Comment 11•25 years ago
|
||
Verified.
Windows: 2000-07-13-09-M17
NOT fixed for Linux. Verified on 2000-07-13-08-M17 build.
The text and the cell are left justified for 2nd and 4th row.
But, they should be centered and right aligned respectively.
Group: netscapeconfidential?
OS: Windows NT → Linux
Updated•25 years ago
|
Group: netscapeconfidential?
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Comment 12•25 years ago
|
||
Reopening per Bindu's last comments.
Assignee | ||
Comment 13•25 years ago
|
||
extremely odd. this is totally xp code. I don't know why linux would behave
differently. how does mac look?
Note that I changed some of the behavior when fixing bugs 37083 and bug 40038
(so that 'text-align: center' doesn't center blocks, since there was no evidence
that real sites depended on that quirk).
Assignee | ||
Comment 15•25 years ago
|
||
needs investigation. won't make RTM, marking Future.
Status: REOPENED → ASSIGNED
Target Milestone: M16 → Future
On my Linux trunk build from a few days ago, all the testcases are correct as I
think they should be in both quirks and standard mode (HTML's align centers
blocks, CSS's text-align works according to the CSS spec).
Comment 17•25 years ago
|
||
Upon managerial request, adding the "testcase" keyword to 84 open layout bugs that
do not have the "testcase" keyword and yet have an attachement with the word
"test" in the description field. Apologies for any mistakes.
Keywords: testcase
Comment 18•25 years ago
|
||
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; m18) Gecko/20001220
BuildID: 2000122004
text-align: when applied to block elements affects their inline content,
not the element itself, as per
http://www.w3.org/TR/REC-CSS2/text.html#propdef-text-align
<TABLE> is a block element NOT an inline element as defined in HTML:
http://www.w3.org/TR/html4/strict.dtd
http://www.w3.org/TR/html4/loose.dtd
I agree with David Baron. tables in 2nd and 4th rows *should* be left justified
To center the tables themselves { margin-left: auto; margin-right: auto; }
should be applied.
This bug seems to be fully resolved and works correctly for me.
Comment 19•25 years ago
|
||
The auto margins go on the table itself, not the div containing the table.
Comment 21•25 years ago
|
||
OK. Removing the DIV around the table and adding the definition 'TABLE {margin-
left: auto; margin-right: auto;}' to my style element causes part of the table
to be centered: the caption is still off at the left of the page. The inline
caption element is contained within the block table element. Is this a
different bug?
Mozilla/5.0 (Windows; U; WinNT4.0; en-US; m18) Gecko/20001228
It's not a bug. CSS2 17.4.1 says: "Captions above or below a 'table' element
are formatted very much as if they were a block element before or after the
table, except that (1) they inherit inheritable properties from the table, and
(2) they are not considered to be a block box for the purposes of any 'compact'
or 'run-in' element that may precede the table." You'd need to add the same
auto margins to the caption.
Comment 23•25 years ago
|
||
I understand. Thank you for your patience. I agree that this bug is resolved.
Comment 24•24 years ago
|
||
Netscape's standard compliance QA team reorganised itself once again, so taking
remaining non-tables style bugs. Sorry about the spam. I tried to get this done
directly at the database level, but apparently that is "not easy because of the
shadow db", "plus it screws up the audit trail", so no can do...
QA Contact: chrisd → ian
Comment 25•24 years ago
|
||
Can someone re-close this bug and mark it as FIXED?
Comment 26•24 years ago
|
||
Updated•24 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 25 years ago → 24 years ago
Resolution: --- → WORKSFORME
Comment 27•24 years ago
|
||
WORKSFORME on Win32 Netscape Commercial Build 2001030308.
WORKSFORME on Linux Netscape Commercial Build 2001030608.
(tested both quirks and standards mode)
You need to log in
before you can comment on or make changes to this bug.
Description
•