forked from blue/squawk
some thoughts about fonts, lastInteraction and label into keyDelegate
This commit is contained in:
parent
2aed8a1209
commit
15fb4bbd62
15 changed files with 166 additions and 171 deletions
|
@ -53,7 +53,6 @@ public:
|
|||
QSize sizeHint(const QStyleOptionViewItem& option, const QModelIndex& index) const override;
|
||||
//void setModelData(QWidget * editor, QAbstractItemModel * model, const QModelIndex & index) const override;
|
||||
|
||||
void initializeFonts(const QFont& font);
|
||||
bool editorEvent(QEvent * event, QAbstractItemModel * model, const QStyleOptionViewItem & option, const QModelIndex & index) override;
|
||||
void endClearWidgets();
|
||||
void beginClearWidgets();
|
||||
|
@ -94,6 +93,9 @@ protected:
|
|||
|
||||
protected slots:
|
||||
void onButtonPushed() const;
|
||||
|
||||
private:
|
||||
static void initializeFonts();
|
||||
|
||||
private:
|
||||
class FeedButton : public QPushButton {
|
||||
|
@ -101,12 +103,13 @@ private:
|
|||
QString messageId;
|
||||
};
|
||||
|
||||
QFont bodyFont;
|
||||
QFont nickFont;
|
||||
QFont dateFont;
|
||||
static bool fontsInitialized;
|
||||
static QFont bodyFont;
|
||||
static QFont nickFont;
|
||||
static QFont dateFont;
|
||||
QTextDocument* bodyRenderer;
|
||||
QFontMetrics nickMetrics;
|
||||
QFontMetrics dateMetrics;
|
||||
static QFontMetrics nickMetrics;
|
||||
static QFontMetrics dateMetrics;
|
||||
|
||||
int buttonHeight;
|
||||
int buttonWidth;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue