Bug 101203

Summary: centered style lost them export docx to html
Product: LibreOffice Reporter: Alexey Kakunin <akakunin>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: ilmari.lauhakangas
Priority: medium    
Version: 5.1.4.2 release   
Hardware: All   
OS: All   
Whiteboard:
Crash report or crash signature: Regression By:
Attachments: simplest docx with centered line

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 ***