|
Krita Source Code Documentation
|
The KisFontComboBoxes class This is a little widget with two comboboxes. One is for the font family, and the other for the style, using the power of QFontDataBase. This allows us to limit the amount of fonts visible in the fonts drop down, as that can be a quite intense number when you have several 'style complete' fonts. More...
#include <kis_font_family_combo_box.h>
Inheritance diagram for KisFontComboBoxes:Signals | |
| void | fontChanged (QString) |
Public Member Functions | |
| QString | currentFamily () const |
| QFont | currentFont (int pointSize=10) const |
| currentFont the current QFont from both family and style combinations | |
| QString | currentStyle () const |
| KisFontComboBoxes (QWidget *parent=0) | |
| void | refillComboBox (QVector< QFontDatabase::WritingSystem > writingSystems=QVector< QFontDatabase::WritingSystem >()) |
| void | setCurrentFamily (const QString family) |
| void | setCurrentFont (QFont font) |
| setCurrentFont sets the style and font comboboxes appropriately. | |
| void | setCurrentStyle (QString style) |
| void | setInitialized () |
Private Slots | |
| void | fontChange () |
| void | fontFamilyChanged () |
Private Attributes | |
| QComboBox * | m_family |
| QComboBox * | m_styles |
The KisFontComboBoxes class This is a little widget with two comboboxes. One is for the font family, and the other for the style, using the power of QFontDataBase. This allows us to limit the amount of fonts visible in the fonts drop down, as that can be a quite intense number when you have several 'style complete' fonts.
Definition at line 25 of file kis_font_family_combo_box.h.
| KisFontComboBoxes::KisFontComboBoxes | ( | QWidget * | parent = 0 | ) |
Definition at line 201 of file kis_font_family_combo_box.cpp.
References connect(), fontChange(), fontFamilyChanged(), m_family, and m_styles.
| QString KisFontComboBoxes::currentFamily | ( | ) | const |
Definition at line 252 of file kis_font_family_combo_box.cpp.
References m_family.
| QFont KisFontComboBoxes::currentFont | ( | int | pointSize = 10 | ) | const |
currentFont the current QFont from both family and style combinations
| pointSize | as this widget has no idea about point size, input desired point size. |
Definition at line 262 of file kis_font_family_combo_box.cpp.
| QString KisFontComboBoxes::currentStyle | ( | ) | const |
Definition at line 257 of file kis_font_family_combo_box.cpp.
References m_styles.
|
privateslot |
Definition at line 312 of file kis_font_family_combo_box.cpp.
References currentFont(), and fontChanged().
|
signal |
|
privateslot |
Definition at line 273 of file kis_font_family_combo_box.cpp.
References m_family, m_styles, and KisFontFamilyComboBox::setTopFont().
| void KisFontComboBoxes::refillComboBox | ( | QVector< QFontDatabase::WritingSystem > | writingSystems = QVector<QFontDatabase::WritingSystem>() | ) |
Definition at line 267 of file kis_font_family_combo_box.cpp.
References m_family, and KisFontFamilyComboBox::refillComboBox().
| void KisFontComboBoxes::setCurrentFamily | ( | const QString | family | ) |
Definition at line 229 of file kis_font_family_combo_box.cpp.
References fontFamilyChanged(), and m_family.
| void KisFontComboBoxes::setCurrentFont | ( | QFont | font | ) |
setCurrentFont sets the style and font comboboxes appropriately.
| font | the QFont to set. |
Definition at line 223 of file kis_font_family_combo_box.cpp.
References setCurrentFamily(), and setCurrentStyle().
| void KisFontComboBoxes::setCurrentStyle | ( | QString | style | ) |
Definition at line 235 of file kis_font_family_combo_box.cpp.
References m_styles.
| void KisFontComboBoxes::setInitialized | ( | ) |
Definition at line 317 of file kis_font_family_combo_box.cpp.
References m_family, and KisFontFamilyComboBox::setInitialized().
|
private |
Definition at line 62 of file kis_font_family_combo_box.h.
|
private |
Definition at line 63 of file kis_font_family_combo_box.h.