Issue 90553

Summary: import MathML : Pb with ^
Product: Math Reporter: apourche <antoine.pourchez>
Component: codeAssignee: AOO issues mailing list <issues>
Status: REOPENED --- QA Contact:
Severity: Trivial    
Priority: P3 CC: issues, jjcogliati-r1, rb.henschel
Version: OOo 2.4.0   
Target Milestone: 4.0.0   
Hardware: All   
OS: All   
Issue Type: DEFECT Latest Confirmation in: ---
Developer Difficulty: ---
Attachments:
Description Flags
Sample MML that show the PB
none
bad view in openOffice
none
Good View in Firefox
none
Patch to fix all simple accent problems from Libre Office
none
simple accents none

Description apourche 2008-06-10 13:06:39 UTC
This equation isn't imported correctly in OO because of the char ^:
<math xmlns="http://www.w3.org/1998/Math/MathML">
    <mstyle fontfamily="serif">
        <mrow>
            <msub>
                <mover>
                    <mi>t</mi>
                    <mo accent="true">^</mo>
                </mover>
                <mi>A</mi>
            </msub>
        </mrow>
    </mstyle>
</math>
Comment 1 apourche 2008-06-10 13:08:30 UTC
Created attachment 54359 [details]
Sample MML that show the PB
Comment 2 apourche 2008-06-10 13:10:54 UTC
Created attachment 54360 [details]
bad view in openOffice
Comment 3 apourche 2008-06-10 13:11:19 UTC
Created attachment 54361 [details]
Good View in Firefox
Comment 4 michael.ruess 2008-06-11 13:24:34 UTC
MRU->TL: the import of the attached MML gives "font serif t csup  widehat_A",
but it should be more sth. like "font serif {hat t}_A". The csup is not
necessary because of widehat; also the widehatis in wrong position.
Comment 5 jrincayc 2010-02-24 18:52:32 UTC
Note that this bug can be triggered by opening a ODT file that comes from
Microsoft Word.  

This has also been reported in the redhat bugzilla
https://bugzilla.redhat.com/show_bug.cgi?id=533318
Comment 6 jrincayc 2012-06-30 01:51:45 UTC
I created and put up a patch for this bug for libreoffice. I would guess that it can be used for Open Office as well:
https://bugs.freedesktop.org/show_bug.cgi?id=33849
Comment 7 Regina Henschel 2012-06-30 12:47:24 UTC
@jrincayc: Your patch is appreciated. Please attach it here and assure, that you give the patch under Apache License, Version 2.0 (http://www.apache.org/licenses/LICENSE-2.0).
Comment 8 jrincayc 2012-07-01 14:57:12 UTC
Created attachment 78525 [details]
Patch to fix all simple accent problems from Libre Office

Patch created for Libre Office, but I think it should probably work with Open Office, and I am giving the patch under Apache License, Version 2.0.
Comment 9 Regina Henschel 2012-08-08 15:09:40 UTC
I have tried LO3.6 and it does not show the formula as I can see it in the browser. Isn't this patch applied to LO3.6?

I have applied the patch to my local working copy of AOO. There too I still see the wrong formula.

Has someone verified, that the patch works as intended?

What I did:
 Open a new formula document.
 Tools > Import Formula...
 Choose the file attached to this bug.
Comment 10 Regina Henschel 2012-08-08 16:38:11 UTC
Created attachment 78883 [details]
simple accents

The patch does not solve the bad rendering of the first attachment, but is solves wrong import for those simple accents, which can be applied from the 'Attributes' category in Math. The attached file contains a collection of that characters.
Comment 11 SVN Robot 2012-08-08 17:17:00 UTC
"regina" committed SVN revision 1370843 into trunk:
#i90553# fix simple accents in MathML importPatch by: Joshua Cogliati;Review ...
Comment 12 hdu@apache.org 2013-07-10 15:07:09 UTC
adjusted target to version that will contain the fix
Comment 13 Regina Henschel 2014-12-27 16:48:36 UTC
Single accents are good, but the initial document is still not rendered correctly. There seems to be an additional problem here.