summaryrefslogtreecommitdiff
path: root/inputmethods/jumpx/keyboard.cpp
Side-by-side diff
Diffstat (limited to 'inputmethods/jumpx/keyboard.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--inputmethods/jumpx/keyboard.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/inputmethods/jumpx/keyboard.cpp b/inputmethods/jumpx/keyboard.cpp
index 0b8fc14..0cfb4be 100644
--- a/inputmethods/jumpx/keyboard.cpp
+++ b/inputmethods/jumpx/keyboard.cpp
@@ -95,64 +95,65 @@ static const uchar *const specialMapShift[] = {
(const uchar *const)"#?",
(const uchar *const)";\"",
(const uchar *const)":|",
(const uchar *const)"\\&",
};
static const uchar *const specialMapParen[] = {
(const uchar *const)"()",
(const uchar *const)"[]",
(const uchar *const)"{}",
(const uchar *const)"<>",
(const uchar *const)"@~",
};
static const uchar *const num2Map = (const uchar *const)"67890";
static const mapElement mod2Map[] = {
{ Qt::Key_Backspace, 8 },
{ Qt::Key_Delete, 0 },
{ Qt::Key_Return, 13 },
{ Qt::Key_Shift, 0 },
{ myParenID, 0 },
};
static const int cursorMap[][2] = {
{ Qt::Key_Home, Qt::Key_PageUp },
{ Qt::Key_End, Qt::Key_PageDown },
{ Qt::Key_Up, Qt::Key_Up },
{ Qt::Key_Left, Qt::Key_Right },
{ Qt::Key_Down, Qt::Key_Down },
};
+using namespace JumpX;
Keyboard::Keyboard(QWidget* parent, const char* name, WFlags f) :
QFrame(parent, name, f),
shift(0), paren(0), ctrl(0), alt(0),
pressedKeyUnicode(0), pressedKeyQcode(0), pressedMod(0),
isnoncont(false),
slideKeyUnicodeH(0), slideKeyQcodeH(0), slideKeyUnicodeV(0), slideKeyQcodeV(0),
enableMouseTracking(false), slidePix(NULL), slidePixH(NULL), slidePixV(NULL),
releasedPix(NULL), pressedPix(NULL)
{
//setPalette(QPalette(QColor(240,240,230))); // Beige!
releasedPlain = releasedShift = releasedParen = Resource::loadPixmap("jumpx/released");
pressedPlain = pressedShift = pressedParen = Resource::loadPixmap("jumpx/pressed");
pressedDigit = Resource::loadPixmap("jumpx/pressed");
QPixmap tmp;
tmp = Resource::loadPixmap("jumpx/releasedShift");
bitBlt(&releasedShift, letterx1, 0, &tmp);
tmp = Resource::loadPixmap("jumpx/releasedParen");
bitBlt(&releasedParen, specialx1, 0, &tmp);
tmp = Resource::loadPixmap("jumpx/pressedShift");
bitBlt(&pressedShift, letterx1, 0, &tmp);
tmp = Resource::loadPixmap("jumpx/pressedParen");
bitBlt(&pressedParen, specialx1, 0, &tmp);
tmp = Resource::loadPixmap("jumpx/pressedDigit");
bitBlt(&pressedDigit, specialx1, 0, &tmp);