Last Comment Bug 9258 - [FIX] topmargin="0" leftmargin="0" not applied
: [FIX] topmargin="0" leftmargin="0" not applied
: topembed
Product: Core
Classification: Components
Component: Layout (show other bugs)
: Trunk
: x86 All
: P3 normal (vote)
: mozilla0.9.4
Assigned To: Marc Attinasi
: Chris Petersen
: Jet Villegas (:jet)
Depends on:
  Show dependency treegraph
Reported: 1999-07-03 17:44 PDT by bene
Modified: 2001-09-05 17:03 PDT (History)
3 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

PATCH to map topmargin and leftmargin attributes in QuirksMode (3.67 KB, patch)
2001-08-14 15:09 PDT, Marc Attinasi
no flags Details | Diff | Splinter Review
Testcase (109 bytes, text/html)
2001-08-14 15:15 PDT, Marc Attinasi
no flags Details

Description bene 1999-07-03 17:44:29 PDT
<body topmargin="0" leftmargin="0">

I am not quite sure if the margin's are suppost to be part of the HTML specs, but if they are,
they aren't quite working properly.  If they are not part of the HTML spec, then I appologize.

But it wouldn't hurt to include support for these tags.

Ben Efros
Comment 1 rickg 1999-07-06 11:17:59 PDT
Kipp-- I don't think we do topmargin and leftmargin this way, do we? If not,
please close this bug.
Comment 2 kipp 1999-07-06 14:41:59 PDT
1. Navigator never supported "topmargin" or "leftmargin" for body elements; it
does support "marginwidth" and "marginheight" which provides symmetric
left/right top/bottom margins, but is deprecated in favor of the css approach.

2. HTML4 has no such attributes for the BODY element either.

Therefore, we aren't going to implement them in gecko.

If you want to affect the top/left margins for an element, use css:

<body style="margin-top: 0; margin-left: 0">

for example.
Comment 3 Hixie (not reading bugmail) 2001-08-02 20:57:18 PDT
This would be an easy 'bug' to fix. (Netscape people: See WRMB 7958.)
Comment 4 Hixie (not reading bugmail) 2001-08-02 20:57:53 PDT
(buster is no longer working on mozilla)
Comment 5 jag (Peter Annema) 2001-08-09 18:25:00 PDT
jst, hyatt: any idea who could fix this, and/or how?
Comment 6 Hixie (not reading bugmail) 2001-08-10 01:47:56 PDT
It's a simple matter of adding code to the BODY tag's MapAttributesInto stuff.
We already do it for some attributes, extending it to work with the other
attributes should be trivial.
Comment 7 Waheed Islam 2001-08-12 15:03:09 PDT
could we _please_ include support for this, even though it's not part of html 4.

If mozilla was completely based on standards, it would turnout something like
amaya! :(

But I mean, mozilla should _support_ both standards and non-standards.

Cause otherwise without support for this, sites won't turn out quite as they
should... -- this site isn't such a good example since it
looks nearly fine even without support,

but please, include <body topmargin=*> !
Comment 8 Waheed Islam 2001-08-12 15:05:54 PDT
sorry, wrong url above...
Comment 9 Christopher Hoess (gone) 2001-08-14 12:43:57 PDT

*** This bug has been marked as a duplicate of 26788 ***
Comment 10 Marc Attinasi 2001-08-14 13:49:03 PDT
Reopening bug. I'm going to fix for this, so marking it a dup of a WONTFIX bug
is not right.
Comment 11 Marc Attinasi 2001-08-14 13:49:42 PDT
Comment 12 Marc Attinasi 2001-08-14 15:09:53 PDT
Created attachment 45840 [details] [diff] [review]
PATCH to map topmargin and leftmargin attributes in QuirksMode
Comment 13 Marc Attinasi 2001-08-14 15:11:23 PDT
Patch has been attached to map the topmargin and leftmargin to the body in
quirks mode, for compatibility with IE. Seeking reviews (r and sr).
Comment 14 Marc Attinasi 2001-08-14 15:15:14 PDT
Created attachment 45845 [details]
Comment 15 Johnny Stenback (:jst, 2001-08-14 15:30:26 PDT
Comment 16 Alexandru Savulov 2001-08-14 16:21:34 PDT
r= alexsavulov
Comment 17 Marc Attinasi 2001-08-15 15:25:49 PDT
Checked into branch and trunk.
Comment 18 David Baron :dbaron: ⌚️UTC-10 2001-08-15 15:43:52 PDT
I have to say I don't like the idea of making this quirks mode only.  I think
it's good to keep the list of quirks to a minimum -- and there's no reason
supporting all these extra features breaks standards (any more than all the ones
we already do).
Comment 19 Marc Attinasi 2001-08-15 15:54:25 PDT
dbaron, does the HTML spec say what should be done with attributes that are NOT
part of the standard? I would think that, if we had a true strict-DTD parser,
these attributes would be thrown out anyway. I'm confused, but you know more
than I about this: is it really 'standards compliant' to honor non-standard
attributes (or tags for that matter)?

I'd be more than happy to remove the quirk-check, I was under the impression
(possibly erroneous) that non-standard attributes, and especially IE-specific
ones :), were not allowed in standard mode.
Comment 20 Marc Attinasi 2001-08-15 16:01:11 PDT
... or is this the key to understanding your statement?

> ... (any more than all the ones we already do).
Comment 21 David Baron :dbaron: ⌚️UTC-10 2001-08-15 17:40:32 PDT
Partly, although if we have features that don't exist in standard mode, that
will discourage people from using it.

IMO, quirks mode should be used only when we need to deviate from a standard to
make the web work -- otherwise we should act as though we didn't have multiple
modes.  This will keep the number of differences to a minimum and make our lives
much less confusing.
Comment 22 Marc Attinasi 2001-08-15 17:48:26 PDT
I opened bug 95530 for further discussion of UnQuirking this. Let's discuss it
Comment 23 Chris Petersen 2001-09-05 17:03:26 PDT
Marking verified in the Sept 05th build (2001-09-05-05)

Note You need to log in before you can comment on or make changes to this bug.