summaryrefslogtreecommitdiffstats
path: root/twin-styles/cde/cdeclient.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 09:58:18 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 09:58:18 -0600
commit48afe4d8df11f862f7ccc60f0594991f857f81db (patch)
tree3f24a7c318e7f7dd10ada3a918006ad495ad9245 /twin-styles/cde/cdeclient.cpp
parent5c194e6e7059ddcc96b0e0166ce6157c35fc183e (diff)
downloadtdeartwork-48afe4d8df11f862f7ccc60f0594991f857f81db.tar.gz
tdeartwork-48afe4d8df11f862f7ccc60f0594991f857f81db.zip
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit 5c194e6e7059ddcc96b0e0166ce6157c35fc183e.
Diffstat (limited to 'twin-styles/cde/cdeclient.cpp')
-rw-r--r--twin-styles/cde/cdeclient.cpp98
1 files changed, 49 insertions, 49 deletions
diff --git a/twin-styles/cde/cdeclient.cpp b/twin-styles/cde/cdeclient.cpp
index 34a4baae..03eb14fa 100644
--- a/twin-styles/cde/cdeclient.cpp
+++ b/twin-styles/cde/cdeclient.cpp
@@ -19,7 +19,7 @@
#include "cdeclient.h"
#include <tqdatetime.h>
-#include <layout.h>
+#include <tqlayout.h>
#include <tqbutton.h>
#include <tqcursor.h>
#include <tqlabel.h>
@@ -114,9 +114,9 @@ static inline const KDecorationOptions* options()
return KDecoration::options();
}
-static void fixColorGroup(TQColorGroup & colorGroup)
+static void fixColorGroup(TQColorGroup & tqcolorGroup)
{
- TQColor light = colorGroup.light();
+ TQColor light = tqcolorGroup.light();
int hue, saturation, value;
@@ -125,17 +125,17 @@ static void fixColorGroup(TQColorGroup & colorGroup)
if (value < 128)
{
light.setHsv(hue, saturation, 128);
- colorGroup.setColor(TQColorGroup::Light, light);
+ tqcolorGroup.setColor(TQColorGroup::Light, light);
}
- TQColor dark = colorGroup.dark();
+ TQColor dark = tqcolorGroup.dark();
dark.hsv(&hue, &saturation, &value);
if (value < 84)
{
dark.setHsv(hue, saturation, 84);
- colorGroup.setColor(TQColorGroup::Dark, dark);
+ tqcolorGroup.setColor(TQColorGroup::Dark, dark);
}
}
@@ -381,7 +381,7 @@ void CdeClient::addClientButtons( const TQString& s )
void CdeClient::captionChange()
{
- widget()->repaint(titlebar->geometry(), false);
+ widget()->tqrepaint(titlebar->tqgeometry(), false);
}
void CdeClient::activeChange()
@@ -389,7 +389,7 @@ void CdeClient::activeChange()
for ( int i=0; i < BtnCount; i++ )
if ( button[i] ) button[i]->reset();
- widget()->repaint(false);
+ widget()->tqrepaint(false);
}
void CdeClient::maximizeChange()
@@ -398,7 +398,7 @@ void CdeClient::maximizeChange()
bool m = maximizeMode() == MaximizeFull;
TQToolTip::remove(button[BtnMax]);
TQToolTip::add(button[BtnMax], m ? i18n("Restore") : i18n("Maximize"));
- button[BtnMax]->repaint();
+ button[BtnMax]->tqrepaint();
}
}
@@ -412,7 +412,7 @@ void CdeClient::shadeChange()
void CdeClient::showEvent(TQShowEvent *)
{
- widget()->repaint();
+ widget()->tqrepaint();
}
void CdeClient::desktopChange()
@@ -420,7 +420,7 @@ void CdeClient::desktopChange()
// Nothing to do yet
}
-TQSize CdeClient::minimumSize() const
+TQSize CdeClient::tqminimumSize() const
{
return TQSize(2 * (s_buttonSize + s_frameWidth),
2 * s_frameWidth + s_buttonSize);
@@ -489,12 +489,12 @@ void CdeClient::resizeEvent( TQResizeEvent* e)
{
widget()->update( width() - dx + 1, 0, dx, height() );
widget()->update( TQRect( TQPoint(4,4),
- titlebar->geometry().bottomLeft() - TQPoint(1,0) ) );
- widget()->update(TQRect(titlebar->geometry().topRight(),
- TQPoint(width() - 4, titlebar->geometry().bottom())));
+ titlebar->tqgeometry().bottomLeft() - TQPoint(1,0) ) );
+ widget()->update(TQRect(titlebar->tqgeometry().topRight(),
+ TQPoint(width() - 4, titlebar->tqgeometry().bottom())));
// Titlebar needs no paint event
- TQApplication::postEvent( this, new TQPaintEvent( titlebar->geometry(), false ) );
+ TQApplication::postEvent( this, new TQPaintEvent( titlebar->tqgeometry(), false ) );
}
}
}
@@ -503,16 +503,16 @@ void CdeClient::paintEvent( TQPaintEvent* )
{
TQPainter p(widget());
- TQColorGroup colorGroup;
+ TQColorGroup tqcolorGroup;
if ( coloredFrame )
- colorGroup = options()->colorGroup( KDecoration::ColorTitleBar, isActive() );
+ tqcolorGroup = options()->tqcolorGroup( KDecoration::ColorTitleBar, isActive() );
else
- colorGroup = options()->colorGroup( KDecoration::ColorFrame, isActive() );
+ tqcolorGroup = options()->tqcolorGroup( KDecoration::ColorFrame, isActive() );
- fixColorGroup( colorGroup );
+ fixColorGroup( tqcolorGroup );
- TQRect trect = titlebar->geometry();
+ TQRect trect = titlebar->tqgeometry();
TQRect mrect = widget()->rect();
if ( s_frameWidth > 0 )
@@ -523,7 +523,7 @@ void CdeClient::paintEvent( TQPaintEvent* )
}
p.setPen( TQt::NoPen );
- p.setBrush( colorGroup.background() );
+ p.setBrush( tqcolorGroup.background() );
if ( s_frameWidth > 1 )
@@ -546,24 +546,24 @@ void CdeClient::paintEvent( TQPaintEvent* )
// draw left and right frames:
qDrawShadePanel( &p, 1, longSide + 1,
s_frameWidth, mrect.height() - 2 * (longSide + 1),
- colorGroup );
+ tqcolorGroup );
qDrawShadePanel( &p, mrect.width() - s_frameWidth - 1, longSide + 1,
s_frameWidth, mrect.height() - 2 * (longSide + 1),
- colorGroup );
+ tqcolorGroup );
}
// draw top and bottom frames:
qDrawShadePanel( &p, longSide + 1, 1,
mrect.width() - 2 * (longSide + 1), s_frameWidth,
- colorGroup );
+ tqcolorGroup );
qDrawShadePanel( &p, longSide + 1, mrect.height() - s_frameWidth - 1,
mrect.width() - 2 * (longSide + 1), s_frameWidth,
- colorGroup );
+ tqcolorGroup );
// draw light corner parts:
- p.setPen( colorGroup.light() );
+ p.setPen( tqcolorGroup.light() );
// tl corner:
p.drawLine( 1, 1, longSide - 1, 1 );
@@ -601,7 +601,7 @@ void CdeClient::paintEvent( TQPaintEvent* )
s_frameWidth + 1, mrect.height() - s_frameWidth - 1 );
// draw dark corner parts:
- p.setPen( colorGroup.dark() );
+ p.setPen( tqcolorGroup.dark() );
// tl corner:
if ( !shaded )
@@ -640,14 +640,14 @@ void CdeClient::paintEvent( TQPaintEvent* )
if ( !coloredFrame )
{
- colorGroup = options()->colorGroup( KDecoration::ColorTitleBar, isActive() );
- fixColorGroup( colorGroup );
- p.setBrush( colorGroup.background() );
+ tqcolorGroup = options()->tqcolorGroup( KDecoration::ColorTitleBar, isActive() );
+ fixColorGroup( tqcolorGroup );
+ p.setBrush( tqcolorGroup.background() );
}
// draw titlebar:
p.drawRect( trect );
- qDrawShadePanel( &p, trect, colorGroup, titlebarPressed );
+ qDrawShadePanel( &p, trect, tqcolorGroup, titlebarPressed );
// draw caption:
if ( titlebarPressed ) // move the caption right and down if the titlebar is pressed
@@ -672,7 +672,7 @@ void CdeClient::paintEvent( TQPaintEvent* )
// Draw a line behind the wrapped window to prevent having
// unpainted areas when we're shaded.
- p.setPen( colorGroup.dark() );
+ p.setPen( tqcolorGroup.dark() );
p.drawLine(s_frameWidth + 1, mrect.height() - s_frameWidth - 2,
mrect.width() - s_frameWidth - 2, mrect.height() - s_frameWidth - 2);
@@ -712,24 +712,24 @@ KDecoration::Position CdeClient::mousePosition( const TQPoint& p ) const
void CdeClient::mouseDoubleClickEvent( TQMouseEvent * e )
{
- if ( e->button() == Qt::LeftButton && titlebar->geometry().contains( e->pos() ) )
+ if ( e->button() == Qt::LeftButton && titlebar->tqgeometry().contains( e->pos() ) )
titlebarDblClickOperation();
}
void CdeClient::wheelEvent( TQWheelEvent * e )
{
- if (isSetShade() || titleLayout->geometry().contains( e->pos() ) )
+ if (isSetShade() || titleLayout->tqgeometry().contains( e->pos() ) )
titlebarMouseWheelOperation( e->delta());
}
void CdeClient::mousePressEvent( TQMouseEvent * e )
{
- if ( e->button() == Qt::LeftButton && titlebar->geometry().contains( e->pos() ) )
+ if ( e->button() == Qt::LeftButton && titlebar->tqgeometry().contains( e->pos() ) )
{
if ( titlebarButtonMode )
{
titlebarPressed = true;
- widget()->repaint(titlebar->geometry(), false);
+ widget()->tqrepaint(titlebar->tqgeometry(), false);
}
}
}
@@ -745,7 +745,7 @@ void CdeClient::mouseReleaseEvent( TQMouseEvent * e )
if ( e->button() == Qt::LeftButton && titlebarPressed )
{
titlebarPressed = false;
- widget()->repaint(titlebar->geometry(), false);
+ widget()->tqrepaint(titlebar->tqgeometry(), false);
}
}
@@ -797,7 +797,7 @@ CdeButton::CdeButton(CdeClient* parent,
void CdeButton::reset()
{
- repaint( false );
+ tqrepaint( false );
}
void CdeButton::drawButton( TQPainter* p )
@@ -805,36 +805,36 @@ void CdeButton::drawButton( TQPainter* p )
p->setBrush( options()->color( KDecoration::ColorTitleBar, m_parent->isActive() ) );
p->drawRect( 0, 0, s_buttonSize, s_buttonSize );
- TQColorGroup colorGroup =
- options()->colorGroup( KDecoration::ColorTitleBar, m_parent->isActive() );
+ TQColorGroup tqcolorGroup =
+ options()->tqcolorGroup( KDecoration::ColorTitleBar, m_parent->isActive() );
- fixColorGroup(colorGroup);
+ fixColorGroup(tqcolorGroup);
qDrawShadePanel( p, 0, 0, s_buttonSize, s_buttonSize,
- colorGroup, isDown() );
+ tqcolorGroup, isDown() );
switch ( m_btnType )
{
case (BtnMenu):
- qDrawShadePanel( p, s_o1, s_o2, s_w1, s_w2, colorGroup );
+ qDrawShadePanel( p, s_o1, s_o2, s_w1, s_w2, tqcolorGroup );
break;
case (BtnHelp):
- p->setPen( colorGroup.light() );
+ p->setPen( tqcolorGroup.light() );
p->drawLineSegments( TQPointArray(16, helpLLines) );
- p->setPen( colorGroup.dark() );
+ p->setPen( tqcolorGroup.dark() );
p->drawLineSegments( TQPointArray(14, helpDLines) );
break;
case (BtnIconify):
- qDrawShadePanel( p, s_o2, s_o2, s_w2, s_w2, colorGroup );
+ qDrawShadePanel( p, s_o2, s_o2, s_w2, s_w2, tqcolorGroup );
break;
case (BtnMax):
- qDrawShadePanel( p, s_o1, s_o1, s_w1, s_w1, colorGroup,
+ qDrawShadePanel( p, s_o1, s_o1, s_w1, s_w1, tqcolorGroup,
m_parent->maximizeMode() == KDecoration::MaximizeFull );
break;
case (BtnClose):
- p->setPen( colorGroup.dark() );
+ p->setPen( tqcolorGroup.dark() );
p->drawLineSegments( TQPointArray(18, closeDLines) );
- p->setPen( colorGroup.light() );
+ p->setPen( tqcolorGroup.light() );
p->drawLineSegments( TQPointArray(15, closeLLines) );
break;
}