summaryrefslogtreecommitdiffstats
path: root/kwin/clients/plastik
diff options
context:
space:
mode:
Diffstat (limited to 'kwin/clients/plastik')
-rw-r--r--kwin/clients/plastik/config/configdialog.ui4
-rw-r--r--kwin/clients/plastik/misc.cpp10
-rw-r--r--kwin/clients/plastik/plastik.cpp6
-rw-r--r--kwin/clients/plastik/plastikbutton.cpp4
-rw-r--r--kwin/clients/plastik/plastikclient.cpp72
-rw-r--r--kwin/clients/plastik/plastikclient.h2
6 files changed, 49 insertions, 49 deletions
diff --git a/kwin/clients/plastik/config/configdialog.ui b/kwin/clients/plastik/config/configdialog.ui
index 642891b31..9970bd254 100644
--- a/kwin/clients/plastik/config/configdialog.ui
+++ b/kwin/clients/plastik/config/configdialog.ui
@@ -4,7 +4,7 @@
<property name="name">
<cstring>ConfigDialog</cstring>
</property>
- <property name="geometry">
+ <property name="tqgeometry">
<rect>
<x>0</x>
<y>0</y>
@@ -115,5 +115,5 @@
<tabstop>animateButtons</tabstop>
<tabstop>titleShadow</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kwin/clients/plastik/misc.cpp b/kwin/clients/plastik/misc.cpp
index 43786fe46..1b259d383 100644
--- a/kwin/clients/plastik/misc.cpp
+++ b/kwin/clients/plastik/misc.cpp
@@ -61,9 +61,9 @@ TQColor alphaBlendColors(const TQColor &bgColor, const TQColor &fgColor, const i
if(alpha<0) alpha = 0;
int inv_alpha = 255 - alpha;
- TQColor result = TQColor( qRgb(qRed(rgb_b)*inv_alpha/255 + qRed(rgb)*alpha/255,
- qGreen(rgb_b)*inv_alpha/255 + qGreen(rgb)*alpha/255,
- qBlue(rgb_b)*inv_alpha/255 + qBlue(rgb)*alpha/255) );
+ TQColor result = TQColor( tqRgb(tqRed(rgb_b)*inv_alpha/255 + tqRed(rgb)*alpha/255,
+ tqGreen(rgb_b)*inv_alpha/255 + tqGreen(rgb)*alpha/255,
+ tqBlue(rgb_b)*inv_alpha/255 + tqBlue(rgb)*alpha/255) );
return result;
}
@@ -73,10 +73,10 @@ TQImage recolorImage(TQImage *img, TQColor color) {
destImg.setAlphaBuffer(true);
for (int x = 0; x < img->width(); x++) {
for (int y = 0; y < img->height(); y++) {
- if(img->pixel(x,y) == qRgb(0,0,255) ) {
+ if(img->pixel(x,y) == tqRgb(0,0,255) ) {
destImg.setPixel(x,y,color.rgb() ); // set to the new color
} else {
- destImg.setPixel(x,y,qRgba(0,0,0,0) ); // set transparent...
+ destImg.setPixel(x,y,tqRgba(0,0,0,0) ); // set transparent...
}
}
}
diff --git a/kwin/clients/plastik/plastik.cpp b/kwin/clients/plastik/plastik.cpp
index a6313cd1c..8d905e398 100644
--- a/kwin/clients/plastik/plastik.cpp
+++ b/kwin/clients/plastik/plastik.cpp
@@ -87,7 +87,7 @@ bool PlastikHandler::reset(unsigned long changed)
m_borderSize = 4;
}
- // check if we are in reverse layout mode
+ // check if we are in reverse tqlayout mode
m_reverse = TQApplication::reverseLayout();
// read in the configuration
@@ -329,7 +329,7 @@ const TQPixmap &PlastikHandler::pixmap(Pixmaps type, bool active, bool toolWindo
painter.drawLine(2,h-1, w-1,h-1);
}
- // outside the region normally masked by doShape
+ // outside the region normally tqmasked by doShape
painter.setPen(TQColor(0,0,0) );
painter.drawLine(0, 0, 1, 0 );
painter.drawPoint(0, 1);
@@ -361,7 +361,7 @@ const TQPixmap &PlastikHandler::pixmap(Pixmaps type, bool active, bool toolWindo
painter.drawLine(0,h-1, w-3,h-1);
}
- // outside the region normally masked by doShape
+ // outside the region normally tqmasked by doShape
painter.setPen(TQColor(0,0,0) );
painter.drawLine(w-2, 0, w-1, 0 );
painter.drawPoint(w-1, 1);
diff --git a/kwin/clients/plastik/plastikbutton.cpp b/kwin/clients/plastik/plastikbutton.cpp
index 27a3eb127..5a3258004 100644
--- a/kwin/clients/plastik/plastikbutton.cpp
+++ b/kwin/clients/plastik/plastikbutton.cpp
@@ -140,7 +140,7 @@ void PlastikButton::animate()
}
}
- repaint(false);
+ tqrepaint(false);
}
void PlastikButton::enterEvent(TQEvent *e)
@@ -269,7 +269,7 @@ void PlastikButton::drawButton(TQPainter *painter)
if(!isDown() && Handler()->titleShadow() ) {
TQColor shadowColor;
- if (qGray(Handler()->getColor(TitleFont,active).rgb()) < 100)
+ if (tqGray(Handler()->getColor(TitleFont,active).rgb()) < 100)
shadowColor = TQColor(255, 255, 255);
else
shadowColor = TQColor(0,0,0);
diff --git a/kwin/clients/plastik/plastikclient.cpp b/kwin/clients/plastik/plastikclient.cpp
index 604c66641..4fdfe8e17 100644
--- a/kwin/clients/plastik/plastikclient.cpp
+++ b/kwin/clients/plastik/plastikclient.cpp
@@ -80,7 +80,7 @@ bool PlastikClient::decorationBehaviour(DecorationBehaviour behaviour) const
}
}
-int PlastikClient::layoutMetric(LayoutMetric lm, bool respectWindowState, const KCommonDecorationButton *btn) const
+int PlastikClient::tqlayoutMetric(LayoutMetric lm, bool respectWindowState, const KCommonDecorationButton *btn) const
{
bool maximized = maximizeMode()==MaximizeFull && !options()->moveResizeMaximizedWindows();
@@ -149,7 +149,7 @@ int PlastikClient::layoutMetric(LayoutMetric lm, bool respectWindowState, const
return 3;
default:
- return KCommonDecoration::layoutMetric(lm, respectWindowState, btn);
+ return KCommonDecoration::tqlayoutMetric(lm, respectWindowState, btn);
}
}
@@ -204,25 +204,25 @@ TQRegion PlastikClient::cornerShape(WindowCorner corner)
switch (corner) {
case WC_TopLeft:
- if (layoutMetric(LM_TitleEdgeLeft) > 0)
+ if (tqlayoutMetric(LM_TitleEdgeLeft) > 0)
return TQRegion(0, 0, 1, 2) + TQRegion(1, 0, 1, 1);
else
return TQRegion();
case WC_TopRight:
- if (layoutMetric(LM_TitleEdgeRight) > 0)
+ if (tqlayoutMetric(LM_TitleEdgeRight) > 0)
return TQRegion(w-1, 0, 1, 2) + TQRegion(w-2, 0, 1, 1);
else
return TQRegion();
case WC_BottomLeft:
- if (layoutMetric(LM_BorderBottom) > 0)
+ if (tqlayoutMetric(LM_BorderBottom) > 0)
return TQRegion(0, h-1, 1, 1);
else
return TQRegion();
case WC_BottomRight:
- if (layoutMetric(LM_BorderBottom) > 0)
+ if (tqlayoutMetric(LM_BorderBottom) > 0)
return TQRegion(w-1, h-1, 1, 1);
else
return TQRegion();
@@ -254,14 +254,14 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
// int r_h = r.height();
int r_x, r_y, r_x2, r_y2;
r.coords(&r_x, &r_y, &r_x2, &r_y2);
- const int borderLeft = layoutMetric(LM_BorderLeft);
- const int borderRight = layoutMetric(LM_BorderRight);
- const int borderBottom = layoutMetric(LM_BorderBottom);
- const int titleHeight = layoutMetric(LM_TitleHeight);
- const int titleEdgeTop = layoutMetric(LM_TitleEdgeTop);
- const int titleEdgeBottom = layoutMetric(LM_TitleEdgeBottom);
- const int titleEdgeLeft = layoutMetric(LM_TitleEdgeLeft);
- const int titleEdgeRight = layoutMetric(LM_TitleEdgeRight);
+ const int borderLeft = tqlayoutMetric(LM_BorderLeft);
+ const int borderRight = tqlayoutMetric(LM_BorderRight);
+ const int borderBottom = tqlayoutMetric(LM_BorderBottom);
+ const int titleHeight = tqlayoutMetric(LM_TitleHeight);
+ const int titleEdgeTop = tqlayoutMetric(LM_TitleEdgeTop);
+ const int titleEdgeBottom = tqlayoutMetric(LM_TitleEdgeBottom);
+ const int titleEdgeLeft = tqlayoutMetric(LM_TitleEdgeLeft);
+ const int titleEdgeRight = tqlayoutMetric(LM_TitleEdgeRight);
const int borderBottomTop = r_y2-borderBottom+1;
const int borderLeftRight = r_x+borderLeft-1;
@@ -280,7 +280,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(titleEdgeTop > 0)
{
tempRect.setRect(r_x+2, r_y, r_w-2*2, titleEdgeTop );
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(TitleBarTileTop, active, toolWindow) );
}
}
@@ -291,7 +291,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(titleEdgeLeft > 0)
{
tempRect.setRect(r_x, r_y, borderLeft, titleEdgeTop+titleHeight+titleEdgeBottom);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(TitleBarLeft, active, toolWindow) );
titleMarginLeft = borderLeft;
}
@@ -301,7 +301,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(titleEdgeRight > 0)
{
tempRect.setRect(borderRightLeft, r_y, borderRight, titleEdgeTop+titleHeight+titleEdgeBottom);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(TitleBarRight, active, toolWindow) );
titleMarginRight = borderRight;
}
@@ -312,7 +312,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(Rtitle.width() > 0)
{
m_captionRect = captionRect(); // also update m_captionRect!
- if (m_captionRect.isValid() && region.contains(m_captionRect) )
+ if (m_captionRect.isValid() && region.tqcontains(m_captionRect) )
{
painter.drawTiledPixmap(m_captionRect, caption);
}
@@ -320,14 +320,14 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
// left to the title
tempRect.setRect(r_x+titleMarginLeft, m_captionRect.top(),
m_captionRect.left() - (r_x+titleMarginLeft), m_captionRect.height() );
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(TitleBarTile, active, toolWindow) );
}
// right to the title
tempRect.setRect(m_captionRect.right()+1, m_captionRect.top(),
(r_x2-titleMarginRight) - m_captionRect.right(), m_captionRect.height() );
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(TitleBarTile, active, toolWindow) );
}
@@ -337,7 +337,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(borderLeft > 0 && sideHeight > 0)
{
tempRect.setCoords(r_x, titleEdgeBottomBottom+1, borderLeftRight, borderBottomTop-1);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(BorderLeftTile, active, toolWindow) );
}
}
@@ -346,7 +346,7 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
if(borderRight > 0 && sideHeight > 0)
{
tempRect.setCoords(borderRightLeft, titleEdgeBottomBottom+1, r_x2, borderBottomTop-1);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(BorderRightTile, active, toolWindow) );
}
}
@@ -358,19 +358,19 @@ void PlastikClient::paintEvent(TQPaintEvent *e)
int r = r_x2;
tempRect.setRect(r_x, borderBottomTop, borderLeft, borderBottom);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(BorderBottomLeft, active, toolWindow) );
l = tempRect.right()+1;
}
tempRect.setRect(borderRightLeft, borderBottomTop, borderLeft, borderBottom);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(BorderBottomRight, active, toolWindow) );
r = tempRect.left()-1;
}
tempRect.setCoords(l, borderBottomTop, r, r_y2);
- if (tempRect.isValid() && region.contains(tempRect) ) {
+ if (tempRect.isValid() && region.tqcontains(tempRect) ) {
painter.drawTiledPixmap(tempRect, handler->pixmap(BorderBottomTile, active, toolWindow) );
}
}
@@ -381,16 +381,16 @@ TQRect PlastikClient::captionRect() const
const TQPixmap &caption = captionPixmap();
TQRect r = widget()->rect();
- const int titleHeight = layoutMetric(LM_TitleHeight);
- const int titleEdgeBottom = layoutMetric(LM_TitleEdgeBottom);
- const int titleEdgeTop = layoutMetric(LM_TitleEdgeTop);
- const int titleEdgeLeft = layoutMetric(LM_TitleEdgeLeft);
- const int marginLeft = layoutMetric(LM_TitleBorderLeft);
- const int marginRight = layoutMetric(LM_TitleBorderRight);
+ const int titleHeight = tqlayoutMetric(LM_TitleHeight);
+ const int titleEdgeBottom = tqlayoutMetric(LM_TitleEdgeBottom);
+ const int titleEdgeTop = tqlayoutMetric(LM_TitleEdgeTop);
+ const int titleEdgeLeft = tqlayoutMetric(LM_TitleEdgeLeft);
+ const int marginLeft = tqlayoutMetric(LM_TitleBorderLeft);
+ const int marginRight = tqlayoutMetric(LM_TitleBorderRight);
const int titleLeft = r.left() + titleEdgeLeft + buttonsLeftWidth() + marginLeft;
const int titleWidth = r.width() -
- titleEdgeLeft - layoutMetric(LM_TitleEdgeRight) -
+ titleEdgeLeft - tqlayoutMetric(LM_TitleEdgeRight) -
buttonsLeftWidth() - buttonsRightWidth() -
marginLeft - marginRight;
@@ -435,7 +435,7 @@ void PlastikClient::reset( unsigned long changed )
{
if (changed & SettingColors)
{
- // repaint the whole thing
+ // tqrepaint the whole thing
clearCaptionPixmaps();
widget()->update();
updateButtons();
@@ -445,7 +445,7 @@ void PlastikClient::reset( unsigned long changed )
updateLayout();
- // then repaint
+ // then tqrepaint
clearCaptionPixmaps();
widget()->update();
}
@@ -479,7 +479,7 @@ const TQPixmap &PlastikClient::captionPixmap() const
int captionWidth = fm.width(c);
int captionHeight = fm.height();
- const int th = layoutMetric(LM_TitleHeight, false) + layoutMetric(LM_TitleEdgeBottom, false);
+ const int th = tqlayoutMetric(LM_TitleHeight, false) + tqlayoutMetric(LM_TitleEdgeBottom, false);
TQPainter painter;
@@ -496,7 +496,7 @@ const TQPixmap &PlastikClient::captionPixmap() const
if(Handler()->titleShadow())
{
TQColor shadowColor;
- if (qGray(Handler()->getColor(TitleFont,active).rgb()) < 100)
+ if (tqGray(Handler()->getColor(TitleFont,active).rgb()) < 100)
shadowColor = TQColor(255, 255, 255);
else
shadowColor = TQColor(0,0,0);
diff --git a/kwin/clients/plastik/plastikclient.h b/kwin/clients/plastik/plastikclient.h
index e83bf75a5..6f96664ea 100644
--- a/kwin/clients/plastik/plastikclient.h
+++ b/kwin/clients/plastik/plastikclient.h
@@ -41,7 +41,7 @@ public:
virtual TQString defaultButtonsLeft() const;
virtual TQString defaultButtonsRight() const;
virtual bool decorationBehaviour(DecorationBehaviour behaviour) const;
- virtual int layoutMetric(LayoutMetric lm, bool respectWindowState = true, const KCommonDecorationButton * = 0) const;
+ virtual int tqlayoutMetric(LayoutMetric lm, bool respectWindowState = true, const KCommonDecorationButton * = 0) const;
virtual TQRegion cornerShape(WindowCorner corner);
virtual KCommonDecorationButton *createButton(ButtonType type);