Issue 24050 - Writing to HTML document, paragraph style info overriden
Summary: Writing to HTML document, paragraph style info overriden
Status: CLOSED DUPLICATE of issue 19690
Alias: None
Product: Writer
Classification: Application
Component: code (show other issues)
Version: OOo 1.1
Hardware: PC Windows 2000
: P3 Trivial (vote)
Target Milestone: ---
Assignee: eric.savary
QA Contact: issues@sw
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-02 21:56 UTC by dwig
Modified: 2013-08-07 14:38 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Simple document illustrating the problem, zipped. (611 bytes, application/x-compressed)
2004-01-02 21:59 UTC, dwig
no flags Details
Demo of the DD/DT STYLE tags problem (916 bytes, application/x-compressed)
2004-04-19 10:07 UTC, jvromans
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description dwig 2004-01-02 21:56:34 UTC
I've been using Writer (in 1.0.1 and now 1.1.0) to write and update a document
in HTML format (natively, without going through .sxw).

I'm using the Text Body style for most of the paragraphs.  I noticed that it
was leaving more space between paragraphs than I wanted, so I set the style's
"below paragraph" spacing to 0.  In the generated HTML, I get the following:

	P { margin-top: 0.1in; margin-bottom: 0in }

... which is fine.  However, all the paragraphs begin with the following
tag: <P STYLE="margin-bottom: 0.2in">.  In other words, each paragraph forces
the "below paragraph" spacing to 0.2in, explicitly overriding the style
declaration.  I haven't found any way to change this behavior.  I've even edited
the HTML file with a text editor to remove the undesired "STYLE=...", but this
is ignored by Writer, and re-saving it puts the attributes back.

After playing with it a bit, I notice that "new" text is saved correctly, but
when you open the saved document, it's read back in with the "forced" style.

I'll attach a simple HTML document illustrating this.

The closest existing bug report I found was #22174; they may be related.
Comment 1 dwig 2004-01-02 21:59:22 UTC
Created attachment 12229 [details]
Simple document illustrating the problem, zipped.
Comment 2 dwig 2004-01-02 22:09:27 UTC
By the way, I'm an experienced developer.  If someone could give me some good
pointers to get started on this, I might have enough time to work on it myself.
 (It'd be a learning experience, though -- I haven't looked under the hood at
all yet.)
Comment 3 h.ilter 2004-01-06 10:22:15 UTC
Reassigned to ES
Comment 4 jvromans 2004-04-19 10:05:55 UTC
I have a similar problem that may be related. In a HTML document the global
styles for description lists are:

	DD { margin-left: 0.2in; margin-bottom: 0.2in }
	DT { margin-left: 0.1in }

The DT/DD elements in the text do not have STYLE attributes.

When OOo opens this document, the descriptions lists appear with margin-left:
0.1in (for DD) and 0in (for DT). In other words, the HTML edititor does not obey
the style definitions.

When the document is saved, the global style definitions are still there, but
every DT/DD element has an explicit STYLE attribute attached that overrides the
global style settings.
Comment 5 jvromans 2004-04-19 10:07:57 UTC
Created attachment 14630 [details]
Demo of the DD/DT STYLE tags problem
Comment 6 eric.savary 2004-10-24 01:34:55 UTC
duplicate

*** This issue has been marked as a duplicate of 19690 ***
Comment 7 eric.savary 2004-10-24 01:35:15 UTC
closed