frankly, I have no idea what you are after, and why you make it so complicated.
So far I have seen nothing in what you have posted, that qDebug() does not give you since you only output strings.
Its your job to convert what ever other types to strings, and then you can just feed the strings to qDebug().
You are over complicating a non existing problem (in my view).
Well, then put a line break where you need it!gives me :
123456
and I'd want
123
456
qDebug() will output any string you give it, so just create the string you want the way you want it.
Thats is true, qDebug() adds a line break after every srting, it not magic, just the way it was conceived.Perhaps this can hellp :
Cout needs to receive and endl because if not there is no line feed.
cout<<"hello"<<"how are you"<<endl;
But qDebug NOT :
qDebug()<<"hello"<<"how are you";
SO ..... what kind of magic is there in qDebug ?
As the qDebug() docs states:
With this syntax, the function returns a QDebug object that is configured to use the QtDebugMsg message type. It automatically puts a single space between each item, and outputs a newline at the end. It supports many C++ and Qt types.
Bookmarks