Apache OpenOffice (AOO) Bugzilla – Issue 19707
incorrect conversion saving a word processor document as html
Last modified: 2013-08-07 14:38:26 UTC
I saved a document as html and noticed the following: 1) The default font size was changed from 12 to 11 in the html version 2) The heading 1 font size was correctly left at 12 3) Paragraphs had an additional blank line, making the html look double spaced. I tried the same experiment in MS Word 2000, and noticed that the style sheet that Word created had "margin: 0" in the paragraph style description. That seems to have eliminated the double spacing.
Please Attach the documents which make this problem, so we can test it. (Without the documents, we cannot confirm the problem easily) Don't forget to cut other part of the documents, so the file size is small, but we still able to see the problem.
Created attachment 9455 [details] sample MS Word document
I open the file, save as html file, open the html file at html editor. 1. I didnt find that default font is changed. I still get same size. 12. times new roman. in HTML editor, after saving it as html. 2. I didnt understand 3. Yes it is look very different. the space between each line is very big in HTML file compared in ooo writer. so I can confirm number 3 but not the other. Please open other issue. I can Reproduce the problem on OpenOffice 1.1 RC4(default Install, US), Win XP Pro Sp1. (And MS Office XP Sp2). It is real problem
1) Works for me (in Word and Writer, both fonts are 12) 2) ok 3) duplicate of issue 14600 *** This issue has been marked as a duplicate of 14600 ***
closed
Re: #2, font size changed in HTML... This is the style sheet seen in Internet Explorer 5.5 using "view/source" (note that P.western is 11pt and not 12pt): <STYLE> <!-- @page { size: 8.5in 14in; margin-right: 1.25in; margin-top: 1in; margin-bottom: 1in } P { margin-bottom: 0in; direction: ltr; color: #000000; widows: 2; orphans: 2 } P.western { font-family: "Times New Roman", serif; font-size: 11pt; so-language: en-US } P.cjk { font-family: "Times New Roman", serif; font-size: 11pt } P.ctl { font-family: "Times New Roman", serif; font-size: 12pt; so-language: ar-SA } H1 { margin-top: 0in; margin-bottom: 0in; direction: ltr; color: #000000; widows: 2; orphans: 2; text-decoration: underline } H1.western { font-family: "Times New Roman", serif; font-size: 12pt; so-language: en-US; font-weight: medium } H1.cjk { font-family: "Times New Roman", serif; font-size: 12pt; font-weight: medium } H1.ctl { font-family: "Times New Roman", serif; font-size: 12pt; so-language: ar-SA; font-weight: medium } H2 { margin-top: 0in; margin-bottom: 0in; direction: ltr; color: #000000; text-align: center; widows: 2; orphans: 2 } H2.western { font-size: 12pt; so-language: en-US } H2.cjk { font-family: "Times New Roman", serif; font-size: 12pt } H2.ctl { font-family: "Times New Roman", serif; font-size: 12pt; so-language: ar-SA } --> </STYLE> The following is the MS Word version, again viewed via Internet Explorer 5.5, using "view/source". (note that <P> is 12 pt, as it should be): <style> <!-- /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman";} h1 {mso-style-next:Normal; margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; page-break-after:avoid; mso-outline-level:1; font-size:12.0pt; font-family:"Times New Roman"; mso-font-kerning:0pt; font-weight:normal; text-decoration:underline; text-underline:single;} h2 {mso-style-next:Normal; margin:0in; margin-bottom:.0001pt; text-align:center; mso-pagination:widow-orphan; page-break-after:avoid; mso-outline-level:2; font-size:12.0pt; font-family:"Times New Roman";} h3 {mso-style-next:Normal; margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; page-break-after:avoid; mso-outline-level:3; font-size:12.0pt; font-family:"Times New Roman";} p.MsoBodyText, li.MsoBodyText, div.MsoBodyText {margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; mso-bidi-font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman";} p.MsoBodyTextIndent, li.MsoBodyTextIndent, div.MsoBodyTextIndent {margin-top:0in; margin-right:0in; margin-bottom:0in; margin-left:.5in; margin-bottom:.0001pt; text-indent:-.5in; mso-pagination:widow-orphan; tab-stops:-1.0in; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman";} p.MsoBodyText2, li.MsoBodyText2, div.MsoBodyText2 {margin:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman"; text-decoration:underline; text-underline:single;} @page Section1 {size:8.5in 14.0in; margin:1.0in 1.25in 1.0in 1.25in; mso-header-margin:.5in; mso-footer-margin:.5in; mso-paper-source:0;} div.Section1 {page:Section1;} --> </style>
Reassigned to ES
ES->MIB: we write a wrong font size for P.Western (11) which we correct for each piece of P class="Western" using a <FONT SIZE=3>. So the whole text is hard formatted because the the style is wrong...
The style corresponding to <P> is "Text Body". In the attached document, it's size is 11pt. The document itself has "Default" applied, that has a font size of 12pt. "Default" is not mapped to any HTML tag directly, so it's formatting properties have to be exported as hard formatting.
.
,