You could use QDataStream::device() and cast it to QFile I guess...
You could use QDataStream::device() and cast it to QFile I guess...
yes, did`t see that. thanks.
Still wired that QTextStream has flush() and QDataStream doesnt...
After a brief look at the sources: QTextStream buffers the content in a QString and at the end (or when calling flush()) it writes the content to the device. This is to take care of encodeing etc. QDataSream on the other hand directly writes to the device hence no flush() is needed.
thanks for the answer!
Will have a look at the sources myself next time.![]()
Bookmarks