if I use <str:wordWrap width="15" delimiter="<BR>">1234567890123456789012345</str:wordWrap> I get the following output: 123456<BR>789012<BR>345678<BR>901234<BR>5 It looks like it calculates the delimiter length (10 characters in this case) and adds it to the length of the string to be split to compare to the width+1. I guess, this is not an expected behavior. It should treat the delimiter out of calculations and apply width to the string itself.
Vladyslav, This tag definition states that: this involves formatting a long String to fit within a certain character width of page. So, if we don't take the delimiter's length into account, the chunks won't fit into that width. On the other hand, it also says that: A delimiter may be passed in to put at the end of each line. In other words, the current definition is dubious about where the delimiter should be include. So, I will fix this bug including a new attribute for the tag: delimiterInside - flag indicating if the delimiter should be included in chunk before length reaches width. Default is true.
Fixed (and new version available through nightly build)