Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Hi,

sorry i forgot to mention some bacis info and question was not realy clear:

- system: debian wheezy/sid
- LibreOffice 3.3.1
OOO330m19 (Build:8)
tag libreoffice-3.3.1.2, Debian package 1:3.3.1-1
- python-uno           1:3.3.1-1
- uno-libs3            1.7.0+LibO3.3.1-1

How i can export MathML code from formula embedded object? Seems some time ago
it was possible with getMathML method, but no its not AFAIK. Maybe
there are other ways?

2011/3/31 Александр Лаврущенко <kpykcb@gmail.com>:
Hi all,

i want to export mathml from python script. I saw at the forum Basic
code snippet:

http://www.oooforum.org/forum/viewtopic.phtml?t=59791

which looks like:

for nObjectCounter = 0 to oDoc.embeddedObjects.count - 1
oEmbeddedObject = oEmbeddedObjects.getByIndex(nObjectCounter)
if oEmbeddedObject.clsid = "078B7ABA-54FC-457F-8551-6147e776a997" then
nMathObjects = nMathObjects + 1
oMathObject = oEmbeddedObject.embeddedObject
mathml = oMathObject.getMathML
end if
next

I translated this to python code, but seems that  oMathObject here
dont have any method named getMathML.

So question is, what changed in API and how i can get mathml from
formula object:

doc = desktop.loadComponentFromURL(url, "_blank", 0, ())
x=doc.EmbeddedObjects.getByIndex(2)
x.EmbeddedObject.Formula
    <58> u'{ 9x + 14 =17}'
x.EmbeddedObject.getMathML                 # no such method


Thanks for help.

P.S. Provided Basic code give the same result.


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.