summaryrefslogtreecommitdiffstats
path: root/kcontrol/input/xcursor/themepage.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-07 04:10:07 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-07 04:10:07 +0000
commitfd3a982e26813f5bcc82c7e89ce6fa2ad44432bf (patch)
tree9eda848e56fcb862fdfdf479adeccd95b6fe387a /kcontrol/input/xcursor/themepage.cpp
parent02f67d0e1355b79b1806746efb0f2f640e57f13d (diff)
downloadtdebase-fd3a982e26813f5bcc82c7e89ce6fa2ad44432bf.tar.gz
tdebase-fd3a982e26813f5bcc82c7e89ce6fa2ad44432bf.zip
Revert automated changes
Sorry guys, they are just not ready for prime time Work will continue as always git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1212480 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kcontrol/input/xcursor/themepage.cpp')
-rw-r--r--kcontrol/input/xcursor/themepage.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/kcontrol/input/xcursor/themepage.cpp b/kcontrol/input/xcursor/themepage.cpp
index 38d41fff1..7caf18c3f 100644
--- a/kcontrol/input/xcursor/themepage.cpp
+++ b/kcontrol/input/xcursor/themepage.cpp
@@ -83,10 +83,10 @@ static TQString defaultThemeDescription( const TQString& theme )
ThemePage::ThemePage( TQWidget* parent, const char* name )
: TQWidget( parent, name ), selectedTheme( NULL ), currentTheme( NULL )
{
- TQBoxLayout *tqlayout = new TQVBoxLayout( this );
- tqlayout->setAutoAdd( true );
- tqlayout->setMargin( KDialog::marginHint() );
- tqlayout->setSpacing( KDialog::spacingHint() );
+ TQBoxLayout *layout = new TQVBoxLayout( this );
+ layout->setAutoAdd( true );
+ layout->setMargin( KDialog::marginHint() );
+ layout->setSpacing( KDialog::spacingHint() );
new TQLabel( i18n("Select the cursor theme you want to use (hover preview to test cursor):"), this );
@@ -122,7 +122,7 @@ ThemePage::ThemePage( TQWidget* parent, const char* name )
( !icons.exists() && !TQFileInfo( TQDir::homeDirPath() ).isWritable() ) )
installButton->setEnabled( false );
- if ( !themeDirs.tqcontains( path ) )
+ if ( !themeDirs.contains( path ) )
installButton->setEnabled( false );
selectionChanged( listview->currentItem() );
@@ -305,17 +305,17 @@ bool ThemePage::installThemes( const TQString &file )
// Check if a theme with that name already exists
if ( TQDir( destDir ).exists( *it ) ) {
const TQString question = i18n( "A theme named %1 already exists in your icon "
- "theme folder. Do you want tqreplace it with this one?" ).arg( *it );
+ "theme folder. Do you want replace it with this one?" ).arg( *it );
int answer = KMessageBox::warningContinueCancel( this, question, i18n( "Overwrite Theme?"), i18n("Replace") );
if ( answer != KMessageBox::Continue )
continue;
- // ### If the theme that's being tqreplaced is the current theme, it
+ // ### If the theme that's being replaced is the current theme, it
// will cause cursor inconsistencies in newly started apps.
}
// ### Should we check if a theme with the same name exists in a global theme dir?
- // If that's the case it will effectively tqreplace it, even though the global theme
+ // If that's the case it will effectively replace it, even though the global theme
// won't be deleted. Checking for this situation is easy, since the global theme
// will be in the listview. Maybe this should never be allowed since it might
// result in strange side effects (from the average users point of view). OTOH
@@ -395,7 +395,7 @@ const TQStringList ThemePage::getThemeBaseDirs() const
TQString path = XcursorLibraryPath();
#endif
// Expand all occurences of ~ to the home dir
- path.tqreplace( "~/", TQDir::homeDirPath() + '/' );
+ path.replace( "~/", TQDir::homeDirPath() + '/' );
return TQStringList::split( ':', path );
}
@@ -414,7 +414,7 @@ bool ThemePage::isCursorTheme( const TQString &theme, const int depth ) const
continue;
const TQStringList subdirs( dir.entryList( TQDir::Dirs ) );
- if ( subdirs.tqcontains( theme ) )
+ if ( subdirs.contains( theme ) )
{
const TQString path = *it + '/' + theme;
const TQString indexfile = path + "/index.theme";
@@ -453,7 +453,7 @@ bool ThemePage::isCursorTheme( const TQString &theme, const int depth ) const
void ThemePage::insertThemes()
{
// Scan each base dir for cursor themes and add them to the listview.
- // An icon theme is considered to be a cursor theme if it tqcontains
+ // An icon theme is considered to be a cursor theme if it contains
// a cursors subdirectory or if it inherits a cursor theme.
for ( TQStringList::ConstIterator it = themeDirs.begin(); it != themeDirs.end(); ++it )
{
@@ -585,7 +585,7 @@ TQPixmap ThemePage::createIcon( const TQString &theme, const TQString &sample )
image.setAlphaBuffer( true );
// Clear the image
- TQ_UINT32 *dst = reinterpret_cast<TQ_UINT32*>( image.bits() );
+ Q_UINT32 *dst = reinterpret_cast<Q_UINT32*>( image.bits() );
for ( int i = 0; i < image.width() * image.height(); i++ )
dst[i] = 0;
@@ -593,26 +593,26 @@ TQPixmap ThemePage::createIcon( const TQString &theme, const TQString &sample )
TQPoint dstOffset( (image.width() - r.width()) / 2, (image.height() - r.height()) / 2 );
TQPoint srcOffset( r.topLeft() );
- dst = reinterpret_cast<TQ_UINT32*>( image.scanLine(dstOffset.y()) ) + dstOffset.x();
- src = reinterpret_cast<TQ_UINT32*>( xcur->pixels ) + srcOffset.y() * xcur->width + srcOffset.x();
+ dst = reinterpret_cast<Q_UINT32*>( image.scanLine(dstOffset.y()) ) + dstOffset.x();
+ src = reinterpret_cast<Q_UINT32*>( xcur->pixels ) + srcOffset.y() * xcur->width + srcOffset.x();
// Copy the XcursorImage into the TQImage, converting it from premultiplied
// to non-premultiplied alpha and cropping it if needed.
for ( int y = 0; y < r.height(); y++ )
{
for ( int x = 0; x < r.width(); x++, dst++, src++ ) {
- const TQ_UINT32 pixel = *src;
+ const Q_UINT32 pixel = *src;
- const TQ_UINT8 a = tqAlpha( pixel );
- const TQ_UINT8 r = tqRed( pixel );
- const TQ_UINT8 g = tqGreen( pixel );
- const TQ_UINT8 b = tqBlue( pixel );
+ const Q_UINT8 a = qAlpha( pixel );
+ const Q_UINT8 r = qRed( pixel );
+ const Q_UINT8 g = qGreen( pixel );
+ const Q_UINT8 b = qBlue( pixel );
if ( !a || a == 255 ) {
*dst = pixel;
} else {
float alpha = a / 255.0;
- *dst = tqRgba( int(r / alpha), int(g / alpha), int(b / alpha), a );
+ *dst = qRgba( int(r / alpha), int(g / alpha), int(b / alpha), a );
}
}
dst += ( image.width() - r.width() );
@@ -630,7 +630,7 @@ TQPixmap ThemePage::createIcon( const TQString &theme, const TQString &sample )
TQImage image( iconSize, iconSize, 32 );
image.setAlphaBuffer( true );
- TQ_UINT32 *data = reinterpret_cast< TQ_UINT32* >( image.bits() );
+ Q_UINT32 *data = reinterpret_cast< Q_UINT32* >( image.bits() );
for ( int i = 0; i < image.width() * image.height(); i++ )
data[ i ] = 0;