Uploaded image for project: 'FOP'
  1. FOP
  2. FOP-1778

Nested inline elements with text-align attribute cause an Exception

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Resolution: Unresolved
    • 0.95
    • None
    • renderer/pdf
    • None
    • Operating System: Windows XP
      Platform: PC
    • 48806

    Description

      I am using FOP 0.95 (latest stable at the time of writing) and attached FO
      file.

      I convert it to PDF with

      fop -fo exception.fo sample.PDF

      Expected output:
      A PDF file

      Actual output

      The following exception:

      java.lang.ClassCastException: org.apache.fop.layoutmgr.LeafPosition cannot be cast to org.apache.fop.layoutmgr.NonLeafPosition
      at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:217)
      at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:125)
      at org.apache.fop.cli.Main.startFOP(Main.java:166)
      at org.apache.fop.cli.Main.main(Main.java:197)

      If I remove either the inline elements or the text-align attribute the exception goes away

      Attachments

        1. fo.xml
          1 kB
          Peter Hancock
        2. exception.fo
          2 kB
          Kostis Kapelonis

        Activity

          People

            Unassigned Unassigned
            kkapelon@freemail.gr Kostis Kapelonis
            Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: