Rename a number of old tq methods that are no longer tq specific

r14.0.x
Timothy Pearson 13 years ago
parent ff1cff2a1e
commit 2b7143e053

@ -20,7 +20,7 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>400</width> <width>400</width>
<height>0</height> <height>0</height>
@ -88,7 +88,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>383</width> <width>383</width>
<height>16</height> <height>16</height>

@ -98,7 +98,7 @@ public:
if ( !item) return; if ( !item) return;
if (item->mBookmark.isGroup()) return; if (item->mBookmark.isGroup()) return;
TQRect rect=mListView->tqitemRect(item); TQRect rect=mListView->itemRect(item);
tip(rect, item->mBookmark.url().prettyURL()); tip(rect, item->mBookmark.url().prettyURL());
}; };
@ -392,11 +392,11 @@ void BookmarkViewController::deleteCurrentBookmark() {
TQString title; TQString title;
if (bookmark.isGroup()) { if (bookmark.isGroup()) {
msg=i18n("Are you sure you want to delete the bookmark folder <b>%1</b>?<br>This will delete the folder and all the bookmarks in it.") msg=i18n("Are you sure you want to delete the bookmark folder <b>%1</b>?<br>This will delete the folder and all the bookmarks in it.")
.tqarg(bookmark.text()); .arg(bookmark.text());
title=i18n("Delete Bookmark &Folder"); title=i18n("Delete Bookmark &Folder");
} else { } else {
msg=i18n("Are you sure you want to delete the bookmark <b>%1</b>?") msg=i18n("Are you sure you want to delete the bookmark <b>%1</b>?")
.tqarg(bookmark.text()); .arg(bookmark.text());
title=i18n("Delete &Bookmark"); title=i18n("Delete &Bookmark");
} }

@ -22,13 +22,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// TQt // TQt
#include <tqbuttongroup.h> #include <tqbuttongroup.h>
#include <tqcheckbox.h> #include <tqcheckbox.h>
#include <tqlayout.h> #include <layout.h>
#include <tqlineedit.h> #include <tqlineedit.h>
#include <tqmap.h> #include <tqmap.h>
#include <tqradiobutton.h> #include <tqradiobutton.h>
#include <tqspinbox.h> #include <tqspinbox.h>
#include <tqstylesheet.h> #include <stylesheet.h>
#include <tqtextedit.h> #include <textedit.h>
// KDE // KDE
#include <kcolorbutton.h> #include <kcolorbutton.h>
@ -93,9 +93,9 @@ template<class T>
void addConfigPage(KDialogBase* dialog, T* content, const TQString& header, const TQString& name, const char* iconName) { void addConfigPage(KDialogBase* dialog, T* content, const TQString& header, const TQString& name, const char* iconName) {
TQFrame* page=dialog->addPage(name, header, BarIcon(iconName, 32)); TQFrame* page=dialog->addPage(name, header, BarIcon(iconName, 32));
content->reparent(page, TQPoint(0,0)); content->reparent(page, TQPoint(0,0));
TQVBoxLayout* tqlayout=new TQVBoxLayout(page, 0, KDialog::spacingHint()); TQVBoxLayout* layout=new TQVBoxLayout(page, 0, KDialog::spacingHint());
tqlayout->addWidget(content); layout->addWidget(content);
tqlayout->addStretch(); layout->addStretch();
} }
template<class T> template<class T>
@ -247,7 +247,7 @@ void ConfigDialog::calculateCacheSize() {
KURL url; KURL url;
url.setPath(ThumbnailLoadJob::thumbnailBaseDir()); url.setPath(ThumbnailLoadJob::thumbnailBaseDir());
unsigned long size=KDirSize::dirSize(url); unsigned long size=KDirSize::dirSize(url);
KMessageBox::information( this,i18n("Cache size is %1").tqarg(KIO::convertSize(size)) ); KMessageBox::information( this,i18n("Cache size is %1").arg(KIO::convertSize(size)) );
} }
@ -281,7 +281,7 @@ void ConfigDialog::emptyCache() {
int response=KMessageBox::warningContinueCancel(this, int response=KMessageBox::warningContinueCancel(this,
"<qt>" + i18n("Are you sure you want to empty the thumbnail cache?" "<qt>" + i18n("Are you sure you want to empty the thumbnail cache?"
" This will delete the folder <b>%1</b>.").tqarg(TQStyleSheet::escape(dir)) + "</qt>", " This will delete the folder <b>%1</b>.").arg(TQStyleSheet::escape(dir)) + "</qt>",
TQString(), TQString(),
KStdGuiItem::del()); KStdGuiItem::del());
@ -289,7 +289,7 @@ void ConfigDialog::emptyCache() {
KURL url; KURL url;
url.setPath(dir); url.setPath(dir);
if (KIO::NetAccess::del(url, tqtopLevelWidget()) ) { if (KIO::NetAccess::del(url, topLevelWidget()) ) {
KMessageBox::information( this,i18n("Cache emptied.") ); KMessageBox::information( this,i18n("Cache emptied.") );
} }
} }

@ -93,7 +93,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>16</height> <height>16</height>

@ -43,7 +43,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>16</height> <height>16</height>
@ -131,7 +131,7 @@ You can use the following keywords to format the On Screen Display:
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>18</height> <height>18</height>

@ -40,7 +40,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>16</height> <height>16</height>
@ -131,7 +131,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>20</width> <width>20</width>
<height>0</height> <height>0</height>
@ -150,7 +150,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout6</cstring> <cstring>layout6</cstring>
</property> </property>
<grid> <grid>
<property name="name"> <property name="name">
@ -166,7 +166,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>20</height> <height>20</height>
@ -217,7 +217,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>16</height> <height>16</height>
@ -258,7 +258,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout7</cstring> <cstring>layout7</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">

@ -56,7 +56,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>181</width> <width>181</width>
<height>21</height> <height>21</height>
@ -73,7 +73,7 @@
</widget> </widget>
<widget class="TQLayoutWidget" row="4" column="0" rowspan="1" colspan="6"> <widget class="TQLayoutWidget" row="4" column="0" rowspan="1" colspan="6">
<property name="name"> <property name="name">
<cstring>tqlayout4</cstring> <cstring>layout4</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">
@ -217,7 +217,7 @@
<string>Using this option, Gwenview will display the image as fast as possible, and smooth it after a short delay. <string>Using this option, Gwenview will display the image as fast as possible, and smooth it after a short delay.
Use this option if your computer is not very fast.</string> Use this option if your computer is not very fast.</string>
</property> </property>
<property name="tqalignment"> <property name="alignment">
<set>WordBreak|AlignTop</set> <set>WordBreak|AlignTop</set>
</property> </property>
<property name="buddy" stdset="0"> <property name="buddy" stdset="0">
@ -238,7 +238,7 @@ Use this option if your computer is not very fast.</string>
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>16</height> <height>16</height>

@ -92,7 +92,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>20</width> <width>20</width>
<height>24</height> <height>24</height>
@ -120,7 +120,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>20</width> <width>20</width>
<height>24</height> <height>24</height>
@ -137,7 +137,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout1</cstring> <cstring>layout1</cstring>
</property> </property>
<grid> <grid>
<property name="name"> <property name="name">
@ -153,7 +153,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>11</width> <width>11</width>
<height>20</height> <height>20</height>
@ -191,7 +191,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>41</height> <height>41</height>

@ -88,7 +88,7 @@ When this option is enabled, the slideshow will stop on the last image of the fo
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>180</width> <width>180</width>
<height>20</height> <height>20</height>

@ -163,7 +163,7 @@ KIPI::ImageCollection KIPIInterface::currentSelection() {
LOG(""); LOG("");
KURL::List list=d->mFileView->selectedImageURLs(); KURL::List list=d->mFileView->selectedImageURLs();
KURL url=d->mFileView->dirURL(); KURL url=d->mFileView->dirURL();
return KIPI::ImageCollection(new ImageCollection(url, i18n("%1 (Selected Images)").tqarg(url.fileName()), list)); return KIPI::ImageCollection(new ImageCollection(url, i18n("%1 (Selected Images)").arg(url.fileName()), list));
} }
@ -189,12 +189,12 @@ int KIPIInterface::features() const {
* here, it is however necessary to discard caches if the plugin preserves timestamp * here, it is however necessary to discard caches if the plugin preserves timestamp
*/ */
bool KIPIInterface::addImage(const KURL& url, TQString&) { bool KIPIInterface::addImage(const KURL& url, TQString&) {
Cache::instance()->tqinvalidate( url ); Cache::instance()->invalidate( url );
return true; return true;
} }
void KIPIInterface::delImage(const KURL& url) { void KIPIInterface::delImage(const KURL& url) {
Cache::instance()->tqinvalidate( url ); Cache::instance()->invalidate( url );
} }
// TODO currently KDirWatch doesn't have watching of files in a directory // TODO currently KDirWatch doesn't have watching of files in a directory
@ -203,7 +203,7 @@ void KIPIInterface::refreshImages( const KURL::List& urls ) {
for( KURL::List::ConstIterator it = urls.begin(); for( KURL::List::ConstIterator it = urls.begin();
it != urls.end(); it != urls.end();
++it ) { ++it ) {
Cache::instance()->tqinvalidate( *it ); Cache::instance()->invalidate( *it );
} }
d->mFileView->refreshItems( urls ); d->mFileView->refreshItems( urls );
} }

