10 #include <QFontDialog>
19 : QPushButton(text, parent) {
23 void FontPushButton::onClicked() {
25 QFont f = QFontDialog::getFont(&ok, font());
29 int fontSize = this->font().pointSize();
30 f.setPointSize(fontSize);
33 setToolTip(f.family());
36 void FontPushButton::init() {
38 connect(
this, SIGNAL(clicked()), SLOT(onClicked()));