summaryrefslogtreecommitdiff
path: root/inputmethods
Unidiff
Diffstat (limited to 'inputmethods') (more/less context) (ignore whitespace changes)
-rw-r--r--inputmethods/multikey/keyboard.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/inputmethods/multikey/keyboard.cpp b/inputmethods/multikey/keyboard.cpp
index c3ee8f3..92ea896 100644
--- a/inputmethods/multikey/keyboard.cpp
+++ b/inputmethods/multikey/keyboard.cpp
@@ -191,13 +191,13 @@ void Keyboard::drawKeyboard(QPainter &p, int row, int col)
191 p.drawText(x, y, 191 p.drawText(x, y,
192 defaultKeyWidth * keyWidth + 3, keyHeight, 192 defaultKeyWidth * keyWidth + 3, keyHeight,
193 AlignCenter, (QChar)c); 193 AlignCenter, (QChar)c);
194 } 194 }
195 else 195 else
196 // center the image in the middle of the key 196 // center the image in the middle of the key
197 p.drawImage( x + (defaultKeyWidth * keyWidth - pix->width())/2, 197 p.drawImage( x + (defaultKeyWidth * keyWidth - pix->width())/2 + 1,
198 y + (keyHeight - pix->height())/2 + 1, 198 y + (keyHeight - pix->height())/2 + 1,
199 *pix ); 199 *pix );
200 200
201 // this fixes the problem that the very right end of the board's vertical line 201 // this fixes the problem that the very right end of the board's vertical line
202 // gets painted over, because it's one pixel shorter than all other keys 202 // gets painted over, because it's one pixel shorter than all other keys
203 p.setPen(keycolor_lines); 203 p.setPen(keycolor_lines);
@@ -241,13 +241,13 @@ void Keyboard::drawKeyboard(QPainter &p, int row, int col)
241 keyWidthPix + 3, keyHeight, 241 keyWidthPix + 3, keyHeight,
242 AlignCenter, (QChar)c); 242 AlignCenter, (QChar)c);
243 } 243 }
244 else { 244 else {
245 // center the image in the middle of the key 245 // center the image in the middle of the key
246 pix->setColor(1, textcolor.rgb()); 246 pix->setColor(1, textcolor.rgb());
247 p.drawImage( x + (keyWidthPix - pix->width())/2, 247 p.drawImage( x + (keyWidthPix - pix->width())/2 + 1,
248 y + (keyHeight - pix->height())/2 + 1, 248 y + (keyHeight - pix->height())/2 + 1,
249 QImage(*pix) ); 249 QImage(*pix) );
250 } 250 }
251 251
252 p.setPen(keycolor_lines); 252 p.setPen(keycolor_lines);
253 p.drawLine(x, y, x, y + keyHeight); 253 p.drawLine(x, y, x, y + keyHeight);