summaryrefslogtreecommitdiffstats
path: root/kmines/frame.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kmines/frame.cpp')
-rw-r--r--kmines/frame.cpp44
1 files changed, 22 insertions, 22 deletions
diff --git a/kmines/frame.cpp b/kmines/frame.cpp
index b5c154b0..5eee07ba 100644
--- a/kmines/frame.cpp
+++ b/kmines/frame.cpp
@@ -26,8 +26,8 @@
#include "settings.h"
-FieldFrame::FieldFrame(TQWidget *tqparent)
- : TQFrame(tqparent, "field"), _button(0)
+FieldFrame::FieldFrame(TQWidget *parent)
+ : TQFrame(parent, "field"), _button(0)
{
setFrameStyle( TQFrame::Box | TQFrame::Raised );
setLineWidth(2);
@@ -39,18 +39,18 @@ void FieldFrame::adjustSize()
setFixedSize(tqsizeHint());
_button.resize(Settings::caseSize(), Settings::caseSize());
- TQBitmap tqmask;
+ TQBitmap mask;
for (uint i=0; i<Nb_Pixmap_Types; i++) {
- TQPixmap mask_pm = tqmask;
+ TQPixmap mask_pm = mask;
drawPixmap(mask_pm, (PixmapType)i, true);
drawPixmap(_pixmaps[i], (PixmapType)i, false);
- _pixmaps[i].setMask(tqmask);
+ _pixmaps[i].setMask(mask);
}
for (uint i=0; i<Nb_Advised; i++) {
- TQPixmap mask_pm = tqmask;
+ TQPixmap mask_pm = mask;
drawAdvised(mask_pm, i, true);
drawAdvised(_advised[i], i, false);
- _advised[i].setMask(tqmask);
+ _advised[i].setMask(mask);
}
TQFont f = font();
@@ -59,44 +59,44 @@ void FieldFrame::adjustSize()
setFont(f);
}
-void FieldFrame::initPixmap(TQPixmap &pix, bool tqmask) const
+void FieldFrame::initPixmap(TQPixmap &pix, bool mask) const
{
pix.resize(Settings::caseSize(), Settings::caseSize());
- if (tqmask) pix.fill(color0);
+ if (mask) pix.fill(color0);
}
-void FieldFrame::drawPixmap(TQPixmap &pix, PixmapType type, bool tqmask) const
+void FieldFrame::drawPixmap(TQPixmap &pix, PixmapType type, bool mask) const
{
- initPixmap(pix, tqmask);
+ initPixmap(pix, mask);
TQPainter p(&pix);
if ( type==FlagPixmap ) {
p.setWindow(0, 0, 16, 16);
- p.setPen( (tqmask ? color1 : black) );
+ p.setPen( (mask ? color1 : black) );
p.drawLine(6, 13, 14, 13);
p.drawLine(8, 12, 12, 12);
p.drawLine(9, 11, 11, 11);
p.drawLine(10, 2, 10, 10);
- if (!tqmask) p.setPen(black);
- p.setBrush( (tqmask ? color1 : Settings::color(Settings::EnumType::flag)) );
+ if (!mask) p.setPen(black);
+ p.setBrush( (mask ? color1 : Settings::color(Settings::EnumType::flag)) );
p.drawRect(4, 3, 6, 5);
return;
}
p.setWindow(0, 0, 20, 20);
if ( type==ExplodedPixmap )
- p.fillRect(2, 2, 16, 16, (tqmask ? color1 : Settings::color(Settings::EnumType::explosion)));
- TQPen pen(tqmask ? color1 : black, 1);
+ p.fillRect(2, 2, 16, 16, (mask ? color1 : Settings::color(Settings::EnumType::explosion)));
+ TQPen pen(mask ? color1 : black, 1);
p.setPen(pen);
- p.setBrush(tqmask ? color1 : black);
+ p.setBrush(mask ? color1 : black);
p.drawLine(10,3,10,18);
p.drawLine(3,10,18,10);
p.drawLine(5, 5, 16, 16);
p.drawLine(5, 15, 15, 5);
p.drawEllipse(5, 5, 11, 11);
- p.fillRect(8, 8, 2, 2, (tqmask ? color1 : white));
+ p.fillRect(8, 8, 2, 2, (mask ? color1 : white));
if ( type==ErrorPixmap ) {
- if (!tqmask) {
+ if (!mask) {
pen.setColor(Settings::color(Settings::EnumType::error));
p.setPen(pen);
}
@@ -109,12 +109,12 @@ void FieldFrame::drawPixmap(TQPixmap &pix, PixmapType type, bool tqmask) const
}
}
-void FieldFrame::drawAdvised(TQPixmap &pix, uint i, bool tqmask) const
+void FieldFrame::drawAdvised(TQPixmap &pix, uint i, bool mask) const
{
- initPixmap(pix, tqmask);
+ initPixmap(pix, mask);
TQPainter p(&pix);
p.setWindow(0, 0, 16, 16);
- p.setPen( TQPen(tqmask ? color1 : Settings::mineColor(i), 2) );
+ p.setPen( TQPen(mask ? color1 : Settings::mineColor(i), 2) );
p.drawRect(3, 3, 11, 11);
}