Fop
  1. Fop
  2. FOP-1908

[PATCH] Percental table column width not calculated from table

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Resolution: Fixed
    • Affects Version/s: 1.0
    • Fix Version/s: None
    • Component/s: rtf
    • Labels:
      None
    • Environment:
      Operating System: All
      Platform: Other
    • External issue ID:
      50901

      Description

      The width of table columns is not correctly calculated for RTF output. A percental width should be calculated from the enclosing table's width.

      org.apache.fop.layoutmgr.table.TableLayoutManager actually does this for PDF output (see getBaseLength() implementation), but org.apache.fop.render.rtf.rtflib.tools.PercentContext doesn't.

      The result is that the last column gets the entire space.

      I'll attach a small example demonstrating the problem as well as a patch that fixes that problem for me.

      1. fop-rtf-table-column-width.patch
        1 kB
        Carsten Pfeiffer
      2. test.fo
        2 kB
        Carsten Pfeiffer
      3. test.pdf
        5 kB
        Carsten Pfeiffer
      4. test-after-patch.rtf
        4 kB
        Carsten Pfeiffer
      5. test-before-patch.rtf
        4 kB
        Carsten Pfeiffer

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            fop-dev
            Reporter:
            Carsten Pfeiffer
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development