A Python object could be something entirely different than a QObject.
Maybe PyQt maps QVariant to soemthing called "object".
That creates a translated string.
A QString can be wrapped automatically into a QVariant, so the compiler can convert the QString into a QVariant when handling that line.
The example could have also used explicit QString or an int, etc.
I see.
In case you can't get setHeaderData() to work you could still consider deriving from QFileSystemModel and reimplementing headerData().
Cheers,
_
Bookmarks