You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by bu...@apache.org on 2012/08/06 16:26:40 UTC

[Bug 53659] New: RTF renderer barfs when fo:table-row is missing inside fo-table-header

https://issues.apache.org/bugzilla/show_bug.cgi?id=53659

          Priority: P2
            Bug ID: 53659
          Assignee: fop-dev@xmlgraphics.apache.org
           Summary: RTF renderer barfs when fo:table-row is missing inside
                    fo-table-header
          Severity: normal
    Classification: Unclassified
          Reporter: gisbert.selke@wido.bv.aok.de
          Hardware: PC
            Status: NEW
           Version: all
         Component: rtf
           Product: Fop

Created attachment 29170
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=29170&action=edit
Input FO, output PDF (for reference), trace, conf

In RTF, using fo:table-cell as direct children of fo:table-header (without
intervening fo:table-row) causes the FOPException "... RTFHandler: startCell
null". In PDF, it works flawlessly (which it should, as far as I understand the
FO
specs).

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 53659] [PATCH] RTF renderer barfs when fo:table-row is missing inside fo-table-header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=53659

Robert Meyer <rm...@hotmail.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|RTF renderer barfs when     |[PATCH] RTF renderer barfs
                   |fo:table-row is missing     |when fo:table-row is
                   |inside fo-table-header      |missing inside
                   |                            |fo-table-header

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 53659] RTF renderer barfs when fo:table-row is missing inside fo-table-header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=53659

--- Comment #2 from Robert Meyer <rm...@hotmail.co.uk> ---
Created attachment 29509
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=29509&action=edit
Patch to fix mismatch between XSL:FO and RTF regarding header table-rows

This issue is happening because it is always expecting there to be a TableRow
even though Gisbert correctly states that one is not required for XSL:FO. This
fix tries to create the missing container element if one cannot be found. This
however creates the problem that because no endRow() method is ever fired, the
new TableRow will be left hanging by itself which causes table rendering
issues.

To fix this, each element whether it is a writeable section or not (i.e.
headers, footers) are pushed to the stack either as an RtfContainer or as their
matching FObj object. When a pop event occurs, a check is made to see that what
it thinks is being popped actually matches the top item on the stack. If it
doesn't, then it means there is a mismatch and it is likely caused by a new
table row. In this event, the item is pushed back onto the stack and a call to
the method matching that class is made to close the tag pair before attempting
to re-pop the original item.

The code allows for further expansion should any other tag mismatches between
XSL:FO and RTF be found. I have tested this patch against the original bug FO
and it works correctly. There are a couple of things which are not ideal but
please feel free to post any comments or suggestions if you have them.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 53659] RTF renderer barfs when fo:table-row is missing inside fo-table-header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=53659

Robert Meyer <rm...@hotmail.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #29509|0                           |1
        is obsolete|                            |

--- Comment #3 from Robert Meyer <rm...@hotmail.co.uk> ---
Created attachment 29510
  --> https://issues.apache.org/bugzilla/attachment.cgi?id=29510&action=edit
Corrected patch file

Sorry, that original patch was related to something else. I have now posted the
correct patch file.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 53659] RTF renderer barfs when fo:table-row is missing inside fo-table-header

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=53659

Gisbert <gi...@wido.bv.aok.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Version|all                         |1.1dev
                 OS|                            |All

--- Comment #1 from Gisbert <gi...@wido.bv.aok.de> ---
I'm running on Windows 7, using FOP 1.1rc1

-- 
You are receiving this mail because:
You are the assignee for the bug.