[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    kdeedu/khangman/khangman
From:       Anne-Marie Mahfouf <annma () kde ! org>
Date:       2005-04-14 12:58:20
Message-ID: 20050414125820.10BCD5FA () office ! kde ! org
[Download RAW message or body]

CVS commit by annma: 

the sea theme painting does not flicker anymore and seems nearly perfect


  M +5 -6      khangmanview.cpp   1.112


--- kdeedu/khangman/khangman/khangmanview.cpp  #1.111:1.112
@@ -301,5 +301,4 @@ void KHangManView::paintHangman()
     QPainter paint;
     paint.begin(paletteBackgroundPixmap());
-    bitBlt(this, 0, 0, paletteBackgroundPixmap(), 0, 0, width(), height(), CopyROP \
);  if (Prefs::mode() ==0)  {
         QRect myRect = QRect(width()-width()*280/700, 0, width()*280/700, \
height()*90/535); @@ -308,12 +307,12 @@ void KHangManView::paintHangman()
         QPainter p(&pix);
         QFont f = QFont("Domestic Manners");
-        f.setPointSize(height()/15);
+        f.setPointSize(height()/17);
         p.setFont(f);
         p.setPen( QColor(148, 156, 167));
         QString misses = i18n("Misses");
-        p.drawText(0, 0, width()*280/700, height()*90/535, AlignLeft, misses);
+        p.drawText(0, 0, width()*280/700, height()*90/535, AlignLeft|AlignTop, \
misses);  QRect aux = paint.boundingRect(QRect(), AlignLeft, misses);
-        p.setFont(QFont("Bitstream Charter", height()/15, QFont::Bold));
-        p.drawText(aux.width()+50, 0, width()*280/700, height()*90/535, \
AlignLeft|AlignTop|DontClip, missedL ); +        p.setFont(QFont("Bitstream Charter", \
height()/17, QFont::Bold)); +        p.drawText(aux.width(), 0, width()*280/700, \
height()*90/535, AlignCenter|AlignTop|DontClip, missedL );  p.end();
         paint.drawPixmap(myRect,pix);
@@ -394,5 +393,5 @@ void KHangManView::slotTry()
                        // }
                     paintWord();
-                    update();
+                    //no update(); here or it'll flicker!!!
                     sword.remove(QRegExp(" "));
                     if (rightWord.stripWhiteSpace().lower() == \
sword.stripWhiteSpace().lower()) {   //you made it!


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic