sizeHint() is a function of a widget which returns how big the widget is.
Example:
{
// Do some checks with the text document so you know the returned value is correct. If you use a pointer for example, check if it exists. etc...
return myDoubleLineTextDocument.sizeHint();
}
QSize AlertDelegate::sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const
{
// Do some checks with the text document so you know the returned value is correct. If you use a pointer for example, check if it exists. etc...
return myDoubleLineTextDocument.sizeHint();
}
To copy to clipboard, switch view to plain text mode
You will need to define your textdocument more accessible in your delegate.
Bookmarks