Diffstat (limited to 'inputmethods/pickboard/pickboard.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | inputmethods/pickboard/pickboard.cpp | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/inputmethods/pickboard/pickboard.cpp b/inputmethods/pickboard/pickboard.cpp index 087144e..1611cb0 100644 --- a/inputmethods/pickboard/pickboard.cpp +++ b/inputmethods/pickboard/pickboard.cpp | |||
@@ -1,16 +1,16 @@ | |||
1 | /********************************************************************** | 1 | /********************************************************************** |
2 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. | 2 | ** Copyright (C) 2000-2002 Trolltech AS. All rights reserved. |
3 | ** | 3 | ** |
4 | ** This file is part of Qtopia Environment. | 4 | ** This file is part of the Qtopia Environment. |
5 | ** | 5 | ** |
6 | ** This file may be distributed and/or modified under the terms of the | 6 | ** This file may be distributed and/or modified under the terms of the |
7 | ** GNU General Public License version 2 as published by the Free Software | 7 | ** GNU General Public License version 2 as published by the Free Software |
8 | ** Foundation and appearing in the file LICENSE.GPL included in the | 8 | ** Foundation and appearing in the file LICENSE.GPL included in the |
9 | ** packaging of this file. | 9 | ** packaging of this file. |
10 | ** | 10 | ** |
11 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 11 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE |
12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 12 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
13 | ** | 13 | ** |
14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | 14 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. |
15 | ** | 15 | ** |
16 | ** Contact info@trolltech.com if any conditions of this licensing are | 16 | ** Contact info@trolltech.com if any conditions of this licensing are |
@@ -25,25 +25,43 @@ | |||
25 | 25 | ||
26 | #include <qpainter.h> | 26 | #include <qpainter.h> |
27 | #include <qlist.h> | 27 | #include <qlist.h> |
28 | #include <qbitmap.h> | 28 | #include <qbitmap.h> |
29 | #include <qlayout.h> | 29 | #include <qlayout.h> |
30 | #include <qvbox.h> | 30 | #include <qvbox.h> |
31 | #include <qdialog.h> | 31 | #include <qdialog.h> |
32 | #include <qscrollview.h> | 32 | #include <qscrollview.h> |
33 | #include <qpopupmenu.h> | 33 | #include <qpopupmenu.h> |
34 | #include <qhbuttongroup.h> | 34 | #include <qhbuttongroup.h> |
35 | #include <qpushbutton.h> | 35 | #include <qpushbutton.h> |
36 | #include <qmessagebox.h> | 36 | #include <qmessagebox.h> |
37 | #ifdef QWS | ||
37 | #include <qwindowsystem_qws.h> | 38 | #include <qwindowsystem_qws.h> |
39 | #endif | ||
40 | |||
41 | /*! \class Pickboard | ||
42 | \brief The Pickboard class provides an input method | ||
43 | based on a virtual keyboard combined with word-completion. | ||
44 | |||
45 | This version of Pickboard is Dual Licensed Software. However, for you to be | ||
46 | able to license the technology to others, you may require a T9(R) Text | ||
47 | Input license from Tegic Communications Corporation. More information can | ||
48 | be found at http://www.t9.com/. | ||
49 | |||
50 | \legalese | ||
51 | This version of Pickboard is Dual Licensed Software. However, for you to be | ||
52 | able to license the technology to others, you may require a T9(R) Text | ||
53 | Input license from Tegic Communications Corporation. More information can | ||
54 | be found at http://www.t9.com/. | ||
55 | */ | ||
38 | 56 | ||
39 | /* XPM */ | 57 | /* XPM */ |
40 | static const char * const menu_xpm[]={ | 58 | static const char * const menu_xpm[]={ |
41 | "9 9 2 1", | 59 | "9 9 2 1", |
42 | "a c #000000", | 60 | "a c #000000", |
43 | ". c None", | 61 | ". c None", |
44 | ".........", | 62 | ".........", |
45 | ".........", | 63 | ".........", |
46 | ".........", | 64 | ".........", |
47 | "....a....", | 65 | "....a....", |
48 | "...aaa...", | 66 | "...aaa...", |
49 | "..aaaaa..", | 67 | "..aaaaa..", |
@@ -65,25 +83,28 @@ public: | |||
65 | parent,SIGNAL(key(ushort,ushort,ushort,bool,bool))); | 83 | parent,SIGNAL(key(ushort,ushort,ushort,bool,bool))); |
66 | } | 84 | } |
67 | 85 | ||
68 | PickboardPicks* picks; | 86 | PickboardPicks* picks; |
69 | QPushButton* menu; | 87 | QPushButton* menu; |
70 | }; | 88 | }; |
71 | 89 | ||
72 | Pickboard::Pickboard(QWidget* parent, const char* name, WFlags f) : | 90 | Pickboard::Pickboard(QWidget* parent, const char* name, WFlags f) : |
73 | QFrame(parent,name,f) | 91 | QFrame(parent,name,f) |
74 | { | 92 | { |
75 | (new QHBoxLayout(this))->setAutoAdd(TRUE); | 93 | (new QHBoxLayout(this))->setAutoAdd(TRUE); |
76 | d = new PickboardPrivate(this); | 94 | d = new PickboardPrivate(this); |
95 | // under Win32 we may not have smallsmooth font | ||
96 | #ifndef Q_OS_WIN32 | ||
77 | setFont( QFont( "smallsmooth", 9 ) ); | 97 | setFont( QFont( "smallsmooth", 9 ) ); |
98 | #endif | ||
78 | } | 99 | } |
79 | 100 | ||
80 | Pickboard::~Pickboard() | 101 | Pickboard::~Pickboard() |
81 | { | 102 | { |
82 | delete d; | 103 | delete d; |
83 | } | 104 | } |
84 | 105 | ||
85 | void Pickboard::resetState() | 106 | void Pickboard::resetState() |
86 | { | 107 | { |
87 | d->picks->resetState(); | 108 | d->picks->resetState(); |
88 | } | 109 | } |
89 | 110 | ||