I have a QSqlTableModel with a QTableView I use to display the model's item.
I set the header of the table view with:
model->setHeaderData(1, Qt::Horizontal, tr("Marca"),Qt:: DisplayRole);
model->setHeaderData(1, Qt::Horizontal, tr("Marca"),Qt:: DisplayRole);
To copy to clipboard, switch view to plain text mode
Now, suppose I wanna put some fancy things in the header, for example a greek symbol.
I know that in html I can do "γ", but this does not work if I put, let's say,
model->setHeaderData(1, Qt::Horizontal, tr("<p>γ</p>"),Qt:: DisplayRole);
model->setHeaderData(1, Qt::Horizontal, tr("<p>γ</p>"),Qt:: DisplayRole);
To copy to clipboard, switch view to plain text mode
How can I do it?
regards
Bookmarks