summaryrefslogtreecommitdiff
path: root/libopie/ofontselector.h
Unidiff
Diffstat (limited to 'libopie/ofontselector.h') (more/less context) (show whitespace changes)
-rw-r--r--libopie/ofontselector.h11
1 files changed, 3 insertions, 8 deletions
diff --git a/libopie/ofontselector.h b/libopie/ofontselector.h
index b3aa862..a9c8a72 100644
--- a/libopie/ofontselector.h
+++ b/libopie/ofontselector.h
@@ -9,74 +9,69 @@
9 - .   .-<_>     .<> Foundation; either version 2 of the License, 9 - .   .-<_>     .<> Foundation; either version 2 of the License,
10     ._= =}       : or (at your option) any later version. 10     ._= =}       : or (at your option) any later version.
11    .%`+i>       _;_. 11    .%`+i>       _;_.
12    .i_,=:_.      -<s. This library is distributed in the hope that 12    .i_,=:_.      -<s. This library is distributed in the hope that
13     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY; 13     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
14    : ..    .:,     . . . without even the implied warranty of 14    : ..    .:,     . . . without even the implied warranty of
15    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A 15    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
16  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU 16  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
17..}^=.=       =       ; Library General Public License for more 17..}^=.=       =       ; Library General Public License for more
18++=   -.     .`     .: details. 18++=   -.     .`     .: details.
19 :     =  ...= . :.=- 19 :     =  ...= . :.=-
20 -.   .:....=;==+<; You should have received a copy of the GNU 20 -.   .:....=;==+<; You should have received a copy of the GNU
21  -_. . .   )=.  = Library General Public License along with 21  -_. . .   )=.  = Library General Public License along with
22    --        :-=` this library; see the file COPYING.LIB. 22    --        :-=` this library; see the file COPYING.LIB.
23 If not, write to the Free Software Foundation, 23 If not, write to the Free Software Foundation,
24 Inc., 59 Temple Place - Suite 330, 24 Inc., 59 Temple Place - Suite 330,
25 Boston, MA 02111-1307, USA. 25 Boston, MA 02111-1307, USA.
26 26
27*/ 27*/
28 28
29#ifndef __OPIE_FONTSELECTOR_H__ 29#ifndef __OPIE_FONTSELECTOR_H__
30#define __OPIE_FONTSELECTOR_H__ 30#define __OPIE_FONTSELECTOR_H__
31 31
32#include <qwidget.h> 32#include <qwidget.h>
33#include <qpe/fontdatabase.h>
34 33
35class QComboBox;
36class QListBox; 34class QListBox;
37class QFont; 35class OFontSelectorPrivate;
36
38 37
39class OFontSelector : public QWidget 38class OFontSelector : public QWidget
40{ 39{
41 Q_OBJECT 40 Q_OBJECT
42 41
43public: 42public:
44 OFontSelector ( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); 43 OFontSelector ( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
45 virtual ~OFontSelector ( ); 44 virtual ~OFontSelector ( );
46 45
47 bool selectedFont ( QString &family, QString &style, int &size ); 46 bool selectedFont ( QString &family, QString &style, int &size );
48 bool selectedFont ( QString &family, QString &style, int &size, QString &charset ); 47 bool selectedFont ( QString &family, QString &style, int &size, QString &charset );
49 48
50 QFont selectedFont ( ); 49 QFont selectedFont ( );
51 50
52 bool setSelectedFont ( const QFont & ); 51 bool setSelectedFont ( const QFont & );
53 bool setSelectedFont ( const QString &family, const QString &style, int size, const QString &charset = 0 ); 52 bool setSelectedFont ( const QString &family, const QString &style, int size, const QString &charset = 0 );
54 53
55 QString fontFamily ( ) const; 54 QString fontFamily ( ) const;
56 QString fontStyle ( ) const; 55 QString fontStyle ( ) const;
57 int fontSize ( ) const; 56 int fontSize ( ) const;
58 QString fontCharSet ( ) const; 57 QString fontCharSet ( ) const;
59 58
60signals: 59signals:
61 void fontSelected ( const QFont & ); 60 void fontSelected ( const QFont & );
62 61
63protected slots: 62protected slots:
64 virtual void fontFamilyClicked ( int ); 63 virtual void fontFamilyClicked ( int );
65 virtual void fontStyleClicked ( int ); 64 virtual void fontStyleClicked ( int );
66 virtual void fontSizeClicked ( int ); 65 virtual void fontSizeClicked ( int );
67 66
68private: 67private:
69 void loadFonts ( QListBox * ); 68 void loadFonts ( QListBox * );
70 69
71 void changeFont ( ); 70 void changeFont ( );
72 71
73private: 72private:
74 QListBox * m_font_family_list; 73 OFontSelectorPrivate *d;
75 QComboBox * m_font_style_list;
76 QComboBox * m_font_size_list;
77
78 FontDatabase m_fdb;
79}; 74};
80 75
81#endif 76#endif
82 77