View Single Post
Old 08-05-2020, 06:57 PM   #38
KevinH
Sigil Developer
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 8,948
Karma: 6361444
Join Date: Nov 2009
Device: many
Okay, I went the wrong way. QIODevice when set to Text will always write the platform appropriate line endings. We use a QTextStream with a QIODevice set to Text in our Utility:WriteUnicodeTextFile.

So on Windows, in order to make offsets that work internally to Qt, I must replace all \r\n with just \n before calling parse.

I still do not know if automatic line conversions are done when unpacking the zip (.epub) depending on platform. I will look to see how minizip and zlib handles that.

This is important for Checkpointing and diffs as well.
KevinH is offline   Reply With Quote