author | alwin <alwin> | 2005-02-28 09:40:30 (UTC) |
---|---|---|
committer | alwin <alwin> | 2005-02-28 09:40:30 (UTC) |
commit | 2b64a84d39eeed5681d0ee5068c7d11a01527750 (patch) (unidiff) | |
tree | c8693340dbc5ef5e2f9afa90b690829ddff2c4bd /noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp | |
parent | 61fa699140c5efbb6ba0bf2a62f7e8fbf62976be (diff) | |
download | opie-2b64a84d39eeed5681d0ee5068c7d11a01527750.zip opie-2b64a84d39eeed5681d0ee5068c7d11a01527750.tar.gz opie-2b64a84d39eeed5681d0ee5068c7d11a01527750.tar.bz2 |
other keymapping tool - not working this moment, I have to check it out
- the reason is that the config file is somewhat easier to understand than
from zkbapplet and has a nice config tool.
Please don't put it into any repositories this moment.
Diffstat (limited to 'noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp | 162 |
1 files changed, 162 insertions, 0 deletions
diff --git a/noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp b/noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp new file mode 100644 index 0000000..16841f1 --- a/dev/null +++ b/noncore/applets/keyhelper/keyhelperconf/KHCWidgetBase.cpp | |||
@@ -0,0 +1,162 @@ | |||
1 | /**************************************************************************** | ||
2 | ** Form implementation generated from reading ui file 'KHCWidgetBase.ui' | ||
3 | ** | ||
4 | ** Created: Mon Feb 28 09:58:22 2005 | ||
5 | ** by: The User Interface Compiler (uic) | ||
6 | ** | ||
7 | ** WARNING! All changes made in this file will be lost! | ||
8 | ****************************************************************************/ | ||
9 | #include "KHCWidgetBase.h" | ||
10 | |||
11 | #include <qcheckbox.h> | ||
12 | #include <qlabel.h> | ||
13 | #include <qlineedit.h> | ||
14 | #include <qmultilineedit.h> | ||
15 | #include <qpushbutton.h> | ||
16 | #include <qlayout.h> | ||
17 | #include <qvariant.h> | ||
18 | #include <qtooltip.h> | ||
19 | #include <qwhatsthis.h> | ||
20 | |||
21 | /* | ||
22 | * Constructs a KHCWidgetBase which is a child of 'parent', with the | ||
23 | * name 'name' and widget flags set to 'f' | ||
24 | */ | ||
25 | KHCWidgetBase::KHCWidgetBase( QWidget* parent, const char* name, WFlags fl ) | ||
26 | : QWidget( parent, name, fl ) | ||
27 | { | ||
28 | if ( !name ) | ||
29 | setName( "KHCWidgetBase" ); | ||
30 | resize( 431, 388 ); | ||
31 | setCaption( tr( "KeyHelperConf" ) ); | ||
32 | |||
33 | btnCtrl = new QPushButton( this, "btnCtrl" ); | ||
34 | btnCtrl->setGeometry( QRect( 280, 150, 121, 31 ) ); | ||
35 | btnCtrl->setText( tr( "Disable" ) ); | ||
36 | |||
37 | btnGen = new QPushButton( this, "btnGen" ); | ||
38 | btnGen->setGeometry( QRect( 10, 150, 110, 31 ) ); | ||
39 | btnGen->setText( tr( "Generate" ) ); | ||
40 | |||
41 | btnCopy = new QPushButton( this, "btnCopy" ); | ||
42 | btnCopy->setGeometry( QRect( 140, 150, 121, 31 ) ); | ||
43 | btnCopy->setText( tr( "Copy" ) ); | ||
44 | |||
45 | lblOrgK = new QLabel( this, "lblOrgK" ); | ||
46 | lblOrgK->setGeometry( QRect( 20, 50, 50, 20 ) ); | ||
47 | lblOrgK->setText( tr( "K" ) ); | ||
48 | |||
49 | lblMapK = new QLabel( this, "lblMapK" ); | ||
50 | lblMapK->setGeometry( QRect( 20, 120, 20, 20 ) ); | ||
51 | lblMapK->setText( tr( "K" ) ); | ||
52 | |||
53 | lblMapKeycode = new QLabel( this, "lblMapKeycode" ); | ||
54 | lblMapKeycode->setGeometry( QRect( 40, 120, 80, 21 ) ); | ||
55 | lblMapKeycode->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, lblMapKeycode->sizePolicy().hasHeightForWidth() ) ); | ||
56 | lblMapKeycode->setFrameShape( QLabel::Panel ); | ||
57 | lblMapKeycode->setFrameShadow( QLabel::Sunken ); | ||
58 | lblMapKeycode->setText( tr( "keycode" ) ); | ||
59 | |||
60 | txtMapKey = new QLineEdit( this, "txtMapKey" ); | ||
61 | txtMapKey->setGeometry( QRect( 200, 80, 200, 22 ) ); | ||
62 | |||
63 | txtOrgKey = new QLineEdit( this, "txtOrgKey" ); | ||
64 | txtOrgKey->setGeometry( QRect( 190, 10, 200, 22 ) ); | ||
65 | |||
66 | lblOriginal = new QLabel( this, "lblOriginal" ); | ||
67 | lblOriginal->setGeometry( QRect( 10, 10, 120, 31 ) ); | ||
68 | lblOriginal->setFrameShape( QLabel::Box ); | ||
69 | lblOriginal->setFrameShadow( QLabel::Raised ); | ||
70 | lblOriginal->setText( tr( "Original Key" ) ); | ||
71 | |||
72 | lblMapping = new QLabel( this, "lblMapping" ); | ||
73 | lblMapping->setGeometry( QRect( 10, 80, 120, 21 ) ); | ||
74 | lblMapping->setFrameShape( QLabel::Box ); | ||
75 | lblMapping->setFrameShadow( QLabel::Raised ); | ||
76 | lblMapping->setText( tr( "Mapping Key" ) ); | ||
77 | |||
78 | mleDefine = new QMultiLineEdit( this, "mleDefine" ); | ||
79 | mleDefine->setGeometry( QRect( 10, 200, 391, 110 ) ); | ||
80 | mleDefine->setReadOnly( TRUE ); | ||
81 | |||
82 | lblOrgKeycode = new QLabel( this, "lblOrgKeycode" ); | ||
83 | lblOrgKeycode->setGeometry( QRect( 50, 50, 70, 21 ) ); | ||
84 | lblOrgKeycode->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, lblOrgKeycode->sizePolicy().hasHeightForWidth() ) ); | ||
85 | lblOrgKeycode->setFrameShape( QLabel::Panel ); | ||
86 | lblOrgKeycode->setFrameShadow( QLabel::Sunken ); | ||
87 | lblOrgKeycode->setText( tr( "keycode" ) ); | ||
88 | |||
89 | lblOrgU = new QLabel( this, "lblOrgU" ); | ||
90 | lblOrgU->setGeometry( QRect( 130, 50, 20, 21 ) ); | ||
91 | lblOrgU->setText( tr( "U" ) ); | ||
92 | |||
93 | lblOrgUnicode = new QLabel( this, "lblOrgUnicode" ); | ||
94 | lblOrgUnicode->setGeometry( QRect( 150, 50, 80, 21 ) ); | ||
95 | lblOrgUnicode->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, lblOrgUnicode->sizePolicy().hasHeightForWidth() ) ); | ||
96 | lblOrgUnicode->setFrameShape( QLabel::Panel ); | ||
97 | lblOrgUnicode->setFrameShadow( QLabel::Sunken ); | ||
98 | lblOrgUnicode->setText( tr( "unicode" ) ); | ||
99 | |||
100 | lblMapU = new QLabel( this, "lblMapU" ); | ||
101 | lblMapU->setGeometry( QRect( 130, 120, 20, 21 ) ); | ||
102 | lblMapU->setText( tr( "U" ) ); | ||
103 | |||
104 | lblMapUnicode = new QLabel( this, "lblMapUnicode" ); | ||
105 | lblMapUnicode->setGeometry( QRect( 150, 120, 80, 21 ) ); | ||
106 | lblMapUnicode->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)1, lblMapUnicode->sizePolicy().hasHeightForWidth() ) ); | ||
107 | lblMapUnicode->setFrameShape( QLabel::Panel ); | ||
108 | lblMapUnicode->setFrameShadow( QLabel::Sunken ); | ||
109 | lblMapUnicode->setText( tr( "unicode" ) ); | ||
110 | |||
111 | chkMapShift = new QCheckBox( this, "chkMapShift" ); | ||
112 | chkMapShift->setGeometry( QRect( 260, 120, 33, 19 ) ); | ||
113 | chkMapShift->setText( tr( "S" ) ); | ||
114 | chkMapShift->setAutoResize( TRUE ); | ||
115 | |||
116 | chkMapCtrl = new QCheckBox( this, "chkMapCtrl" ); | ||
117 | chkMapCtrl->setGeometry( QRect( 310, 120, 34, 19 ) ); | ||
118 | chkMapCtrl->setText( tr( "C" ) ); | ||
119 | chkMapCtrl->setAutoResize( TRUE ); | ||
120 | |||
121 | chkMapAlt = new QCheckBox( this, "chkMapAlt" ); | ||
122 | chkMapAlt->setGeometry( QRect( 360, 120, 34, 19 ) ); | ||
123 | chkMapAlt->setText( tr( "A" ) ); | ||
124 | chkMapAlt->setAutoResize( TRUE ); | ||
125 | |||
126 | chkOrgShift = new QCheckBox( this, "chkOrgShift" ); | ||
127 | chkOrgShift->setGeometry( QRect( 250, 50, 33, 19 ) ); | ||
128 | chkOrgShift->setText( tr( "S" ) ); | ||
129 | chkOrgShift->setAutoResize( TRUE ); | ||
130 | |||
131 | chkOrgCtrl = new QCheckBox( this, "chkOrgCtrl" ); | ||
132 | chkOrgCtrl->setGeometry( QRect( 300, 50, 34, 19 ) ); | ||
133 | chkOrgCtrl->setText( tr( "C" ) ); | ||
134 | chkOrgCtrl->setAutoResize( TRUE ); | ||
135 | |||
136 | chkOrgAlt = new QCheckBox( this, "chkOrgAlt" ); | ||
137 | chkOrgAlt->setGeometry( QRect( 350, 50, 34, 19 ) ); | ||
138 | chkOrgAlt->setText( tr( "A" ) ); | ||
139 | chkOrgAlt->setAutoResize( TRUE ); | ||
140 | |||
141 | // tab order | ||
142 | setTabOrder( txtOrgKey, chkOrgShift ); | ||
143 | setTabOrder( chkOrgShift, chkOrgCtrl ); | ||
144 | setTabOrder( chkOrgCtrl, chkOrgAlt ); | ||
145 | setTabOrder( chkOrgAlt, txtMapKey ); | ||
146 | setTabOrder( txtMapKey, chkMapShift ); | ||
147 | setTabOrder( chkMapShift, chkMapCtrl ); | ||
148 | setTabOrder( chkMapCtrl, chkMapAlt ); | ||
149 | setTabOrder( chkMapAlt, btnGen ); | ||
150 | setTabOrder( btnGen, btnCopy ); | ||
151 | setTabOrder( btnCopy, btnCtrl ); | ||
152 | setTabOrder( btnCtrl, mleDefine ); | ||
153 | } | ||
154 | |||
155 | /* | ||
156 | * Destroys the object and frees any allocated resources | ||
157 | */ | ||
158 | KHCWidgetBase::~KHCWidgetBase() | ||
159 | { | ||
160 | // no need to delete child widgets, Qt does it all for us | ||
161 | } | ||
162 | |||