I filled my QtextStream textStream
object, already. When it does not end with an "}", I want to append one "}" in that case:
QString fullText = textStream.readAll();
if( !fullText.trimmed().endsWith("}") )
{
QString lastBracket("\n}");
textStream << lastBracket;
}
But after this, my TextStream is just "}" ? So the readAll flushes the TextStream ? How could I solve that elsewise?