Title: Size ODG

Hello,
I try to extract in a Java program the size of an ODG. I have write this code :

        XDrawPage vDrawPage = (XDrawPage) UnoRuntime.queryInterface(XDrawPage.class, vIndexedDrawPages.getByIndex(0));
        XShape vGroup = ((XShapeGrouper) UnoRuntime.queryInterface(XShapeGrouper.class, vDrawPage)).group((XShapes) UnoRuntime.queryInterface(XShapes.class, vDrawPage));

            pXmlWriter.hWriteStartTag("page");
        pXmlWriter.hWriteAttribut("width", Integer.toString(vSize.Width));
            pXmlWriter.hWriteAttribut("height", Integer.toString(vSize.Height));
        pXmlWriter.hWriteEndEmptyTag();


... But, this code return a bad value in some case (with "clavier.odg" for instance, it is bad).
Is there a better means to optain always the correct size?
Thanks.
Antoine


<<...>>

Attachment: clavier.odg
Description: application/vnd.oasis.opendocument.graphics

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to