Closed
Bug 176866
Opened 22 years ago
Closed 22 years ago
"Retain original source formatting" does not work properly
Categories
(Core :: DOM: Serializers, defect)
Tracking
()
People
(Reporter: brian, Assigned: harishd)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
Win2k, build 2002102508.
Set the Composer prefs to "Retain original source formatting," then use
Composer. You will find that some amount of reformatting is taking place.
For example, newlines are being inserted after <br>. This should only occur
when pretty printing is turned on.
Also, many more newlines are being inserted in various places, and Mozilla is
attempting to do some indentation. It looks like some prettyprinting code is
being used when it shouldn't.
Line breaks are added below each TABLE /TABLE or BR tag, and closing tags such
as /P, /ADDRESS, /H1 ... /H6, etc. EVERY TIME you switch to SOURCE view, make a
change and switch back to NORMAL view.
Note separate related Bug 159615 about extra line breaks in the HEAD, and Bug
177303 dealing with line breaks being deleted after DOCTYPE, HTML, HEAD,
/STYLE, and /BODY
Comment 2•22 years ago
|
||
*** Bug 174107 has been marked as a duplicate of this bug. ***
Comment 3•22 years ago
|
||
This bug makes editing web pages very frustrating.
What is to happen (spec?) if the user switches back and forth between "Retain
original source formatting" and "Reformat HTML source"? Does one setting add new
lines and line breaks and the other removes them, or does each pref take it as
is gets it (more likely)?
I get this on Win98. Shouldn't this be OS=All?
Comment 4•22 years ago
|
||
*** Bug 179531 has been marked as a duplicate of this bug. ***
Comment 5•22 years ago
|
||
*** Bug 193354 has been marked as a duplicate of this bug. ***
Comment 6•22 years ago
|
||
This appears to be a duplicate of 174361.
Comment 7•22 years ago
|
||
Comment 8•22 years ago
|
||
The added-linebreak symptoms described by "burpmaster" seem to have been fixed
in 1.3 Final, if not earlier. There are still problems with some elements of
the <body> being being unwantedly reformatted (see my demo attachment in
Bug 174361, and the numerous bugs blocking that bug), and also with newline
control outside of the <body> (see Bug 25141). Perhaps these extra linebreaks
were fixed as a result of the work on Bug 145196 ?
Anyway, this bug WFM.
Comment 9•22 years ago
|
||
I'm still seeing this problem with build 2003040209-TRUNK where the HTML source
is being changed with newlines being added.
Comment 10•22 years ago
|
||
Hmmm, it should be noted (in addition to my previous comment) that I didn't save
the HTML and look at the saved file. What I did was past the testcase into the
"HTML Source" window of Composer, switched to "Normal" and then switched back to
"HTML Source" which is where I saw the extra newlines which didn't exist when I
pasted the HTML. I have "Retain original source formatting" set, although that
seems to only apply to Saving or Publishing.
However, switching from HTML Source to Normal to HTML Source shouldn't change
things. This is what I understand the original problem to be, and is exactly
what Comment #3 is saying.
Testcases coming....
Comment 11•22 years ago
|
||
This is the test case just after I'd pasted it into "HTMl Source" in Composer.
Comment 12•22 years ago
|
||
This is the same HTML after switching to "Normal" and then back to "HTML
Source". Why all the newlines?
Comment 13•22 years ago
|
||
OK, I see that now: If you edit in the Source window (typing or pasting), then
switch to Normal and back to Source, the extraneous newlines are generated.
However, opening the file and editing in Normal or Tags or Preview does not add
the extraneous newlines, either in the Source view or in the saved file.
The symptoms in Bug 97278 are generated in the same way. I submit that this is
a dupe of that bug, despite the reports talking about different parts of the
file.
Comment 14•22 years ago
|
||
Agreed, this is a dup.
*** This bug has been marked as a duplicate of 97278 ***
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
Comment 15•22 years ago
|
||
Please move your votes to Bug 97278!
Comment 16•21 years ago
|
||
*** Bug 227179 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
•