Details
-
Bug
-
Resolution: Done
-
Not Evaluated
-
5.4.1
-
None
Description
In java, python and ruby, as I know, there is a "ToString" method class which allow debugging easily..
For example , you can print an instance :
class Car
def _toString_():
return "car"
Car myCar
print(myCar).
It would be greate to have the same feature for QObject and use it with qDebug(). Actually, overload the QDebug class operator << is not cute.
class Car : public QObject
{
QString toString()
}
qDebug()<<car;