author | sandman <sandman> | 2002-09-25 23:12:14 (UTC) |
---|---|---|
committer | sandman <sandman> | 2002-09-25 23:12:14 (UTC) |
commit | 489bc02ad26767dc45b81bf122a09ef55ac20249 (patch) (side-by-side diff) | |
tree | b7c26f8af38e9b0146179a1618a8fdf2504490fe /libopie/ofontselector.h | |
parent | 0c6ce9f1600bf1efb7736f87fd14dd8215db851f (diff) | |
download | opie-489bc02ad26767dc45b81bf122a09ef55ac20249.zip opie-489bc02ad26767dc45b81bf122a09ef55ac20249.tar.gz opie-489bc02ad26767dc45b81bf122a09ef55ac20249.tar.bz2 |
some fixes to make ofontselector more robust, if you specify invalid font
families/styles/sizes
-rw-r--r-- | libopie/ofontselector.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libopie/ofontselector.h b/libopie/ofontselector.h index 9227e48..2011e43 100644 --- a/libopie/ofontselector.h +++ b/libopie/ofontselector.h @@ -26,48 +26,50 @@ */ #ifndef __OPIE_FONTSELECTOR_H__ #define __OPIE_FONTSELECTOR_H__ #include <qwidget.h> #include <qpe/fontdatabase.h> class QComboBox; class QListBox; class QFont; class OFontSelector : public QWidget { Q_OBJECT public: OFontSelector ( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); virtual ~OFontSelector ( ); bool selectedFont ( QString &family, QString &style, int &size ); bool selectedFont ( QString &family, QString &style, int &size, QString &charset ); + QFont selectedFont ( ); + bool setSelectedFont ( const QString &family, const QString &style, int size, const QString &charset = 0 ); QString fontFamily ( ) const; QString fontStyle ( ) const; int fontSize ( ) const; QString fontCharSet ( ) const; signals: void fontSelected ( const QFont & ); protected slots: virtual void fontFamilyClicked ( int ); virtual void fontStyleClicked ( int ); virtual void fontSizeClicked ( int ); private: void loadFonts ( QListBox * ); void changeFont ( ); private: QListBox * m_font_family_list; QComboBox * m_font_style_list; QComboBox * m_font_size_list; |