Uploaded image for project: 'Pentaho Reporting and Pentaho Report Designer'
  1. Pentaho Reporting and Pentaho Report Designer
  2. PRD-5446

Localization of number-field format-string for PDF exports

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Severity: Low
    • Resolution: Incomplete
    • Affects Version/s: 5.3.0 GA
    • Fix Version/s: Backlog
    • Component/s: Engine, Report Generation
    • Labels:
      None
    • Environment:
      Java 1.8 web application running in Tomcat 8 servlet container
      - P
    • Story Points:
      0
    • Notice:
      When an issue is open, the "Fix Version/s" field conveys a target, not necessarily a commitment. When an issue is closed, the "Fix Version/s" field conveys the version that the issue was fixed in.

      Description

      Please note: data is provided to MasterReport via TableModel and passed onto PdfReportUtil.createPDF for generation.

      Given a number-field with the following format-string:

      #,##0.00
      

      Pentaho generates the right format for both US and Finnish number formats for Excel files. I guess because the format property is set for a cell. For instance:

      US: 1,000.00
      EU: 1 000,00
      

      On the other hand, when generating PDF files, the output is as such:

      US: 1,000.00
      EU: 1000,00 (*Group separator is missing*)
      

      While debugging the code, I found that FastDecimalFormat does indeed format the number correctly, but somehow the spaces are removed from the final output during the rendering process.

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            aatelfer Alrick Telfer
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: