3 Replies Latest reply on Feb 5, 2008 2:56 PM by Mathieu Le Cain

    PDF generation : horizontalAlignment does not work

    Mathieu Le Cain Newbie

      Hi,

      I try to format a table in a PDF export. The problem is that the alignment parameters are not applied when the table become a bit complex...

      here is a sample of code that doesn't work :

      <p:table columns="2" widths="1 1" widthPercentage="50" horizontalAlignment="right" spacingAfter="0">
       <p:cell> <p:font family="HELVETICA" size="10">#{msgExportPDF.totalHT}</p:font></p:cell>
       <p:cell> <p:font style="bold" family="HELVETICA" size="10"><p:text value="#{exportPDF.montantHT}"> <f:convertNumber type="currency" currencySymbol="#{msgExportPDF.euro}" maxFractionDigits="2" minFractionDigits="2"/></p:text></p:font></p:cell>
       <p:cell> <p:font family="HELVETICA" size="10">#{msgExportPDF.tva}#{factureHome.instance.tauxTva.tva} #{msgExportPDF.pourcent}</p:font></p:cell>
       <p:cell horizontalAlignment="right" verticalAlignment="center"> <p:font style="bold" family="HELVETICA" size="10"><p:text value="#{exportPDF.tva}"> <f:convertNumber type="currency" currencySymbol="#{msgExportPDF.euro}" maxFractionDigits="2" minFractionDigits="2"/> </p:text></p:font></p:cell>
       <p:cell grayFill="0.8f" alignment="right"> <p:font family="HELVETICA" size="10">#{msgExportPDF.totalTTC}</p:font></p:cell>
       <p:cell minimumHeight="20" grayFill="0.8f" horizontalAlignment="right"> <p:font style="bold" family="HELVETICA" size="10"><p:text value="#{exportPDF.totalTTC}"> <f:convertNumber type="currency" currencySymbol="#{msgExportPDF.euro}" maxFractionDigits="2" minFractionDigits="2"/> </p:text></p:font></p:cell>
       </p:table>
      


      I've read that there still were some problems with seam PDF generation. Is it a bug (how many time it takes to solve it)? Is my table wrong ? Is there some parameters to set elsewhere ?

      I've succeed to make it work with a very simple table (no other formatting parametters...)

      Thanks !