sitimoen / xdocreport

Automatically exported from code.google.com/p/xdocreport
0 stars 0 forks source link

The text ODF document with frame can't be converted to PDF #218

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create text OpenOffice document
2. Insert frame(menu Insert->Frame...) to this document and save the document
3. Convert created document to PDF

What is the expected output? What do you see instead?

I got an exception.

What version of the product are you using? On what operating system?

This problem was reproduced for both version: 1.0.0 and 1.0.1
OS: Windows 7

Please provide any additional information below.

org.odftoolkit.odfdom.converter.core.ODFConverterException: 
java.lang.ClassCastException: Insertion of illegal Element: 12
    at org.odftoolkit.odfdom.converter.pdf.PdfConverter.doConvert(PdfConverter.java:82)
    at package1.Main$PdfConverterExt.doConvert(Main.java:81)
    at package1.Main.doWork(Main.java:40)
    at package1.Main.main(Main.java:71)
Caused by: java.lang.ClassCastException: Insertion of illegal Element: 12
    at com.lowagie.text.Phrase.add(Unknown Source)
    at fr.opensagres.xdocreport.itext.extension.ExtendedParagraph.addElement(ExtendedParagraph.java:61)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.addITextContainer(ElementVisitorForIText.java:704)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.addITextContainer(ElementVisitorForIText.java:692)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.visit(ElementVisitorForIText.java:320)
    at org.odftoolkit.odfdom.dom.element.text.TextPElement.accept(TextPElement.java:1681)
    at org.odftoolkit.odfdom.converter.core.ElementVisitorConverter.visit(ElementVisitorConverter.java:82)
    at org.odftoolkit.odfdom.dom.DefaultElementVisitor.visit(DefaultElementVisitor.java:1813)
    at org.odftoolkit.odfdom.dom.element.draw.DrawTextBoxElement.accept(DrawTextBoxElement.java:737)
    at org.odftoolkit.odfdom.converter.core.ElementVisitorConverter.visit(ElementVisitorConverter.java:82)
    at org.odftoolkit.odfdom.dom.DefaultElementVisitor.visit(DefaultElementVisitor.java:1605)
    at org.odftoolkit.odfdom.dom.element.draw.DrawFrameElement.accept(DrawFrameElement.java:617)
    at org.odftoolkit.odfdom.converter.core.ElementVisitorConverter.visit(ElementVisitorConverter.java:82)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.addITextContainer(ElementVisitorForIText.java:701)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.addITextContainer(ElementVisitorForIText.java:692)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.visit(ElementVisitorForIText.java:320)
    at org.odftoolkit.odfdom.dom.element.text.TextPElement.accept(TextPElement.java:1681)
    at org.odftoolkit.odfdom.converter.core.ElementVisitorConverter.visit(ElementVisitorConverter.java:82)
    at org.odftoolkit.odfdom.dom.DefaultElementVisitor.visit(DefaultElementVisitor.java:2605)
    at org.odftoolkit.odfdom.converter.pdf.internal.ElementVisitorForIText.visit(ElementVisitorForIText.java:248)
    at org.odftoolkit.odfdom.dom.element.office.OfficeTextElement.accept(OfficeTextElement.java:805)
    at org.odftoolkit.odfdom.converter.pdf.PdfConverter.processBody(PdfConverter.java:126)
    at org.odftoolkit.odfdom.converter.pdf.PdfConverter.doConvert(PdfConverter.java:65)
    ... 3 more

Original issue reported on code.google.com by osadchiy...@gmail.com on 24 Jan 2013 at 4:05

Attachments:

GoogleCodeExporter commented 8 years ago

Original comment by angelo.z...@gmail.com on 24 Jan 2013 at 4:16

GoogleCodeExporter commented 8 years ago
Any updates about this error? It was reported Jan 24, 2013 (7 months ago).

Original comment by valyakol on 1 Aug 2013 at 7:09

GoogleCodeExporter commented 8 years ago
I think we have not do nothing about that. We must find time to try to fix it.

Regards Angelo

Original comment by angelo.z...@gmail.com on 1 Aug 2013 at 8:05

GoogleCodeExporter commented 8 years ago
Exception during conversion is fixed in 1.0.3 version
However the resulting pdf loses some content of the original odt (graphic boxes 
are not supported). See 
https://code.google.com/p/xdocreport/wiki/ODFDOMConverterPDFViaIText to read 
about converter limitations

Original comment by abe...@gmail.com on 21 Aug 2013 at 10:37

GoogleCodeExporter commented 8 years ago

Original comment by abe...@gmail.com on 21 Aug 2013 at 10:38