OpenDocument text (Flat XML) .fodt

Fridrich Strba fridrich.strba at graduateinstitute.ch
Fri Jan 3 08:45:39 PST 2014


Hello,

On 02/01/14 16:04, John Robson wrote:
> Thank you, but not solve, the lines continue large.
> But, this is not a bug, is just a good feature.
> As I said before, break lines in smaller columns will improve the
> versioning results when you work in a collaborative way.

The Flat ODF filter uses DocumentHandlerAdapter from
sax/tools/documenthandleradapter.hxx
What you need basically is to modify somehow the characters method so
that it iterates through the aChars and spit a serie of calls of
m_handler->characters split at the word boundaries. Something like
iterating through the string and keep the position of the last
white-space and if you are over the position 80 pass a sub-string until
the last white-space found before the position 80. And do that until the
string is passed completely.

Not sure what kind of performance penalty would this create. But one
could do that only if pretty printing is selected.

Hope the pointers are good enough

F.

-- 
Please avoid sending me Word, Excel or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 263 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20140103/907a8163/attachment.pgp>


More information about the LibreOffice mailing list