Bug 101203 - centered style lost them export docx to html
Summary: centered style lost them export docx to html
Status: RESOLVED DUPLICATE of bug 72308
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.1.4.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-07-29 17:09 UTC by Alexey Kakunin
Modified: 2016-08-06 19:27 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
simplest docx with centered line (21.36 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2016-07-29 17:09 UTC, Alexey Kakunin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Kakunin 2016-07-29 17:09:10 UTC
Created attachment 126471 [details]
simplest docx with centered line

Open simplest docx (attached) with one centered line in Writer - everything is ok.
Save it as HTML and open in browser - line will not be centered.
It happens because writer saved in head -> style tag default styles for p (looks like generated from default paragraph style defined in original docx file.
In styles there are text-align: center is defined for p element.
Later in body <p align="center" is used for centering paragraphs, but style definition overrides this and paragraph stays centered left.

To fix it for centering elements instead of align="center" style="text-align: center" should be used.
Comment 1 Buovjaga 2016-08-06 19:27:39 UTC

*** This bug has been marked as a duplicate of bug 72308 ***