@ -117,7 +117,7 @@ KDE_EXPORT int kdemain (int argc, char *argv[]) {
aboutData.addCredit("Marco Gazzetta", I18N_NOOP("Fixed crash when trying to generate a thumbnail for a broken JPEG file (v0.16.0)"), "mililani@pobox.com"); aboutData.addCredit("Marco Gazzetta", I18N_NOOP("Fixed crash when trying to generate a thumbnail for a broken JPEG file (v0.16.0)"), "mililani@pobox.com");
aboutData.addCredit("GeniusR13", I18N_NOOP("Fixed compilation on KDE 3.0 (v0.16.1)"), "geniusr13@gmx.net"); aboutData.addCredit("GeniusR13", I18N_NOOP("Fixed compilation on KDE 3.0 (v0.16.1)"), "geniusr13@gmx.net");
aboutData.addCredit("Ian Koenig", I18N_NOOP("First RPM spec file"), "iguy@ionsphere.org"); aboutData.addCredit("Ian Koenig", I18N_NOOP("First RPM spec file"), "iguy@ionsphere.org");
aboutData.addCredit("Meni Livne", I18N_NOOP("Toolbar tqlayout patch for RTL languages (v0.16.0)"), "livne@kde.org"); aboutData.addCredit("Meni Livne", I18N_NOOP("Toolbar layout patch for RTL languages (v0.16.0)"), "livne@kde.org");
aboutData.addCredit("Angelo Naselli", I18N_NOOP("Printing support (v1.0.0)"), "anaselli@linux.it"); aboutData.addCredit("Angelo Naselli", I18N_NOOP("Printing support (v1.0.0)"), "anaselli@linux.it");
aboutData.addCredit("Jos van den Oever", I18N_NOOP("File info view (v1.0.0)\nPatch to toggle auto-zoom on click (v1.0.0)"), "jos@vandenoever.info"); aboutData.addCredit("Jos van den Oever", I18N_NOOP("File info view (v1.0.0)\nPatch to toggle auto-zoom on click (v1.0.0)"), "jos@vandenoever.info");
aboutData.addCredit("Jeroen Peters", I18N_NOOP("Configurable mouse wheel behavior (v1.1.1)"), "jpeters@coldmail.nl"); aboutData.addCredit("Jeroen Peters", I18N_NOOP("Configurable mouse wheel behavior (v1.1.1)"), "jpeters@coldmail.nl");

@ -199,8 +199,8 @@ bool MainWindow::queryClose() {
KConfig* config=KGlobal::config(); KConfig* config=KGlobal::config();
// Don't store dock tqlayout if only the image dock is visible. This avoid // Don't store dock layout if only the image dock is visible. This avoid
// saving tqlayout when in "fullscreen" or "image only" mode. // saving layout when in "fullscreen" or "image only" mode.
if (mFileViewController->isVisible() || mDirViewController->widget()->isVisible()) { if (mFileViewController->isVisible() || mDirViewController->widget()->isVisible()) {
mDockArea->writeDockConfig(config,CONFIG_DOCK_GROUP); mDockArea->writeDockConfig(config,CONFIG_DOCK_GROUP);
} }
@ -806,7 +806,7 @@ void MainWindow::updateStatusInfo() {
int pos = mFileViewController->shownFilePosition(); int pos = mFileViewController->shownFilePosition();
uint count = mFileViewController->fileCount(); uint count = mFileViewController->fileCount();
if (count > 0) { if (count > 0) {
tokens << i18n("%1/%2").tqarg(pos+1).tqarg(count); tokens << i18n("%1/%2").arg(pos+1).arg(count);
} else { } else {
tokens << i18n("No images"); tokens << i18n("No images");
} }
@ -816,7 +816,7 @@ void MainWindow::updateStatusInfo() {
TQSize size = mDocument->image().size(); TQSize size = mDocument->image().size();
if (!size.isEmpty()) { if (!size.isEmpty()) {
tokens << i18n("%1 x %2 pixels").tqarg(size.width()).tqarg(size.height()); tokens << i18n("%1 x %2 pixels").arg(size.width()).arg(size.height());
} }
mSBDetailLabel->setText(tokens.join(" - ")); mSBDetailLabel->setText(tokens.join(" - "));
@ -867,11 +867,11 @@ void MainWindow::createWidgets() {
mDockArea->manager()->setSplitterOpaqueResize(true); mDockArea->manager()->setSplitterOpaqueResize(true);
mViewModeWidget=new TQWidget(mCentralStack); mViewModeWidget=new TQWidget(mCentralStack);
TQVBoxLayout* tqlayout=new TQVBoxLayout(mViewModeWidget); TQVBoxLayout* layout=new TQVBoxLayout(mViewModeWidget);
tqlayout->setAutoAdd(true); layout->setAutoAdd(true);
mCentralStack->addWidget(mViewModeWidget); mCentralStack->addWidget(mViewModeWidget);
// tqStatus bar // Status bar
mSBDetailLabel=new TQLabel("", statusBar()); mSBDetailLabel=new TQLabel("", statusBar());
mSBHintLabel=new TruncatedTextLabel(statusBar()); mSBHintLabel=new TruncatedTextLabel(statusBar());
@ -923,7 +923,7 @@ void MainWindow::createWidgets() {
setGeometry(20,20,720,520); setGeometry(20,20,720,520);
// Default dock config // Default dock config
// (The "magic numbers" were found by adjusting the tqlayout from within the // (The "magic numbers" were found by adjusting the layout from within the
// app and looking at the result in the configuration file) // app and looking at the result in the configuration file)
mFolderDock->manualDock(mFileDock, KDockWidget::DockLeft, 4000); mFolderDock->manualDock(mFileDock, KDockWidget::DockLeft, 4000);
mImageDock->manualDock(mFolderDock, KDockWidget::DockBottom, 3734); mImageDock->manualDock(mFolderDock, KDockWidget::DockBottom, 3734);
@ -1094,9 +1094,9 @@ void MainWindow::createObjectInteractions() {
void MainWindow::createHideShowAction(KDockWidget* dock) { void MainWindow::createHideShowAction(KDockWidget* dock) {
TQString caption; TQString caption;
if (dock->mayBeHide()) { if (dock->mayBeHide()) {
caption=i18n("Hide %1").tqarg(dock->caption()); caption=i18n("Hide %1").arg(dock->caption());
} else { } else {
caption=i18n("Show %1").tqarg(dock->caption()); caption=i18n("Show %1").arg(dock->caption());
} }
KAction* action=new KAction(caption, 0, TQT_TQOBJECT(dock), TQT_SLOT(changeHideShowState()), (TQObject*)0 ); KAction* action=new KAction(caption, 0, TQT_TQOBJECT(dock), TQT_SLOT(changeHideShowState()), (TQObject*)0 );
@ -1216,7 +1216,7 @@ void MainWindow::createLocationToolBar() {
// Do not let the combobox get wider than available space, as this would // Do not let the combobox get wider than available space, as this would
// hide the toolbuttons after it // hide the toolbuttons after it
mURLEdit->tqsetSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed); mURLEdit->setSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed);
// Avoid stealing focus // Avoid stealing focus
mURLEdit->setFocusPolicy(TQ_ClickFocus); mURLEdit->setFocusPolicy(TQ_ClickFocus);

@ -19,7 +19,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/ */
// TQt // TQt
#include <tqlabel.h> #include <tqlabel.h>
#include <tqtextedit.h> #include <textedit.h>
#include <tqfileinfo.h> #include <tqfileinfo.h>
// KDE // KDE
@ -132,7 +132,7 @@ void MetaEdit::setComment(const TQString& comment) {
void MetaEdit::setMessage(const TQString& msg) { void MetaEdit::setMessage(const TQString& msg) {
mCommentEdit->setTextFormat(TQTextEdit::RichText); mCommentEdit->setTextFormat(TQTextEdit::RichText);
mCommentEdit->setReadOnly(true); mCommentEdit->setReadOnly(true);
mCommentEdit->setText(TQString("<i>%1</i>").tqarg(msg)); mCommentEdit->setText(TQString("<i>%1</i>").arg(msg));
} }
} // namespace } // namespace

@ -39,14 +39,14 @@ public:
TruncatedTextLabel(TQWidget* parent) TruncatedTextLabel(TQWidget* parent)
: TQLabel(parent) {} : TQLabel(parent) {}
TQSize tqminimumSizeHint() const { TQSize minimumSizeHint() const {
TQSize size=TQLabel::tqminimumSizeHint(); TQSize size=TQLabel::minimumSizeHint();
size.setWidth(-1); size.setWidth(-1);
return size; return size;
} }
TQSize tqsizeHint() const { TQSize sizeHint() const {
return TQSize(contentsRect().width(), TQLabel::tqsizeHint().height()); return TQSize(contentsRect().width(), TQLabel::sizeHint().height());
} }
void setText(const TQString& text) { void setText(const TQString& text) {

@ -47,9 +47,9 @@ VTabWidget::VTabWidget(TQWidget* parent)
d->mTabBar->setPosition(KMultiTabBar::Left); d->mTabBar->setPosition(KMultiTabBar::Left);
d->mTabBar->setStyle(KMultiTabBar::KDEV3ICON); d->mTabBar->setStyle(KMultiTabBar::KDEV3ICON);
d->mStack=new TQWidgetStack(this); d->mStack=new TQWidgetStack(this);
TQHBoxLayout* tqlayout=new TQHBoxLayout(this); TQHBoxLayout* layout=new TQHBoxLayout(this);
tqlayout->add(d->mTabBar); layout->add(d->mTabBar);
tqlayout->add(d->mStack); layout->add(d->mStack);
} }

@ -179,7 +179,7 @@ void Cache::addThumbnail( const KURL& url, const TQPixmap& thumbnail, TQSize ima
checkMaxSize(); checkMaxSize();
} }
void Cache::tqinvalidate( const KURL& url ) { void Cache::invalidate( const KURL& url ) {
d->mImages.remove( url ); d->mImages.remove( url );
} }

@ -52,7 +52,7 @@ public:
void getFrames( const KURL& url, ImageFrames* frames, TQCString* format ) const; void getFrames( const KURL& url, ImageFrames* frames, TQCString* format ) const;
TQPixmap thumbnail( const KURL& url, TQSize& imagesize ) const; TQPixmap thumbnail( const KURL& url, TQSize& imagesize ) const;
void setPriorityURL( const KURL& url, bool set ); void setPriorityURL( const KURL& url, bool set );
void tqinvalidate( const KURL& url ); void invalidate( const KURL& url );
void checkThumbnailSize( int size ); void checkThumbnailSize( int size );
void readConfig(KConfig*,const TQString& group); void readConfig(KConfig*,const TQString& group);
void updateAge(); void updateAge();

@ -35,7 +35,7 @@ TQString CaptionFormatter::format(const TQString& format) {
TQString resolution; TQString resolution;
if (mImageSize.isValid()) { if (mImageSize.isValid()) {
resolution = TQString( "%1x%2" ).tqarg( mImageSize.width()).tqarg( mImageSize.height()); resolution = TQString( "%1x%2" ).arg( mImageSize.width()).arg( mImageSize.height());
} }
TQString str=format; TQString str=format;

@ -40,14 +40,14 @@ ClickLineEdit::ClickLineEdit(TQWidget *parent, const char* name ) :
void ClickLineEdit::setClickMessage( const TQString &msg ) void ClickLineEdit::setClickMessage( const TQString &msg )
{ {
mClickMessage = msg; mClickMessage = msg;
tqrepaint(); repaint();
} }
void ClickLineEdit::setText( const TQString &txt ) void ClickLineEdit::setText( const TQString &txt )
{ {
mDrawClickMsg = txt.isEmpty(); mDrawClickMsg = txt.isEmpty();
tqrepaint(); repaint();
KLineEdit::setText( txt ); KLineEdit::setText( txt );
} }
@ -86,7 +86,7 @@ void ClickLineEdit::focusInEvent( TQFocusEvent *ev )
{ {
if ( mDrawClickMsg == true ) { if ( mDrawClickMsg == true ) {
mDrawClickMsg = false; mDrawClickMsg = false;
tqrepaint(); repaint();
} }
TQLineEdit::focusInEvent( ev ); TQLineEdit::focusInEvent( ev );
} }
@ -96,7 +96,7 @@ void ClickLineEdit::focusOutEvent( TQFocusEvent *ev )
{ {
if ( text().isEmpty() ) { if ( text().isEmpty() ) {
mDrawClickMsg = true; mDrawClickMsg = true;
tqrepaint(); repaint();
} }
TQLineEdit::focusOutEvent( ev ); TQLineEdit::focusOutEvent( ev );
} }

@ -79,7 +79,7 @@ TipTracker::TipTracker(const TQString& txt, TQWidget* reference)
setPalette(TQToolTip::palette()); setPalette(TQToolTip::palette());
setFrameStyle(TQFrame::Plain | TQFrame::Box); setFrameStyle(TQFrame::Plain | TQFrame::Box);
setLineWidth(1); setLineWidth(1);
tqsetAlignment(AlignAuto | AlignTop); setAlignment(AlignAuto | AlignTop);
} }

@ -26,7 +26,7 @@
#include <tqstringlist.h> #include <tqstringlist.h>
#include <tqcheckbox.h> #include <tqcheckbox.h>
#include <tqlayout.h> #include <layout.h>
#include <tqlabel.h> #include <tqlabel.h>
#include <tqtimer.h> #include <tqtimer.h>
#include <tqvbox.h> #include <tqvbox.h>
@ -113,9 +113,9 @@ bool DeleteDialog::shouldDelete() const {
} }
TQSize DeleteDialog::tqsizeHint() const { TQSize DeleteDialog::sizeHint() const {
m_widget->adjustSize(); m_widget->adjustSize();
TQSize hint = m_widget->tqminimumSize(); TQSize hint = m_widget->minimumSize();
hint = calculateSize(hint.width(), hint.height()); hint = calculateSize(hint.width(), hint.height());
// For some reason calculateSize does not return a correct height. As I'm // For some reason calculateSize does not return a correct height. As I'm

@ -36,7 +36,7 @@ public:
void setURLList(const KURL::List &files); void setURLList(const KURL::List &files);
bool shouldDelete() const; bool shouldDelete() const;
TQSize tqsizeHint() const; TQSize sizeHint() const;
protected slots: protected slots:
virtual void accept(); virtual void accept();

@ -21,7 +21,7 @@
</property> </property>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout3</cstring> <cstring>layout3</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">
@ -47,7 +47,7 @@
<property name="name"> <property name="name">
<cstring>ddDeleteText</cstring> <cstring>ddDeleteText</cstring>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>0</width> <width>0</width>
<height>60</height> <height>60</height>
@ -56,7 +56,7 @@
<property name="text"> <property name="text">
<string>Deletion method placeholder, not in GUI</string> <string>Deletion method placeholder, not in GUI</string>
</property> </property>
<property name="tqalignment"> <property name="alignment">
<set>WordBreak|AlignCenter</set> <set>WordBreak|AlignCenter</set>
</property> </property>
</widget> </widget>
@ -80,7 +80,7 @@
<property name="text"> <property name="text">
<string>Placeholder for number of files, not in GUI</string> <string>Placeholder for number of files, not in GUI</string>
</property> </property>
<property name="tqalignment"> <property name="alignment">
<set>AlignVCenter|AlignRight</set> <set>AlignVCenter|AlignRight</set>
</property> </property>
</widget> </widget>

@ -343,7 +343,7 @@ void Document::slotLoaded() {
// //
//--------------------------------------------------------------------- //---------------------------------------------------------------------
void Document::reload() { void Document::reload() {
Cache::instance()->tqinvalidate( url()); Cache::instance()->invalidate( url());
load(); load();
emit reloaded(url()); emit reloaded(url());
} }
@ -378,7 +378,7 @@ void Document::doPaint(KPrinter *printer, TQPainter *painter) {
TQString t = "true"; TQString t = "true";
TQString f = "false"; TQString f = "false";
int tqalignment = (printer->option("app-gwenview-position").isEmpty() ? int alignment = (printer->option("app-gwenview-position").isEmpty() ?
TQt::AlignCenter : printer->option("app-gwenview-position").toInt()); TQt::AlignCenter : printer->option("app-gwenview-position").toInt());
// Compute filename offset // Compute filename offset
@ -407,7 +407,7 @@ void Document::doPaint(KPrinter *printer, TQPainter *painter) {
if (scaling==GV_FITTOPAGE /* Fit to page */) { if (scaling==GV_FITTOPAGE /* Fit to page */) {
bool enlargeToFit = printer->option( "app-gwenview-enlargeToFit" ) != f; bool enlargeToFit = printer->option( "app-gwenview-enlargeToFit" ) != f;
if ((image.width() > pdWidth || image.height() > pdHeight) || enlargeToFit) { if ((image.width() > pdWidth || image.height() > pdHeight) || enlargeToFit) {
size.tqscale( pdWidth, pdHeight, TQSize::ScaleMin ); size.scale( pdWidth, pdHeight, TQSize::ScaleMin );
} }
} else { } else {
if (scaling==GV_SCALE /* Scale To */) { if (scaling==GV_SCALE /* Scale To */) {
@ -452,24 +452,24 @@ void Document::doPaint(KPrinter *printer, TQPainter *painter) {
printer->abort(); printer->abort();
return; return;
} else if (resp == KMessageBox::No) { // Shrink } else if (resp == KMessageBox::No) { // Shrink
size.tqscale(pdWidth, pdHeight, TQSize::ScaleMin); size.scale(pdWidth, pdHeight, TQSize::ScaleMin);
} }
} }
} }
// Compute x and y // Compute x and y
if ( tqalignment & TQt::AlignHCenter ) if ( alignment & TQt::AlignHCenter )
x = (pdWidth - size.width())/2; x = (pdWidth - size.width())/2;
else if ( tqalignment & TQt::AlignLeft ) else if ( alignment & TQt::AlignLeft )
x = 0; x = 0;
else if ( tqalignment & TQt::AlignRight ) else if ( alignment & TQt::AlignRight )
x = pdWidth - size.width(); x = pdWidth - size.width();
if ( tqalignment & TQt::AlignVCenter ) if ( alignment & TQt::AlignVCenter )
y = (pdHeight - size.height())/2; y = (pdHeight - size.height())/2;
else if ( tqalignment & TQt::AlignTop ) else if ( alignment & TQt::AlignTop )
y = 0; y = 0;
else if ( tqalignment & TQt::AlignBottom ) else if ( alignment & TQt::AlignBottom )
y = pdHeight - size.height(); y = pdHeight - size.height();
// Draw, the image will be scaled to fit the given area if necessary // Draw, the image will be scaled to fit the given area if necessary
@ -532,7 +532,7 @@ void Document::saveBeforeClosing() {
if (!d->mModified) return; if (!d->mModified) return;
TQString msg=i18n("<qt>The image <b>%1</b> has been modified, do you want to save the changes?</qt>") TQString msg=i18n("<qt>The image <b>%1</b> has been modified, do you want to save the changes?</qt>")
.tqarg(url().prettyURL()); .arg(url().prettyURL());
int result=KMessageBox::questionYesNo(dialogParentWidget(), msg, TQString(), int result=KMessageBox::questionYesNo(dialogParentWidget(), msg, TQString(),
KStdGuiItem::save(), KStdGuiItem::discard(), CONFIG_SAVE_AUTOMATICALLY); KStdGuiItem::save(), KStdGuiItem::discard(), CONFIG_SAVE_AUTOMATICALLY);
@ -605,7 +605,7 @@ TQString Document::saveInternal(const KURL& url, const TQCString& format) {
LOG("Save failed: " << msg); LOG("Save failed: " << msg);
return TQString("<qt><b>%1</b><br/>") return TQString("<qt><b>%1</b><br/>")
.tqarg(i18n("Could not save the image to %1.").tqarg(url.prettyURL())) .arg(i18n("Could not save the image to %1.").arg(url.prettyURL()))
+ msg + "</qt>"; + msg + "</qt>";
} }

@ -134,7 +134,7 @@ TQString DocumentLoadedImpl::save(const KURL& _url, const TQCString& format) con
if (!parent.isWritable()) { if (!parent.isWritable()) {
return return
i18n("The %1 folder is read-only.") i18n("The %1 folder is read-only.")
.tqarg(parent.filePath()); .arg(parent.filePath());
} }
} }
} }
@ -152,7 +152,7 @@ TQString DocumentLoadedImpl::save(const KURL& _url, const TQCString& format) con
if (tmp.status()!=0) { if (tmp.status()!=0) {
TQString reason( strerror(tmp.status()) ); TQString reason( strerror(tmp.status()) );
return i18n("Could not create a temporary file.\nReason: %1.") return i18n("Could not create a temporary file.\nReason: %1.")
.tqarg(reason); .arg(reason);
} }
TQFile* file=tmp.file(); TQFile* file=tmp.file();
msg=localSave(file, format); msg=localSave(file, format);
@ -162,7 +162,7 @@ TQString DocumentLoadedImpl::save(const KURL& _url, const TQCString& format) con
if (tmp.status()!=0) { if (tmp.status()!=0) {
TQString reason( strerror(tmp.status()) ); TQString reason( strerror(tmp.status()) );
return i18n("Saving image to a temporary file failed.\nReason: %1.") return i18n("Saving image to a temporary file failed.\nReason: %1.")
.tqarg(reason); .arg(reason);
} }
TQString tmpName=tmp.name(); TQString tmpName=tmp.name();
@ -172,11 +172,11 @@ TQString DocumentLoadedImpl::save(const KURL& _url, const TQCString& format) con
// Move the tmp file to the final dest // Move the tmp file to the final dest
if (url.isLocalFile()) { if (url.isLocalFile()) {
if( ::rename( TQFile::encodeName(tmpName), TQFile::encodeName( url.path())) < 0 ) { if( ::rename( TQFile::encodeName(tmpName), TQFile::encodeName( url.path())) < 0 ) {
return i18n("Could not write to %1.").tqarg(url.path()); return i18n("Could not write to %1.").arg(url.path());
} }
} else { } else {
if (!KIO::NetAccess::upload(tmp.name(), url, KApplication::kApplication()->mainWidget() )) { if (!KIO::NetAccess::upload(tmp.name(), url, KApplication::kApplication()->mainWidget() )) {
return i18n("Could not upload the file to %1.").tqarg(url.prettyURL()); return i18n("Could not upload the file to %1.").arg(url.prettyURL());
} }
} }

@ -99,7 +99,7 @@ void DocumentLoadingImpl::init() {
emitImageRectUpdated(); emitImageRectUpdated();
} else { } else {
setImage(image); setImage(image);
TQMemArray< TQRect > rects = TQRegion(d->mLoader->loadedRegion()).tqrects(); TQMemArray< TQRect > rects = TQRegion(d->mLoader->loadedRegion()).rects();
for( unsigned int i = 0; i < rects.count(); ++i ) { for( unsigned int i = 0; i < rects.count(); ++i ) {
emit rectUpdated(rects[i]); emit rectUpdated(rects[i]);
} }

@ -128,7 +128,7 @@ public:
if (listCropped) { if (listCropped) {
// If list has been cropped, leave space for item count text // If list has been cropped, leave space for item count text
height += fm.height(); height += fm.height();
bottomText = i18n("%1 items").tqarg(mItemList.count()); bottomText = i18n("%1 items").arg(mItemList.count());
width = TQMAX(width, fm.width("... " + bottomText)); width = TQMAX(width, fm.width("... " + bottomText));
} }

@ -144,7 +144,7 @@ struct ExternalToolDialogPrivate {
for (; item; item=item->nextSibling()) { for (; item; item=item->nextSibling()) {
if (item==mSelectedItem) continue; if (item==mSelectedItem) continue;
if (name==item->text(0)) { if (name==item->text(0)) {
KMessageBox::sorry(mContent, i18n("There is already a tool named \"%1\"").tqarg(name)); KMessageBox::sorry(mContent, i18n("There is already a tool named \"%1\"").arg(name));
return false; return false;
} }
} }

@ -20,7 +20,7 @@
<verstretch>0</verstretch> <verstretch>0</verstretch>
</sizepolicy> </sizepolicy>
</property> </property>
<property name="tqminimumSize"> <property name="minimumSize">
<size> <size>
<width>720</width> <width>720</width>
<height>0</height> <height>0</height>
@ -49,7 +49,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>487</width> <width>487</width>
<height>16</height> <height>16</height>
@ -153,7 +153,7 @@
</widget> </widget>
<widget class="TQLayoutWidget" row="0" column="0"> <widget class="TQLayoutWidget" row="0" column="0">
<property name="name"> <property name="name">
<cstring>tqlayout3</cstring> <cstring>layout3</cstring>
</property> </property>
<grid> <grid>
<property name="name"> <property name="name">
@ -304,7 +304,7 @@ You can use keywords in the Command field:
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>140</height> <height>140</height>

@ -222,7 +222,7 @@ TQDict<KDesktopFile>& ExternalToolManager::desktopFiles() const {
void ExternalToolManager::hideDesktopFile(KDesktopFile* desktopFile) { void ExternalToolManager::hideDesktopFile(KDesktopFile* desktopFile) {
TQFileInfo fi(desktopFile->fileName()); TQFileInfo fi(desktopFile->fileName());
TQString name=TQString("%1.desktop").tqarg( fi.baseName(true) ); TQString name=TQString("%1.desktop").arg( fi.baseName(true) );
d->mDesktopFiles.take(name); d->mDesktopFiles.take(name);
if (desktopFile->isReadOnly()) { if (desktopFile->isReadOnly()) {
@ -240,7 +240,7 @@ KDesktopFile* ExternalToolManager::editSystemDesktopFile(const KDesktopFile* des
TQFileInfo fi(desktopFile->fileName()); TQFileInfo fi(desktopFile->fileName());
TQString name=fi.baseName(true); TQString name=fi.baseName(true);
d->mDesktopFiles.remove(TQString("%1.desktop").tqarg(name)); d->mDesktopFiles.remove(TQString("%1.desktop").arg(name));
return createUserDesktopFile(name); return createUserDesktopFile(name);
} }
@ -250,7 +250,7 @@ KDesktopFile* ExternalToolManager::createUserDesktopFile(const TQString& name) {
Q_ASSERT(!name.isEmpty()); Q_ASSERT(!name.isEmpty());
KDesktopFile* desktopFile=new KDesktopFile( KDesktopFile* desktopFile=new KDesktopFile(
d->mUserToolDir + "/" + name + ".desktop", false); d->mUserToolDir + "/" + name + ".desktop", false);
d->mDesktopFiles.insert(TQString("%1.desktop").tqarg(name), desktopFile); d->mDesktopFiles.insert(TQString("%1.desktop").arg(name), desktopFile);
return desktopFile; return desktopFile;
} }

@ -125,8 +125,8 @@ FileDetailView::FileDetailView(TQWidget *parent, const char *name)
setDropHighlighter(false); setDropHighlighter(false);
int size = IconSize(KIcon::Small); int size = IconSize(KIcon::Small);
mShownItemUnselectedPixmap = createShownItemPixmap(size, tqcolorGroup().highlight()); mShownItemUnselectedPixmap = createShownItemPixmap(size, colorGroup().highlight());
mShownItemSelectedPixmap = createShownItemPixmap(size, tqcolorGroup().highlightedText()); mShownItemSelectedPixmap = createShownItemPixmap(size, colorGroup().highlightedText());
} }
@ -525,8 +525,8 @@ void FileDetailView::setShownFileItem(KFileItem* fileItem)
FileDetailViewItem* newShownItem=viewItem(fileItem); FileDetailViewItem* newShownItem=viewItem(fileItem);
FileViewBase::setShownFileItem(fileItem); FileViewBase::setShownFileItem(fileItem);
if (oldShownItem) oldShownItem->tqrepaint(); if (oldShownItem) oldShownItem->repaint();
if (newShownItem) newShownItem->tqrepaint(); if (newShownItem) newShownItem->repaint();
} }

@ -71,7 +71,7 @@ public:
TQRect rect() const TQRect rect() const
{ {
TQRect r = listView()->tqitemRect(this); TQRect r = listView()->itemRect(this);
return TQRect( listView()->viewportToContents( r.topLeft() ), return TQRect( listView()->viewportToContents( r.topLeft() ),
TQSize( r.width(), r.height() ) ); TQSize( r.width(), r.height() ) );
} }

@ -21,7 +21,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// TQt // TQt
#include <tqfile.h> #include <tqfile.h>
#include <tqstylesheet.h> #include <stylesheet.h>
#include <tqwidget.h> #include <tqwidget.h>
// KDE // KDE
@ -89,7 +89,7 @@ void FileOpObject::slotResult(KIO::Job* job) {
void FileOpObject::polishJob(KIO::Job* job) { void FileOpObject::polishJob(KIO::Job* job) {
job->setWindow(mParent->tqtopLevelWidget()); job->setWindow(mParent->topLevelWidget());
connect( job, TQT_SIGNAL( result(KIO::Job*) ), connect( job, TQT_SIGNAL( result(KIO::Job*) ),
this, TQT_SLOT( slotResult(KIO::Job*) ) ); this, TQT_SLOT( slotResult(KIO::Job*) ) );
} }
@ -259,7 +259,7 @@ void FileOpTrashObject::operator()() {
} else { } else {
TQString filename=TQStyleSheet::escape(mURLList.first().filename()); TQString filename=TQStyleSheet::escape(mURLList.first().filename());
response=KMessageBox::warningContinueCancel(mParent, response=KMessageBox::warningContinueCancel(mParent,
i18n("<p>Do you really want to move <b>%1</b> to the trash?</p>").tqarg(filename),i18n("Trash used as a verb", "Trash File"),KGuiItem(i18n("Trash used as a verb", "&Trash"),"edittrash")); i18n("<p>Do you really want to move <b>%1</b> to the trash?</p>").arg(filename),i18n("Trash used as a verb", "Trash File"),KGuiItem(i18n("Trash used as a verb", "&Trash"),"edittrash"));
} }
if (response!=KMessageBox::Continue) return; if (response!=KMessageBox::Continue) return;
} }
@ -287,7 +287,7 @@ void FileOpRealDeleteObject::operator()() {
} else { } else {
TQString filename=TQStyleSheet::escape(mURLList.first().filename()); TQString filename=TQStyleSheet::escape(mURLList.first().filename());
response=KMessageBox::warningContinueCancel(mParent, response=KMessageBox::warningContinueCancel(mParent,
i18n("<p>Do you really want to delete <b>%1</b>?</p>").tqarg(filename), i18n("<p>Do you really want to delete <b>%1</b>?</p>").arg(filename),
i18n("Delete File"), i18n("Delete File"),
KStdGuiItem::del() KStdGuiItem::del()
); );
@ -309,7 +309,7 @@ void FileOpRenameObject::operator()() {
TQString filename = srcURL.filename(); TQString filename = srcURL.filename();
InputDialog dlg(mParent); InputDialog dlg(mParent);
dlg.setCaption(i18n("Renaming File")); dlg.setCaption(i18n("Renaming File"));
dlg.setLabel(i18n("<p>Rename file <b>%1</b> to:</p>").tqarg(TQStyleSheet::escape(filename))); dlg.setLabel(i18n("<p>Rename file <b>%1</b> to:</p>").arg(TQStyleSheet::escape(filename)));
dlg.setButtonOK( KGuiItem(i18n("&Rename"), "edit") ); dlg.setButtonOK( KGuiItem(i18n("&Rename"), "edit") );
dlg.lineEdit()->setText(filename); dlg.lineEdit()->setText(filename);

@ -21,7 +21,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// TQt // TQt
#include <tqframe.h> #include <tqframe.h>
#include <tqlayout.h> #include <layout.h>
#include <tqpainter.h> #include <tqpainter.h>
#include <tqpen.h> #include <tqpen.h>
#include <tqpixmap.h> #include <tqpixmap.h>
@ -77,8 +77,8 @@ public:
ProgressWidget(FileThumbnailView* view, int count) ProgressWidget(FileThumbnailView* view, int count)
: TQFrame(view) : TQFrame(view)
{ {
TQHBoxLayout* tqlayout=new TQHBoxLayout(this, 3, 3); TQHBoxLayout* layout=new TQHBoxLayout(this, 3, 3);
tqlayout->setAutoAdd(true); layout->setAutoAdd(true);
setFrameStyle( TQFrame::StyledPanel | TQFrame::Raised ); setFrameStyle( TQFrame::StyledPanel | TQFrame::Raised );
mStop=new TQPushButton(this); mStop=new TQPushButton(this);
@ -93,7 +93,7 @@ public:
void polish() { void polish() {
TQFrame::polish(); TQFrame::polish();
setMinimumWidth(tqlayout()->tqminimumSize().width()); setMinimumWidth(layout()->minimumSize().width());
//setFixedHeight( mProgressBar->height() ); //setFixedHeight( mProgressBar->height() );
setFixedHeight( mStop->height() ); setFixedHeight( mStop->height() );
} }
@ -142,7 +142,7 @@ struct FileThumbnailView::Private {
mWaitThumbnail.fill(view->paletteBackgroundColor()); mWaitThumbnail.fill(view->paletteBackgroundColor());
TQPainter painter(&mWaitThumbnail); TQPainter painter(&mWaitThumbnail);
painter.setPen(view->tqcolorGroup().button()); painter.setPen(view->colorGroup().button());
painter.drawRect(0,0,mThumbnailSize,mThumbnailSize); painter.drawRect(0,0,mThumbnailSize,mThumbnailSize);
painter.drawPixmap( painter.drawPixmap(
(mThumbnailSize-mWaitPixmap.width())/2, (mThumbnailSize-mWaitPixmap.width())/2,
@ -285,7 +285,7 @@ void FileThumbnailView::setThumbnailPixmap(const KFileItem* fileItem, const TQPi
if (size.isValid()) { if (size.isValid()) {
iconItem->setImageSize(size); iconItem->setImageSize(size);
} }
iconItem->tqrepaint(); iconItem->repaint();
// Notify progress // Notify progress
if (d->mProgressWidget) { if (d->mProgressWidget) {

@ -271,16 +271,16 @@ void FileThumbnailViewItem::calcRect(const TQString&) {
textH+=(*it)->height(); textH+=(*it)->height();
} }
TQRect tqitemRect(x(), y(), view->gridX(), 0); TQRect itemRect(x(), y(), view->gridX(), 0);
TQRect itemPixmapRect(PADDING, PADDING, thumbnailSize, thumbnailSize); TQRect itemPixmapRect(PADDING, PADDING, thumbnailSize, thumbnailSize);
TQRect itemTextRect(0, 0, textW, textH); TQRect itemTextRect(0, 0, textW, textH);
if (isRight) { if (isRight) {
tqitemRect.setHeight( TQMAX(thumbnailSize + PADDING*2, textH) ); itemRect.setHeight( TQMAX(thumbnailSize + PADDING*2, textH) );
itemTextRect.moveLeft(thumbnailSize + PADDING * 2 ); itemTextRect.moveLeft(thumbnailSize + PADDING * 2 );
itemTextRect.moveTop((tqitemRect.height() - textH)/2); itemTextRect.moveTop((itemRect.height() - textH)/2);
} else { } else {
itemPixmapRect.moveLeft( (tqitemRect.width() - itemPixmapRect.width()) / 2 ); itemPixmapRect.moveLeft( (itemRect.width() - itemPixmapRect.width()) / 2 );
tqitemRect.setHeight(thumbnailSize + PADDING*3 + textH); itemRect.setHeight(thumbnailSize + PADDING*3 + textH);
itemTextRect.moveLeft(PADDING); itemTextRect.moveLeft(PADDING);
itemTextRect.moveTop(thumbnailSize + PADDING * 2); itemTextRect.moveTop(thumbnailSize + PADDING * 2);
} }
@ -292,8 +292,8 @@ void FileThumbnailViewItem::calcRect(const TQString&) {
if ( itemTextRect != textRect() ) { if ( itemTextRect != textRect() ) {
setTextRect( itemTextRect ); setTextRect( itemTextRect );
} }
if ( tqitemRect != rect() ) { if ( itemRect != rect() ) {
setItemRect( tqitemRect ); setItemRect( itemRect );
} }
} }

@ -52,7 +52,7 @@ public:
void updateLines(); void updateLines();
protected: protected:
void paintItem(TQPainter* painter, const TQColorGroup& tqcolorGroup); void paintItem(TQPainter* painter, const TQColorGroup& colorGroup);
void calcRect( const TQString& text_=TQString() ); void calcRect( const TQString& text_=TQString() );
void paintFocus(TQPainter*, const TQColorGroup&) {} void paintFocus(TQPainter*, const TQColorGroup&) {}
bool acceptDrop(const TQMimeSource*) const; bool acceptDrop(const TQMimeSource*) const;

@ -23,7 +23,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#include <tqcheckbox.h> #include <tqcheckbox.h>
#include <tqdatetimeedit.h> #include <tqdatetimeedit.h>
#include <tqhbox.h> #include <tqhbox.h>
#include <tqlayout.h> #include <layout.h>
#include <tqpopupmenu.h> #include <tqpopupmenu.h>
#include <tqpushbutton.h> #include <tqpushbutton.h>
#include <tqtooltip.h> #include <tqtooltip.h>
@ -191,7 +191,7 @@ public:
void initFilterBar() { void initFilterBar() {
mFilterBar=new FilterBar(that); mFilterBar=new FilterBar(that);
mFilterBar->tqsetSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed); mFilterBar->setSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed);
mFilterBar->hide(); mFilterBar->hide();
TQIconSet resetIS=BarIcon("locationbar_erase"); TQIconSet resetIS=BarIcon("locationbar_erase");
@ -256,7 +256,7 @@ FileViewController::FileViewController(TQWidget* parent,KActionCollection* actio
: TQWidget(parent) : TQWidget(parent)
, mMode(FILE_LIST) , mMode(FILE_LIST)
, mPrefetch( NULL ) , mPrefetch( NULL )
, mChangeDirtqStatus(CHANGE_DIR_STATUS_NONE) , mChangeDirStatus(CHANGE_DIR_STATUS_NONE)
, mBrowsing(false) , mBrowsing(false)
, mSelecting(false) , mSelecting(false)
{ {
@ -268,10 +268,10 @@ FileViewController::FileViewController(TQWidget* parent,KActionCollection* actio
d->initFilterCombo(); d->initFilterCombo();
d->mStack=new TQWidgetStack(this); d->mStack=new TQWidgetStack(this);
TQVBoxLayout *tqlayout=new TQVBoxLayout(this); TQVBoxLayout *layout=new TQVBoxLayout(this);
tqlayout->addWidget(d->mToolBar); layout->addWidget(d->mToolBar);
tqlayout->addWidget(d->mFilterBar); layout->addWidget(d->mFilterBar);
tqlayout->addWidget(d->mStack); layout->addWidget(d->mStack);
// Actions // Actions
mSelectFirst=new KAction(i18n("&First"), mSelectFirst=new KAction(i18n("&First"),
@ -338,7 +338,7 @@ FileViewController::FileViewController(TQWidget* parent,KActionCollection* actio
// Dir lister // Dir lister
mDirLister=new DirLister; mDirLister=new DirLister;
mDirLister->setMainWindow(tqtopLevelWidget()); mDirLister->setMainWindow(topLevelWidget());
connect(mDirLister,TQT_SIGNAL(clear()), connect(mDirLister,TQT_SIGNAL(clear()),
TQT_TQOBJECT(this),TQT_SLOT(dirListerClear()) ); TQT_TQOBJECT(this),TQT_SLOT(dirListerClear()) );
@ -575,13 +575,13 @@ void FileViewController::slotSelectNext() {
} }
void FileViewController::slotSelectPreviousDir() { void FileViewController::slotSelectPreviousDir() {
mChangeDirtqStatus = CHANGE_DIR_STATUS_PREV; mChangeDirStatus = CHANGE_DIR_STATUS_PREV;
mDirLister->clearError(); mDirLister->clearError();
mDirLister->openURL(mDirURL.upURL()); mDirLister->openURL(mDirURL.upURL());
} }
void FileViewController::slotSelectNextDir() { void FileViewController::slotSelectNextDir() {
mChangeDirtqStatus = CHANGE_DIR_STATUS_NEXT; mChangeDirStatus = CHANGE_DIR_STATUS_NEXT;
mDirLister->clearError(); mDirLister->clearError();
mDirLister->openURL(mDirURL.upURL()); mDirLister->openURL(mDirURL.upURL());
} }
@ -747,7 +747,7 @@ void FileViewController::updateViewMode() {
void FileViewController::updateThumbnailSize(int size) { void FileViewController::updateThumbnailSize(int size) {
size*=SLIDER_RESOLUTION; size*=SLIDER_RESOLUTION;
d->mSliderTracker->setText(i18n("Thumbnail size: %1x%2").tqarg(size).tqarg(size)); d->mSliderTracker->setText(i18n("Thumbnail size: %1x%2").arg(size).arg(size));
FileViewConfig::setThumbnailSize(size); FileViewConfig::setThumbnailSize(size);
mFileThumbnailView->setThumbnailSize(size); mFileThumbnailView->setThumbnailSize(size);
Cache::instance()->checkThumbnailSize(size); Cache::instance()->checkThumbnailSize(size);
@ -1102,12 +1102,12 @@ void FileViewController::delayedDirListerCompleted() {
mFileThumbnailView->sort(mFileThumbnailView->sortDirection()); mFileThumbnailView->sort(mFileThumbnailView->sortDirection());
} }
if (mChangeDirtqStatus != CHANGE_DIR_STATUS_NONE) { if (mChangeDirStatus != CHANGE_DIR_STATUS_NONE) {
KFileItem *item; KFileItem *item;
TQString fileName = mDirURL.filename(); TQString fileName = mDirURL.filename();
for (item=currentFileView()->firstFileItem(); item; item=currentFileView()->nextItem(item) ) { for (item=currentFileView()->firstFileItem(); item; item=currentFileView()->nextItem(item) ) {
if (item->name() == fileName) { if (item->name() == fileName) {
if (mChangeDirtqStatus == CHANGE_DIR_STATUS_NEXT) { if (mChangeDirStatus == CHANGE_DIR_STATUS_NEXT) {
do { do {
item=currentFileView()->nextItem(item); item=currentFileView()->nextItem(item);
} while (item && !Archive::fileItemIsDirOrArchive(item)); } while (item && !Archive::fileItemIsDirOrArchive(item));
@ -1119,7 +1119,7 @@ void FileViewController::delayedDirListerCompleted() {
break; break;
}; };
} }
mChangeDirtqStatus = CHANGE_DIR_STATUS_NONE; mChangeDirStatus = CHANGE_DIR_STATUS_NONE;
if (!item) { if (!item) {
mDirLister->openURL(mDirURL); mDirLister->openURL(mDirURL);
} else { } else {

@ -227,7 +227,7 @@ private:
CHANGE_DIR_STATUS_NONE, CHANGE_DIR_STATUS_NONE,
CHANGE_DIR_STATUS_PREV, CHANGE_DIR_STATUS_PREV,
CHANGE_DIR_STATUS_NEXT CHANGE_DIR_STATUS_NEXT
} mChangeDirtqStatus; } mChangeDirStatus;
bool mBrowsing; bool mBrowsing;
bool mSelecting; bool mSelecting;

@ -64,7 +64,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Maximum</enum> <enum>Maximum</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>16</width> <width>16</width>
<height>16</height> <height>16</height>
@ -125,7 +125,7 @@ equal to this date</string>
<property name="sizeType"> <property name="sizeType">
<enum>Maximum</enum> <enum>Maximum</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>16</width> <width>16</width>
<height>16</height> <height>16</height>
@ -185,7 +185,7 @@ equal to this date</string>
<property name="sizeType"> <property name="sizeType">
<enum>Maximum</enum> <enum>Maximum</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>16</width> <width>16</width>
<height>16</height> <height>16</height>
@ -210,7 +210,7 @@ equal to this date</string>
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>16</width> <width>16</width>
<height>16</height> <height>16</height>

@ -21,7 +21,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// TQt // TQt
#include <tqbitmap.h> #include <tqbitmap.h>
#include <tqevent.h> #include <tqevent.h>
#include <tqlayout.h> #include <layout.h>
#include <tqpainter.h> #include <tqpainter.h>
#include <tqtimer.h> #include <tqtimer.h>
@ -83,8 +83,8 @@ FullScreenBar::FullScreenBar(TQWidget* parent)
setIconSize(FULLSCREEN_ICON_SIZE); setIconSize(FULLSCREEN_ICON_SIZE);
setMovingEnabled(false); setMovingEnabled(false);
TQColor bg=tqcolorGroup().highlight(); TQColor bg=colorGroup().highlight();
TQColor fg=tqcolorGroup().highlightedText(); TQColor fg=colorGroup().highlightedText();
TQPalette pal(palette()); TQPalette pal(palette());
pal.setColor(TQColorGroup::Background, bg); pal.setColor(TQColorGroup::Background, bg);
pal.setColor(TQColorGroup::Foreground, fg); pal.setColor(TQColorGroup::Foreground, fg);
@ -123,7 +123,7 @@ void FullScreenBar::showEvent(TQShowEvent* event) {
if (!d->mFirstShow) return; if (!d->mFirstShow) return;
d->mFirstShow=false; d->mFirstShow=false;
move(0, -height()); move(0, -height());
tqlayout()->setResizeMode(TQLayout::Fixed); layout()->setResizeMode(TQLayout::Fixed);
} }

@ -113,7 +113,7 @@ public:
int getch() { int getch() {
if (mThread->testCancel()) { if (mThread->testCancel()) {
LOG("cancel detected"); LOG("cancel detected");
setqStatus(IO_ReadError); seStatus(IO_ReadError);
return -1; return -1;
} }
return TQBuffer::getch(); return TQBuffer::getch();

@ -70,7 +70,7 @@ ImageSaveDialog::ImageSaveDialog(KURL& url, const TQCString& imageFormat, TQWidg
if (!patterns.contains(pattern)) patterns.append(pattern); if (!patterns.contains(pattern)) patterns.append(pattern);
} }
if (patterns.isEmpty()) { if (patterns.isEmpty()) {
patterns.append( TQString("*.%1").tqarg(format.lower()) ); patterns.append( TQString("*.%1").arg(format.lower()) );
} }
TQString patternString=patterns.join(" "); TQString patternString=patterns.join(" ");

@ -113,7 +113,7 @@ as approximate as possible). However when converting from widget to image and ba
this can result in the final rectangle being smaller than the original. this can result in the final rectangle being smaller than the original.
The widgetToImageBounding() function converts from widget to image coordinates The widgetToImageBounding() function converts from widget to image coordinates
in a way which makes sure the reverse conversion will be at least as large in a way which makes sure the reverse conversion will be at least as large
as the original tqgeometry. as the original geometry.
There are no conversion functions for only width/height, as their conversion There are no conversion functions for only width/height, as their conversion
depends on the position (because of the rounding etc.). For similar reasons depends on the position (because of the rounding etc.). For similar reasons
@ -257,7 +257,7 @@ struct ImageView::Private {
const double zoomValues[] = { 0.5, 1, 2 }; const double zoomValues[] = { 0.5, 1, 2 };
int nbValues=sizeof(zoomValues) / sizeof(double); int nbValues=sizeof(zoomValues) / sizeof(double);
for (int pos=0; pos<nbValues; ++pos) { for (int pos=0; pos<nbValues; ++pos) {
TQString txt=TQString("%1%").tqarg( int(zoomValues[pos]*100) ); TQString txt=TQString("%1%").arg( int(zoomValues[pos]*100) );
mZoomCombo->insertItem(txt); mZoomCombo->insertItem(txt);
} }
} }
@ -423,7 +423,7 @@ ImageView::~ImageView() {
void ImageView::slotLoaded() { void ImageView::slotLoaded() {
if (d->mDocument->isNull()) { if (d->mDocument->isNull()) {
resizeContents(0,0); resizeContents(0,0);
viewport()->tqrepaint(false); viewport()->repaint(false);
return; return;
} }
@ -488,7 +488,7 @@ KToggleAction* ImageView::zoomToFit() const {
void ImageView::updateFromSettings() { void ImageView::updateFromSettings() {
// Reset, so that next tqrepaint doesn't possibly take longer because of // Reset, so that next repaint doesn't possibly take longer because of
// smoothing // smoothing
ImageViewConfig::setMaxRepaintSize(DEFAULT_MAX_REPAINT_SIZE); ImageViewConfig::setMaxRepaintSize(DEFAULT_MAX_REPAINT_SIZE);
ImageViewConfig::setMaxScaleRepaintSize(DEFAULT_MAX_REPAINT_SIZE); ImageViewConfig::setMaxScaleRepaintSize(DEFAULT_MAX_REPAINT_SIZE);
@ -625,7 +625,7 @@ void ImageView::drawContents(TQPainter* painter,int clipx,int clipy,int clipw,in
TQRect widgetRect = TQRect(0, 0, visibleWidth(), visibleHeight()); TQRect widgetRect = TQRect(0, 0, visibleWidth(), visibleHeight());
TQRegion region = TQRegion(widgetRect) - imageRect; TQRegion region = TQRegion(widgetRect) - imageRect;
TQMemArray<TQRect> rects = region.tqrects(); TQMemArray<TQRect> rects = region.rects();
for(unsigned int pos = 0; pos < rects.count(); ++pos ) { for(unsigned int pos = 0; pos < rects.count(); ++pos ) {
painter->eraseRect(rects[pos]); painter->eraseRect(rects[pos]);
} }
@ -701,7 +701,7 @@ void ImageView::limitPaintSize( PendingPaint& paint ) {
// don't paint more than max_size pixels at a time // don't paint more than max_size pixels at a time
int maxHeight = ( maxSize + paint.rect.width() - 1 ) / paint.rect.width(); // round up int maxHeight = ( maxSize + paint.rect.width() - 1 ) / paint.rect.width(); // round up
maxHeight = TQMAX( maxHeight, 5 ); // at least 5 lines together maxHeight = TQMAX( maxHeight, 5 ); // at least 5 lines together
// can't tqrepaint whole paint at once, adjust height and schedule the rest // can't repaint whole paint at once, adjust height and schedule the rest
if( maxHeight < paint.rect.height()) { if( maxHeight < paint.rect.height()) {
TQRect remaining = paint.rect; TQRect remaining = paint.rect;
remaining.setTop( remaining.top() + maxHeight ); remaining.setTop( remaining.top() + maxHeight );
@ -781,12 +781,12 @@ void ImageView::slotBusyLevelChanged( BusyLevel level ) {
// How to do painting: // How to do painting:
// When something needs to be erased: TQPainter on viewport and eraseRect() // When something needs to be erased: TQPainter on viewport and eraseRect()
// When whole picture needs to be repainted: fullRepaint() // When whole picture needs to be repainted: fullRepaint()
// When a part of the picture needs to be updated: viewport()->tqrepaint(area,false) // When a part of the picture needs to be updated: viewport()->repaint(area,false)
// All other paints will be changed to progressive painting. // All other paints will be changed to progressive painting.
void ImageView::fullRepaint() { void ImageView::fullRepaint() {
if( !viewport()->isUpdatesEnabled()) return; if( !viewport()->isUpdatesEnabled()) return;
cancelPending(); cancelPending();
viewport()->tqrepaint(false); viewport()->repaint(false);
} }
void ImageView::cancelPending() { void ImageView::cancelPending() {
@ -832,7 +832,7 @@ void ImageView::performPaint( TQPainter* painter, int clipx, int clipy, int clip
int extraPixels = ImageUtils::extraScalePixels( smoothAlgo, zoom()); int extraPixels = ImageUtils::extraScalePixels( smoothAlgo, zoom());
TQRect imageRect = d->widgetToImageBounding( TQRect(clipx,clipy,clipw,cliph), extraPixels ); TQRect imageRect = d->widgetToImageBounding( TQRect(clipx,clipy,clipw,cliph), extraPixels );
imageRect = imageRect.intersect( TQRect( 0, 0, d->mDocument->width(), d->mDocument->height())); imageRect = imageRect.intersect( TQRect( 0, 0, d->mDocument->width(), d->mDocument->height()));
TQMemArray< TQRect > rects = TQRegion(d->mValidImageArea.intersect( imageRect )).tqrects(); TQMemArray< TQRect > rects = TQRegion(d->mValidImageArea.intersect( imageRect )).rects();
for( unsigned int i = 1; i < rects.count(); ++i ) { for( unsigned int i = 1; i < rects.count(); ++i ) {
addPendingPaint( secondPass, d->imageToWidget( rects[ i ] )); addPendingPaint( secondPass, d->imageToWidget( rects[ i ] ));
} }
@ -1024,7 +1024,7 @@ bool ImageView::eventFilter(TQObject* obj, TQEvent* event) {
return true; return true;
// Getting/loosing focus causes repaints, but repainting here is expensive, // Getting/loosing focus causes repaints, but repainting here is expensive,
// and there's no need to tqrepaint on focus changes, as the focus is not // and there's no need to repaint on focus changes, as the focus is not
// indicated. // indicated.
case TQEvent::FocusIn: case TQEvent::FocusIn:
case TQEvent::FocusOut: case TQEvent::FocusOut:
@ -1313,7 +1313,7 @@ void ImageView::slotImageSizeUpdated() {
void ImageView::slotImageRectUpdated(const TQRect& imageRect) { void ImageView::slotImageRectUpdated(const TQRect& imageRect) {
d->mValidImageArea += imageRect; d->mValidImageArea += imageRect;
viewport()->tqrepaint( d->imageToWidget( imageRect ), false ); viewport()->repaint( d->imageToWidget( imageRect ), false );
} }
@ -1339,7 +1339,7 @@ double ImageView::computeZoomToFit() const {
return 1.0; return 1.0;
} }
TQSize size=d->mDocument->image().size(); TQSize size=d->mDocument->image().size();
size.tqscale(width(),height(),TQSize::ScaleMin); size.scale(width(),height(),TQSize::ScaleMin);
double zoom=double(size.width())/d->mDocument->width(); double zoom=double(size.width())/d->mDocument->width();
if (zoom>1.0 && !ImageViewConfig::enlargeSmallImages()) return 1.0; if (zoom>1.0 && !ImageViewConfig::enlargeSmallImages()) return 1.0;
@ -1350,7 +1350,7 @@ double ImageView::computeZoomToWidth() const {
if (d->mDocument->isNull()) { if (d->mDocument->isNull()) {
return 1.0; return 1.0;
} }
int sw = verticalScrollBar()->tqsizeHint().width(); // tqgeometry is not valid before first show() int sw = verticalScrollBar()->sizeHint().width(); // geometry is not valid before first show()
int w = width(); int w = width();
int dw = d->mDocument->width(); int dw = d->mDocument->width();
switch( vScrollBarMode()) { switch( vScrollBarMode()) {
@ -1370,7 +1370,7 @@ double ImageView::computeZoomToHeight() const {
if (d->mDocument->isNull()) { if (d->mDocument->isNull()) {
return 1.0; return 1.0;
} }
int sh = horizontalScrollBar()->tqsizeHint().height(); int sh = horizontalScrollBar()->sizeHint().height();
int h = height(); int h = height();
int dh = d->mDocument->height(); int dh = d->mDocument->height();
switch( vScrollBarMode()) { switch( vScrollBarMode()) {
@ -1425,11 +1425,11 @@ void ImageView::updateImageOffset() {
int zpixHeight=int(d->mDocument->height() * d->mZoom); int zpixHeight=int(d->mDocument->height() * d->mZoom);
if (zpixWidth>viewWidth && hScrollBarMode()!=AlwaysOff) { if (zpixWidth>viewWidth && hScrollBarMode()!=AlwaysOff) {
// use tqsizeHint() - tqgeometry is not valid before first show() // use sizeHint() - geometry is not valid before first show()
viewHeight-=horizontalScrollBar()->tqsizeHint().height(); viewHeight-=horizontalScrollBar()->sizeHint().height();
} }
if (zpixHeight>viewHeight && vScrollBarMode()!=AlwaysOff) { if (zpixHeight>viewHeight && vScrollBarMode()!=AlwaysOff) {
viewWidth-=verticalScrollBar()->tqsizeHint().width(); viewWidth-=verticalScrollBar()->sizeHint().width();
} }
d->mXOffset=TQMAX(0,(viewWidth-zpixWidth)/2); d->mXOffset=TQMAX(0,(viewWidth-zpixWidth)/2);
@ -1457,7 +1457,7 @@ void ImageView::updateZoomActions() {
if (d->mZoomMode==ZOOM_FREE) { if (d->mZoomMode==ZOOM_FREE) {
d->mZoomIn->setEnabled(d->mZoom<MAX_ZOOM); d->mZoomIn->setEnabled(d->mZoom<MAX_ZOOM);
d->mZoomOut->setEnabled(d->mZoom>1/MAX_ZOOM); d->mZoomOut->setEnabled(d->mZoom>1/MAX_ZOOM);
TQString zoomText=TQString("%1%").tqarg(int(d->mZoom*100)); TQString zoomText=TQString("%1%").arg(int(d->mZoom*100));
d->mZoomCombo->setCurrentText(zoomText); d->mZoomCombo->setCurrentText(zoomText);
} else { } else {
d->mZoomIn->setEnabled(true); d->mZoomIn->setEnabled(true);

@ -2,7 +2,7 @@
<!DOCTYPE kcfg SYSTEM "http://www.kde.org/standards/kcfg/1.0/kcfg.dtd"> <!DOCTYPE kcfg SYSTEM "http://www.kde.org/standards/kcfg/1.0/kcfg.dtd">
<kcfg> <kcfg>
<include>tqapplication.h</include> <include>tqapplication.h</include>
<include>tqpalette.h</include> <include>palette.h</include>
<kcfgfile name="gwenviewrc"/> <kcfgfile name="gwenviewrc"/>
<group name="pixmap widget"> <group name="pixmap widget">
<entry name="smoothAlgorithm" key="smooth scale" type="Enum"> <entry name="smoothAlgorithm" key="smooth scale" type="Enum">
@ -18,7 +18,7 @@
<default>false</default> <default>false</default>
</entry> </entry>
<entry name="backgroundColor" key="background color" type="Color"> <entry name="backgroundColor" key="background color" type="Color">
<default code="true">TQApplication::tqpalette().active().dark()</default> <default code="true">TQApplication::palette().active().dark()</default>
</entry> </entry>
<entry name="enlargeSmallImages" key="enlarge small images" type="Bool"> <entry name="enlargeSmallImages" key="enlarge small images" type="Bool">
<default>false</default> <default>false</default>

@ -22,7 +22,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
// TQt // TQt
#include <tqcursor.h> #include <tqcursor.h>
#include <tqlayout.h> #include <layout.h>
#include <tqpopupmenu.h> #include <tqpopupmenu.h>
#include <tqvbox.h> #include <tqvbox.h>
#include <tqwidgetstack.h> #include <tqwidgetstack.h>
@ -275,12 +275,12 @@ ImageViewController::ImageViewController(TQWidget* parent, Document* document, K
d->mContainer=new TQWidget(parent); d->mContainer=new TQWidget(parent);
d->mContainer->setMinimumWidth(1); // Make sure we can resize the toolbar smaller than its minimum size d->mContainer->setMinimumWidth(1); // Make sure we can resize the toolbar smaller than its minimum size
TQVBoxLayout* tqlayout=new TQVBoxLayout(d->mContainer); TQVBoxLayout* layout=new TQVBoxLayout(d->mContainer);
d->mToolBar=new KToolBar(d->mContainer, "", true); d->mToolBar=new KToolBar(d->mContainer, "", true);
tqlayout->add(d->mToolBar); layout->add(d->mToolBar);
d->mStack=new TQWidgetStack(d->mContainer); d->mStack=new TQWidgetStack(d->mContainer);
tqlayout->add(d->mStack); layout->add(d->mStack);
d->mImageView=new ImageView(d->mStack, document, actionCollection); d->mImageView=new ImageView(d->mStack, document, actionCollection);
d->mStack->addWidget(d->mImageView); d->mStack->addWidget(d->mImageView);

@ -36,7 +36,7 @@ namespace Gwenview {
// Helper function // Helper function
static TQCursor loadCursor(const TQString& name) { static TQCursor loadCursor(const TQString& name) {
TQString path; TQString path;
path=locate("data", TQString("gwenview/cursors/%1.png").tqarg(name)); path=locate("data", TQString("gwenview/cursors/%1.png").arg(name));
return TQCursor(TQPixmap(path)); return TQCursor(TQPixmap(path));
} }

@ -20,7 +20,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/ */
// TQt // TQt
#include <tqcheckbox.h> #include <tqcheckbox.h>
#include <tqlayout.h> #include <layout.h>
#include <tqpainter.h> #include <tqpainter.h>
#include <tqradiobutton.h> #include <tqradiobutton.h>
#include <tqvbuttongroup.h> #include <tqvbuttongroup.h>
@ -82,8 +82,8 @@ PrintDialogPage::PrintDialogPage( Document* document, TQWidget *parent, const ch
mContent = new PrintDialogPageBase(this); mContent = new PrintDialogPageBase(this);
setTitle( mContent->caption() ); setTitle( mContent->caption() );
TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); TQVBoxLayout *layout = new TQVBoxLayout( this );
tqlayout->addWidget( mContent ); layout->addWidget( mContent );
connect(mContent->mWidth, TQT_SIGNAL( valueChanged( double )), TQT_SLOT( slotWidthChanged( double ))); connect(mContent->mWidth, TQT_SIGNAL( valueChanged( double )), TQT_SLOT( slotWidthChanged( double )));
connect(mContent->mHeight, TQT_SIGNAL( valueChanged( double )), TQT_SLOT( slotHeightChanged( double ))); connect(mContent->mHeight, TQT_SIGNAL( valueChanged( double )), TQT_SLOT( slotHeightChanged( double )));
@ -169,57 +169,57 @@ void PrintDialogPage::setScaleHeight( double value ) {
} }
int PrintDialogPage::getPosition(const TQString& align) { int PrintDialogPage::getPosition(const TQString& align) {
int tqalignment; int alignment;
if (align == i18n("Central-Left")) { if (align == i18n("Central-Left")) {
tqalignment = TQt::AlignLeft | TQt::AlignVCenter; alignment = TQt::AlignLeft | TQt::AlignVCenter;
} else if (align == i18n("Central-Right")) { } else if (align == i18n("Central-Right")) {
tqalignment = TQt::AlignRight | TQt::AlignVCenter; alignment = TQt::AlignRight | TQt::AlignVCenter;
} else if (align == i18n("Top-Left")) { } else if (align == i18n("Top-Left")) {
tqalignment = TQt::AlignTop | TQt::AlignLeft; alignment = TQt::AlignTop | TQt::AlignLeft;
} else if (align == i18n("Top-Right")) { } else if (align == i18n("Top-Right")) {
tqalignment = TQt::AlignTop | TQt::AlignRight; alignment = TQt::AlignTop | TQt::AlignRight;
} else if (align == i18n("Bottom-Left")) { } else if (align == i18n("Bottom-Left")) {
tqalignment = TQt::AlignBottom | TQt::AlignLeft; alignment = TQt::AlignBottom | TQt::AlignLeft;
} else if (align == i18n("Bottom-Right")) { } else if (align == i18n("Bottom-Right")) {
tqalignment = TQt::AlignBottom | TQt::AlignRight; alignment = TQt::AlignBottom | TQt::AlignRight;
} else if (align == i18n("Top-Central")) { } else if (align == i18n("Top-Central")) {
tqalignment = TQt::AlignTop | TQt::AlignHCenter; alignment = TQt::AlignTop | TQt::AlignHCenter;
} else if (align == i18n("Bottom-Central")) { } else if (align == i18n("Bottom-Central")) {
tqalignment = TQt::AlignBottom | TQt::AlignHCenter; alignment = TQt::AlignBottom | TQt::AlignHCenter;
} else { } else {
// Central // Central
tqalignment = TQt::AlignCenter; // TQt::AlignHCenter || TQt::AlignVCenter alignment = TQt::AlignCenter; // TQt::AlignHCenter || TQt::AlignVCenter
} }
return tqalignment; return alignment;
} }
TQString PrintDialogPage::setPosition(int align) { TQString PrintDialogPage::setPosition(int align) {
TQString tqalignment; TQString alignment;
if (align == (TQt::AlignLeft | TQt::AlignVCenter)) { if (align == (TQt::AlignLeft | TQt::AlignVCenter)) {
tqalignment = i18n("Central-Left"); alignment = i18n("Central-Left");
} else if (align == (TQt::AlignRight | TQt::AlignVCenter)) { } else if (align == (TQt::AlignRight | TQt::AlignVCenter)) {
tqalignment = i18n("Central-Right"); alignment = i18n("Central-Right");
} else if (align == (TQt::AlignTop | TQt::AlignLeft)) { } else if (align == (TQt::AlignTop | TQt::AlignLeft)) {
tqalignment = i18n("Top-Left"); alignment = i18n("Top-Left");
} else if (align == (TQt::AlignTop | TQt::AlignRight)) { } else if (align == (TQt::AlignTop | TQt::AlignRight)) {
tqalignment = i18n("Top-Right"); alignment = i18n("Top-Right");
} else if (align == (TQt::AlignBottom | TQt::AlignLeft)) { } else if (align == (TQt::AlignBottom | TQt::AlignLeft)) {
tqalignment = i18n("Bottom-Left"); alignment = i18n("Bottom-Left");
} else if (align == (TQt::AlignBottom | TQt::AlignRight)) { } else if (align == (TQt::AlignBottom | TQt::AlignRight)) {
tqalignment = i18n("Bottom-Right"); alignment = i18n("Bottom-Right");
} else if (align == (TQt::AlignTop | TQt::AlignHCenter)) { } else if (align == (TQt::AlignTop | TQt::AlignHCenter)) {
tqalignment = i18n("Top-Central"); alignment = i18n("Top-Central");
} else if (align == (TQt::AlignBottom | TQt::AlignHCenter)) { } else if (align == (TQt::AlignBottom | TQt::AlignHCenter)) {
tqalignment = i18n("Bottom-Central"); alignment = i18n("Bottom-Central");
} else { } else {
// Central: TQt::AlignCenter or (TQt::AlignHCenter || TQt::AlignVCenter) // Central: TQt::AlignCenter or (TQt::AlignHCenter || TQt::AlignVCenter)
tqalignment = i18n("Central"); alignment = i18n("Central");
} }
return tqalignment; return alignment;
} }
// SLOTS // SLOTS

@ -24,7 +24,7 @@
</property> </property>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout2</cstring> <cstring>layout2</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">
@ -98,7 +98,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>101</width> <width>101</width>
<height>21</height> <height>21</height>
@ -170,7 +170,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout4</cstring> <cstring>layout4</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">
@ -186,7 +186,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>20</width> <width>20</width>
<height>20</height> <height>20</height>
@ -214,7 +214,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>240</width> <width>240</width>
<height>21</height> <height>21</height>
@ -236,7 +236,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout4</cstring> <cstring>layout4</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">
@ -252,7 +252,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>20</width> <width>20</width>
<height>20</height> <height>20</height>
@ -351,7 +351,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Expanding</enum> <enum>Expanding</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>16</width> <width>16</width>
<height>20</height> <height>20</height>

@ -486,7 +486,7 @@ void XCFImageFormat::readXCF ( TQImageIO* image_io )
} }
image_io->setImage( xcf_image.image ); image_io->setImage( xcf_image.image );
image_io->setqStatus( 0 ); image_io->seStatus( 0 );
} }
/*! /*!

@ -29,7 +29,7 @@
</widget> </widget>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout6</cstring> <cstring>layout6</cstring>
</property> </property>
<grid> <grid>
<property name="name"> <property name="name">
@ -45,7 +45,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>20</height> <height>20</height>
@ -96,7 +96,7 @@
<property name="sizeType"> <property name="sizeType">
<enum>Fixed</enum> <enum>Fixed</enum>
</property> </property>
<property name="tqsizeHint"> <property name="sizeHint">
<size> <size>
<width>21</width> <width>21</width>
<height>21</height> <height>21</height>

@ -74,7 +74,7 @@ static TQString fbname( const TQString &fileName ) // get file basename (sort of
s = s.mid( i ); s = s.mid( i );
if ( (i = s.findRev('\\')) >= 0 ) if ( (i = s.findRev('\\')) >= 0 )
s = s.mid( i ); s = s.mid( i );
TQRegExp r( TQString::tqfromLatin1("[a-zA-Z][a-zA-Z0-9_]*") ); TQRegExp r( TQString::fromLatin1("[a-zA-Z][a-zA-Z0-9_]*") );
int p = r.search( s ); int p = r.search( s );
if ( p == -1 ) if ( p == -1 )
s.truncate( 0 ); s.truncate( 0 );
@ -82,7 +82,7 @@ static TQString fbname( const TQString &fileName ) // get file basename (sort of
s = s.mid( p, r.matchedLength() ); s = s.mid( p, r.matchedLength() );
} }
if ( s.isEmpty() ) if ( s.isEmpty() )
s = TQString::tqfromLatin1( "dummy" ); s = TQString::fromLatin1( "dummy" );
return s; return s;
} }
@ -161,10 +161,10 @@ static void read_xpm_image_or_array( TQImageIO * iio, const char * const * sourc
int i, cpp, ncols, w, h, index = 0; int i, cpp, ncols, w, h, index = 0;
if ( iio ) { if ( iio ) {
iio->setqStatus( 1 ); iio->seStatus( 1 );
d = iio ? iio->ioDevice() : 0; d = iio ? iio->ioDevice() : 0;
d->readLine( buf.data(), buf.size() ); // "/* XPM */" d->readLine( buf.data(), buf.size() ); // "/* XPM */"
TQRegExp r( TQString::tqfromLatin1("/\\*.XPM.\\*/") ); TQRegExp r( TQString::fromLatin1("/\\*.XPM.\\*/") );
if ( buf.find(r) == -1 ) if ( buf.find(r) == -1 )
return; // bad magic return; // bad magic
} else if ( !source ) { } else if ( !source ) {
@ -291,7 +291,7 @@ static void read_xpm_image_or_array( TQImageIO * iio, const char * const * sourc
} }
if ( iio ) { if ( iio ) {
iio->setImage( image ); iio->setImage( image );
iio->setqStatus( 0 ); // image ok iio->seStatus( 0 ); // image ok
} }
} }
@ -340,7 +340,7 @@ static const char* xpm_color_name( int cpp, int index )
static void write_xpm_image( TQImageIO * iio ) static void write_xpm_image( TQImageIO * iio )
{ {
if ( iio ) if ( iio )
iio->setqStatus( 1 ); iio->seStatus( 1 );
else else
return; return;
@ -424,7 +424,7 @@ static void write_xpm_image( TQImageIO * iio )
} }
s << "};" << endl; s << "};" << endl;
iio->setqStatus( 0 ); iio->seStatus( 0 );
} }
// TQt code end --------------------------- // TQt code end ---------------------------

@ -173,7 +173,7 @@ bool GVDirPart::openURL(const KURL& url) {
void GVDirPart::loaded(const KURL& url) { void GVDirPart::loaded(const KURL& url) {
TQString caption = url.filename(); TQString caption = url.filename();
if( !mDocument->image().isNull()) if( !mDocument->image().isNull())
caption += TQString(" %1 x %2").tqarg(mDocument->width()).tqarg(mDocument->height()); caption += TQString(" %1 x %2").arg(mDocument->width()).arg(mDocument->height());
emit setWindowCaption(caption); emit setWindowCaption(caption);
emit completed(); emit completed();
} }

@ -194,7 +194,7 @@ void GVImagePart::slotLoading() {
} }
void GVImagePart::slotLoaded(const KURL& url) { void GVImagePart::slotLoaded(const KURL& url) {
TQString caption = url.filename() + TQString(" - %1x%2").tqarg(mDocument->width()).tqarg(mDocument->height()); TQString caption = url.filename() + TQString(" - %1x%2").arg(mDocument->width()).arg(mDocument->height());
emit setWindowCaption(caption); emit setWindowCaption(caption);
emit completed(); emit completed();
emit setStatusBarText(i18n("Done.")); emit setStatusBarText(i18n("Done."));
@ -363,7 +363,7 @@ void GVImagePart::saveOriginalAs() {
if (!file.open(IO_WriteOnly)) { if (!file.open(IO_WriteOnly)) {
KMessageBox::error( KMessageBox::error(
widget(), widget(),
i18n("Could not open '%1' for writing.").tqarg(path)); i18n("Could not open '%1' for writing.").arg(path));
return; return;
} }
storeData(widget(), &file, data); storeData(widget(), &file, data);

@ -120,7 +120,7 @@ struct inmem_dest_mgr : public jpeg_destination_mgr {
void inmem_init_destination(j_compress_ptr cinfo) { void inmem_init_destination(j_compress_ptr cinfo) {
inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest); inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest);
if (dest->mOutput->size()==0) { if (dest->mOutput->size()==0) {
bool result=dest->mOutput->tqresize(INMEM_DST_DELTA); bool result=dest->mOutput->resize(INMEM_DST_DELTA);
Q_ASSERT(result); Q_ASSERT(result);
} }
dest->free_in_buffer=dest->mOutput->size(); dest->free_in_buffer=dest->mOutput->size();
@ -129,7 +129,7 @@ void inmem_init_destination(j_compress_ptr cinfo) {
int inmem_empty_output_buffer(j_compress_ptr cinfo) { int inmem_empty_output_buffer(j_compress_ptr cinfo) {
inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest); inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest);
bool result=dest->mOutput->tqresize(dest->mOutput->size() + INMEM_DST_DELTA); bool result=dest->mOutput->resize(dest->mOutput->size() + INMEM_DST_DELTA);
Q_ASSERT(result); Q_ASSERT(result);
dest->next_output_byte=(JOCTET*)( dest->mOutput->data() + dest->mOutput->size() - INMEM_DST_DELTA ); dest->next_output_byte=(JOCTET*)( dest->mOutput->data() + dest->mOutput->size() - INMEM_DST_DELTA );
dest->free_in_buffer=INMEM_DST_DELTA; dest->free_in_buffer=INMEM_DST_DELTA;
@ -141,7 +141,7 @@ void inmem_term_destination(j_compress_ptr cinfo) {
inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest); inmem_dest_mgr* dest=(inmem_dest_mgr*)(cinfo->dest);
int finalSize=dest->next_output_byte - (JOCTET*)(dest->mOutput->data()); int finalSize=dest->next_output_byte - (JOCTET*)(dest->mOutput->data());
Q_ASSERT(finalSize>=0); Q_ASSERT(finalSize>=0);
dest->mOutput->tqresize(finalSize); dest->mOutput->resize(finalSize);
} }

@ -1929,7 +1929,7 @@ TQImage scale(const TQImage& image, int width, int height,
if( image.isNull()) return image.copy(); if( image.isNull()) return image.copy();
TQSize newSize( image.size() ); TQSize newSize( image.size() );
newSize.tqscale( TQSize( width, height ), (TQSize::ScaleMode)mode ); // ### remove cast in TQt 4.0 newSize.scale( TQSize( width, height ), (TQSize::ScaleMode)mode ); // ### remove cast in TQt 4.0
newSize = newSize.expandedTo( TQSize( 1, 1 )); // make sure it doesn't become null newSize = newSize.expandedTo( TQSize( 1, 1 )); // make sure it doesn't become null
if ( newSize == image.size() ) return image.copy(); if ( newSize == image.size() ) return image.copy();

@ -272,7 +272,7 @@ rm -rf $RPM_BUILD_ROOT
o Update the EXIF thumbnail when rotating a JPEG file. o Update the EXIF thumbnail when rotating a JPEG file.
o In the folder view, folders now open with a single click (By Daniel Thaler). o In the folder view, folders now open with a single click (By Daniel Thaler).
o Reworked coordinate conversions in order to avoid subtle paint errors. o Reworked coordinate conversions in order to avoid subtle paint errors.
o Remember computed optimal tqrepaint sizes in the config file, o Remember computed optimal repaint sizes in the config file,
so they are available immediately after next start. so they are available immediately after next start.
o Remember shown URL after session restore. o Remember shown URL after session restore.
* Sat Oct 16 2004 Angelo Naselli <anaselli@mandrake.org> 1.1.5-0.3mdk * Sat Oct 16 2004 Angelo Naselli <anaselli@mandrake.org> 1.1.5-0.3mdk
@ -317,7 +317,7 @@ rm -rf $RPM_BUILD_ROOT
- Avoid data loss if the JPEG images are saved while being rotated by - Avoid data loss if the JPEG images are saved while being rotated by
JPEGTran. JPEGTran.
- The back button in Konqueror now works correctly with gvimagepart. - The back button in Konqueror now works correctly with gvimagepart.
- The default tqlayout is more user-friendly. - The default layout is more user-friendly.
- Non-trivial URLs (e.g. http query URL) are correctly handled. - Non-trivial URLs (e.g. http query URL) are correctly handled.
- You can now drop images on the image view. - You can now drop images on the image view.

@ -175,7 +175,7 @@ void TSThread::customEvent( TQCustomEvent* ev )
} }
bool deleted = false; bool deleted = false;
deleted_flag = &deleted; // this is like TQGuardedPtr for self, but faster deleted_flag = &deleted; // this is like TQGuardedPtr for self, but faster
int signal_id = e->object->tqmetaObject()->findSignal( normalizeSignalSlot( e->signal ).data() + 1, true ); int signal_id = e->object->metaObject()->findSignal( normalizeSignalSlot( e->signal ).data() + 1, true );
if( signal_id >= 0 ) if( signal_id >= 0 )
e->object->qt_emit( signal_id, e->args ); e->object->qt_emit( signal_id, e->args );
else else

Loading…
Cancel
Save