Bug 66286

Summary: Add an option to format an equation in "display" mode
Product: LibreOffice Reporter: Frédéric Wang <fred.wang>
Component: WriterAssignee: Not Assigned <libreoffice-bugs>
Status: RESOLVED INVALID QA Contact:
Severity: enhancement    
Priority: medium CC: dr.khaled.hosny
Version: 4.2.0.0.alpha0+ Master   
Hardware: All   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: Sample odt document
Sample output

Description Frédéric Wang 2013-06-27 23:09:34 UTC
See the related bug that should be handled in the Math code (bug 66278). It seems that at the moment, LibreOffice Writer only allows "inline" formulas. It should be possible to add an UI like

Format -> Formula -> Display/Inline mode

and/or

Right click on a Formula -> Display/Inline mode

so that the user can format an equation in "display" mode. This would have at least the effect of centering the equation in its own paragraph and transmit that info to Math so that the math rendering engine could take that into account. Then when exporting to XHTML the <math> element will have a display="block" attribute attached to it (I guess the XHTML exports relies on the MathML export and so this last point will be fixed in bug 66278) so that browsers can correctly display the formula.
Comment 1 Frédéric Wang 2013-06-27 23:09:57 UTC
Created attachment 81591 [details]
Sample odt document
Comment 2 Frédéric Wang 2013-06-27 23:14:54 UTC
Created attachment 81592 [details]
Sample output

Here is an XHTML example that shows how the document should be exported to XHTML. Note the display="block" on the second equation and the different rendering when you open in e.g. Firefox.
Comment 3 Frédéric Wang 2013-06-28 13:39:24 UTC
OK, there is actually already an option Format => Text in Math to do that. It just remains to modify the MathML export to add the display attribute when necessary.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.