https://bugs.documentfoundation.org/show_bug.cgi?id=72308
Michael Warner <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.documentfounda | |tion.org/show_bug.cgi?id=95 | |861 --- Comment #11 from Michael Warner <[email protected]> --- If I create a new document, and set some text centered, I get the HTML output: <p align="center" style="line-height: 100%; margin-bottom: 0in"> Centered</p> And when I view this in a web browser, it is centered. When I open the attached document, and export to HTML, it has align="center" attribute on the <p> tag but is rendered as left-justified (as described in Comment 0). So, in that sense, this is confirmed. However, the reason it is justified from the attached document is that the export from the attached document also contains a <style> tag in the header: p { color: #000000; text-align: justify; orphans: 2; widows: 2; direction: ltr; background: transparent } The text-align:justify style on p is over-riding the align="center" attribute on the element. Looking in LO Writer, I can see that justified alignment is set on the "Text Body" paragraph style. So, the bug here is that in LO, alignment set directly on text over-rides a paragraph style, but it seems that the opposite is true in HTML. The align="center" attribute is the HTML 4 way to do it, "text-align:center" style is the HTML 5 way. This goes back to the fact that we aren't really generating proper HTML 5 for export. See discussion in Bug 95861. -- You are receiving this mail because: You are the assignee for the bug.
