summaryrefslogtreecommitdiffstats
path: root/digikam/imageplugins/freerotation/freerotationtool.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'digikam/imageplugins/freerotation/freerotationtool.cpp')
-rw-r--r--digikam/imageplugins/freerotation/freerotationtool.cpp82
1 files changed, 41 insertions, 41 deletions
diff --git a/digikam/imageplugins/freerotation/freerotationtool.cpp b/digikam/imageplugins/freerotation/freerotationtool.cpp
index 7e5c7a7..825b88d 100644
--- a/digikam/imageplugins/freerotation/freerotationtool.cpp
+++ b/digikam/imageplugins/freerotation/freerotationtool.cpp
@@ -22,13 +22,13 @@
*
* ============================================================ */
-// Qt includes.
+// TQt includes.
-#include <qcheckbox.h>
-#include <qimage.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qwhatsthis.h>
+#include <tqcheckbox.h>
+#include <tqimage.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqwhatsthis.h>
// KDE includes.
@@ -64,8 +64,8 @@ using namespace Digikam;
namespace DigikamFreeRotationImagesPlugin
{
-FreeRotationTool::FreeRotationTool(QObject* parent)
- : EditorToolThreaded(parent)
+FreeRotationTool::FreeRotationTool(TQObject* tqparent)
+ : EditorToolThreaded(tqparent)
{
setName("freerotation");
setToolName(i18n("Free Rotation"));
@@ -84,52 +84,52 @@ FreeRotationTool::FreeRotationTool(QObject* parent)
// -------------------------------------------------------------
- QString temp;
+ TQString temp;
Digikam::ImageIface iface(0, 0);
m_gboxSettings = new EditorToolSettings(EditorToolSettings::Default|
EditorToolSettings::Ok|
EditorToolSettings::Cancel,
EditorToolSettings::ColorGuide);
- QGridLayout* grid = new QGridLayout(m_gboxSettings->plainPage(), 9, 2);
+ TQGridLayout* grid = new TQGridLayout(m_gboxSettings->plainPage(), 9, 2);
- QLabel *label1 = new QLabel(i18n("New width:"), m_gboxSettings->plainPage());
- m_newWidthLabel = new QLabel(temp.setNum( iface.originalWidth()) + i18n(" px"), m_gboxSettings->plainPage());
- m_newWidthLabel->setAlignment( AlignBottom | AlignRight );
+ TQLabel *label1 = new TQLabel(i18n("New width:"), m_gboxSettings->plainPage());
+ m_newWidthLabel = new TQLabel(temp.setNum( iface.originalWidth()) + i18n(" px"), m_gboxSettings->plainPage());
+ m_newWidthLabel->tqsetAlignment( AlignBottom | AlignRight );
- QLabel *label2 = new QLabel(i18n("New height:"), m_gboxSettings->plainPage());
- m_newHeightLabel = new QLabel(temp.setNum( iface.originalHeight()) + i18n(" px"), m_gboxSettings->plainPage());
- m_newHeightLabel->setAlignment( AlignBottom | AlignRight );
+ TQLabel *label2 = new TQLabel(i18n("New height:"), m_gboxSettings->plainPage());
+ m_newHeightLabel = new TQLabel(temp.setNum( iface.originalHeight()) + i18n(" px"), m_gboxSettings->plainPage());
+ m_newHeightLabel->tqsetAlignment( AlignBottom | AlignRight );
- KSeparator *line = new KSeparator (Horizontal, m_gboxSettings->plainPage());
+ KSeparator *line = new KSeparator(Qt::Horizontal, m_gboxSettings->plainPage());
- QLabel *label3 = new QLabel(i18n("Main angle:"), m_gboxSettings->plainPage());
+ TQLabel *label3 = new TQLabel(i18n("Main angle:"), m_gboxSettings->plainPage());
m_angleInput = new RIntNumInput(m_gboxSettings->plainPage());
m_angleInput->setRange(-180, 180, 1);
m_angleInput->setDefaultValue(0);
- QWhatsThis::add( m_angleInput, i18n("<p>An angle in degrees by which to rotate the image. "
+ TQWhatsThis::add( m_angleInput, i18n("<p>An angle in degrees by which to rotate the image. "
"A positive angle rotates the image clockwise; "
"a negative angle rotates it counter-clockwise."));
- QLabel *label4 = new QLabel(i18n("Fine angle:"), m_gboxSettings->plainPage());
+ TQLabel *label4 = new TQLabel(i18n("Fine angle:"), m_gboxSettings->plainPage());
m_fineAngleInput = new RDoubleNumInput(m_gboxSettings->plainPage());
m_fineAngleInput->setRange(-5.0, 5.0, 0.01);
m_fineAngleInput->setDefaultValue(0);
- QWhatsThis::add( m_fineAngleInput, i18n("<p>This value in degrees will be added to main angle value "
+ TQWhatsThis::add( m_fineAngleInput, i18n("<p>This value in degrees will be added to main angle value "
"to set fine target angle."));
- m_antialiasInput = new QCheckBox(i18n("Anti-Aliasing"), m_gboxSettings->plainPage());
- QWhatsThis::add( m_antialiasInput, i18n("<p>Enable this option to apply the anti-aliasing filter "
+ m_antialiasInput = new TQCheckBox(i18n("Anti-Aliasing"), m_gboxSettings->plainPage());
+ TQWhatsThis::add( m_antialiasInput, i18n("<p>Enable this option to apply the anti-aliasing filter "
"to the rotated image. "
"In order to smooth the target image, it will be blurred a little."));
- QLabel *label5 = new QLabel(i18n("Auto-crop:"), m_gboxSettings->plainPage());
+ TQLabel *label5 = new TQLabel(i18n("Auto-crop:"), m_gboxSettings->plainPage());
m_autoCropCB = new RComboBox(m_gboxSettings->plainPage());
m_autoCropCB->insertItem( i18n("None") );
m_autoCropCB->insertItem( i18n("Widest Area") );
m_autoCropCB->insertItem( i18n("Largest Area") );
m_autoCropCB->setDefaultItem(FreeRotation::NoAutoCrop);
- QWhatsThis::add( m_autoCropCB, i18n("<p>Select the method to process image auto-cropping "
+ TQWhatsThis::add( m_autoCropCB, i18n("<p>Select the method to process image auto-cropping "
"to remove black frames around a rotated image."));
grid->addMultiCellWidget(label1, 0, 0, 0, 0);
@@ -153,20 +153,20 @@ FreeRotationTool::FreeRotationTool(QObject* parent)
// -------------------------------------------------------------
- connect(m_angleInput, SIGNAL(valueChanged(int)),
- this, SLOT(slotTimer()));
+ connect(m_angleInput, TQT_SIGNAL(valueChanged(int)),
+ this, TQT_SLOT(slotTimer()));
- connect(m_fineAngleInput, SIGNAL(valueChanged(double)),
- this, SLOT(slotTimer()));
+ connect(m_fineAngleInput, TQT_SIGNAL(valueChanged(double)),
+ this, TQT_SLOT(slotTimer()));
- connect(m_antialiasInput, SIGNAL(toggled(bool)),
- this, SLOT(slotEffect()));
+ connect(m_antialiasInput, TQT_SIGNAL(toggled(bool)),
+ this, TQT_SLOT(slotEffect()));
- connect(m_autoCropCB, SIGNAL(activated(int)),
- this, SLOT(slotEffect()));
+ connect(m_autoCropCB, TQT_SIGNAL(activated(int)),
+ this, TQT_SLOT(slotEffect()));
- connect(m_gboxSettings, SIGNAL(signalColorGuideChanged()),
- this, SLOT(slotColorGuideChanged()));
+ connect(m_gboxSettings, TQT_SIGNAL(signalColorGuideChanged()),
+ this, TQT_SLOT(slotColorGuideChanged()));
}
FreeRotationTool::~FreeRotationTool()
@@ -187,7 +187,7 @@ void FreeRotationTool::readSettings()
m_fineAngleInput->setValue(config->readDoubleNumEntry("Fine Angle", m_fineAngleInput->defaultValue()));
m_autoCropCB->setCurrentItem(config->readNumEntry("Auto Crop Type", m_autoCropCB->defaultItem()));
m_antialiasInput->setChecked(config->readBoolEntry("Anti Aliasing", true));
- m_gboxSettings->setGuideColor(config->readColorEntry("Guide Color", &Qt::red));
+ m_gboxSettings->setGuideColor(config->readColorEntry("Guide Color", &TQt::red));
m_gboxSettings->setGuideSize(config->readNumEntry("Guide Width", 1));
slotColorGuideChanged();
@@ -235,7 +235,7 @@ void FreeRotationTool::prepareEffect()
double angle = m_angleInput->value() + m_fineAngleInput->value();
bool antialiasing = m_antialiasInput->isChecked();
int autocrop = m_autoCropCB->currentItem();
- QColor background = toolView()->paletteBackgroundColor().rgb();
+ TQColor background = toolView()->paletteBackgroundColor().rgb();
ImageIface* iface = m_previewWidget->imageIface();
int orgW = iface->originalWidth();
int orgH = iface->originalHeight();
@@ -259,7 +259,7 @@ void FreeRotationTool::prepareFinal()
double angle = m_angleInput->value() + m_fineAngleInput->value();
bool antialiasing = m_antialiasInput->isChecked();
int autocrop = m_autoCropCB->currentItem();
- QColor background = Qt::black;
+ TQColor background = TQt::black;
ImageIface iface(0, 0);
int orgW = iface.originalWidth();
@@ -279,7 +279,7 @@ void FreeRotationTool::putPreviewData()
int w = iface->previewWidth();
int h = iface->previewHeight();
- DImg imTemp = filter()->getTargetImage().smoothScale(w, h, QSize::ScaleMin);
+ DImg imTemp = filter()->getTargetImage().smoothScale(w, h, TQSize::ScaleMin);
DImg imDest( w, h, filter()->getTargetImage().sixteenBit(),
filter()->getTargetImage().hasAlpha() );
@@ -291,8 +291,8 @@ void FreeRotationTool::putPreviewData()
iface->previewHeight())).bits());
m_previewWidget->updatePreview();
- QSize newSize = dynamic_cast<FreeRotation*>(filter())->getNewSize();
- QString temp;
+ TQSize newSize = dynamic_cast<FreeRotation*>(filter())->getNewSize();
+ TQString temp;
m_newWidthLabel->setText(temp.setNum( newSize.width()) + i18n(" px") );
m_newHeightLabel->setText(temp.setNum( newSize.height()) + i18n(" px") );
}