0

Hi I am trying to wrap the long word like email within the cell but am unable to do the same, I have tried multiple options like wrap-option="wrap", hyphenate="true" but no luck. Could anyone please help with the same?wrap_email

                           <fo:block font-size="9pt" margin-bottom="12pt">
                             #if($!{email})
                             ${email.toUpperCase()}
                             #else
                             ${displayUid.toUpperCase()}
                             #end
                          </fo:block>
Tony Graham
  • 7,306
  • 13
  • 20
  • The question is tagged with both 'apache-fop' and 'antenna-house'. Are you using FOP or AH Formatter? AH Formatter has 'axf:word-break' (see https://www.antenna.co.jp/AHF/help/en/ahf-ext.html#axf.word-break) and 'axf:word-wrap' (see https://www.antenna.co.jp/AHF/help/en/ahf-ext.html#axf.word-wrap) extensions that could help but aren't available in FOP. – Tony Graham Feb 07 '22 at 09:38
  • I am using FOP, in FOP do we have any tag to wrap the long text? – Vivek Patel Feb 07 '22 at 11:18
  • 1
    See these previous questions: * https://stackoverflow.com/questions/4350788/how-to-force-wrap-on-table-entries * https://stackoverflow.com/questions/36810691/force-line-break-after-string-length – Tony Graham Feb 07 '22 at 12:21
  • 1
    The proper way to do this is to insert zero-width break spaces at your *chosen* break points. Especially for email addresses. You need to avoid confusion with say an email that contains a "." .... what if the formatter broke that after the "." and the email was like Apache.Fop@apache.org. If the "Apache." is orphaned at the end of a line, the user may interpret as the end of a sentence and think the email is "Fop@apache.org" – Kevin Brown Feb 07 '22 at 18:12
  • I don't have any breakpoint, just want to wrap the long text within the cell. Which is going out of the defined cell. – Vivek Patel Feb 08 '22 at 09:49

0 Answers0