diff options
Diffstat (limited to 'krita/ui/kis_dlg_preferences.cc')
| -rw-r--r-- | krita/ui/kis_dlg_preferences.cc | 162 |
1 files changed, 81 insertions, 81 deletions
diff --git a/krita/ui/kis_dlg_preferences.cc b/krita/ui/kis_dlg_preferences.cc index 5522bcdf0..75ec0593c 100644 --- a/krita/ui/kis_dlg_preferences.cc +++ b/krita/ui/kis_dlg_preferences.cc @@ -22,21 +22,21 @@ #include <config.h> #endif -#include <qbitmap.h> -#include <qbuttongroup.h> -#include <qcheckbox.h> -#include <qcursor.h> -#include <qlabel.h> -#include <qlayout.h> -#include <qlineedit.h> -#include <qpixmap.h> -#include <qpushbutton.h> -#include <qslider.h> -#include <qtoolbutton.h> -#include <qvbox.h> +#include <tqbitmap.h> +#include <tqbuttongroup.h> +#include <tqcheckbox.h> +#include <tqcursor.h> +#include <tqlabel.h> +#include <tqlayout.h> +#include <tqlineedit.h> +#include <tqpixmap.h> +#include <tqpushbutton.h> +#include <tqslider.h> +#include <tqtoolbutton.h> +#include <tqvbox.h> #ifdef HAVE_GL -#include <qgl.h> +#include <tqgl.h> #endif #include <KoImageResource.h> @@ -71,13 +71,13 @@ // for the performance update #include "tiles/kis_tilemanager.h" -GeneralTab::GeneralTab( QWidget *_parent, const char *_name ) +GeneralTab::GeneralTab( TQWidget *_parent, const char *_name ) : WdgGeneralSettings( _parent, _name ) { KisConfig cfg; - m_cmbCursorShape->setCurrentItem(cfg.cursorStyle()); + m_cmbtqCursorShape->setCurrentItem(cfg.cursorStyle()); grpDockability->setButton(cfg.dockability()); numDockerFontSize->setValue((int)cfg.dockerFontSize()); } @@ -86,14 +86,14 @@ void GeneralTab::setDefault() { KisConfig cfg; - m_cmbCursorShape->setCurrentItem( cfg.getDefaultCursorStyle()); + m_cmbtqCursorShape->setCurrentItem( cfg.getDefaultCursorStyle()); grpDockability->setButton(cfg.getDefaultDockability()); numDockerFontSize->setValue((int)(cfg.getDefaultDockerFontSize())); } enumCursorStyle GeneralTab::cursorStyle() { - return (enumCursorStyle)m_cmbCursorShape->currentItem(); + return (enumCursorStyle)m_cmbtqCursorShape->currentItem(); } enumKoDockability GeneralTab::dockability() @@ -108,13 +108,13 @@ float GeneralTab::dockerFontSize() //--------------------------------------------------------------------------------------------------- -ColorSettingsTab::ColorSettingsTab(QWidget *parent, const char *name ) - : QWidget(parent, name) +ColorSettingsTab::ColorSettingsTab(TQWidget *tqparent, const char *name ) + : TQWidget(tqparent, name) { // XXX: Make sure only profiles that fit the specified color model // are shown in the profile combos - QGridLayout * l = new QGridLayout( this, 1, 1, KDialog::marginHint(), KDialog::spacingHint()); + TQGridLayout * l = new TQGridLayout( this, 1, 1, KDialog::marginHint(), KDialog::spacingHint()); l->setMargin(0); m_page = new WdgColorSettings(this); l->addWidget( m_page, 0, 0); @@ -130,16 +130,16 @@ ColorSettingsTab::ColorSettingsTab(QWidget *parent, const char *name ) refillMonitorProfiles(KisID("RGBA", "")); refillPrintProfiles(KisID(cfg.printerColorSpace(), "")); - if(m_page->cmbMonitorProfile->contains(cfg.monitorProfile())) + if(m_page->cmbMonitorProfile->tqcontains(cfg.monitorProfile())) m_page->cmbMonitorProfile->setCurrentText(cfg.monitorProfile()); - if(m_page->cmbPrintProfile->contains(cfg.printerProfile())) + if(m_page->cmbPrintProfile->tqcontains(cfg.printerProfile())) m_page->cmbPrintProfile->setCurrentText(cfg.printerProfile()); m_page->chkBlackpoint->setChecked(cfg.useBlackPointCompensation()); m_page->grpPasteBehaviour->setButton(cfg.pasteBehaviour()); m_page->cmbMonitorIntent->setCurrentItem(cfg.renderIntent()); - connect(m_page->cmbPrintingColorSpace, SIGNAL(activated(const KisID &)), - this, SLOT(refillPrintProfiles(const KisID &))); + connect(m_page->cmbPrintingColorSpace, TQT_SIGNAL(activated(const KisID &)), + this, TQT_SLOT(refillPrintProfiles(const KisID &))); } void ColorSettingsTab::setDefault() @@ -164,8 +164,8 @@ void ColorSettingsTab::refillMonitorProfiles(const KisID & s) if ( !csf ) return; - QValueVector<KisProfile *> profileList = KisMetaRegistry::instance()->csRegistry()->profilesFor( csf ); - QValueVector<KisProfile *> ::iterator it; + TQValueVector<KisProfile *> profileList = KisMetaRegistry::instance()->csRegistry()->profilesFor( csf ); + TQValueVector<KisProfile *> ::iterator it; for ( it = profileList.begin(); it != profileList.end(); ++it ) { if ((*it)->deviceClass() == icSigDisplayClass) m_page->cmbMonitorProfile->insertItem((*it)->productName()); @@ -183,8 +183,8 @@ void ColorSettingsTab::refillPrintProfiles(const KisID & s) if ( !csf ) return; - QValueVector<KisProfile *> profileList = KisMetaRegistry::instance()->csRegistry()->profilesFor( csf ); - QValueVector<KisProfile *> ::iterator it; + TQValueVector<KisProfile *> profileList = KisMetaRegistry::instance()->csRegistry()->profilesFor( csf ); + TQValueVector<KisProfile *> ::iterator it; for ( it = profileList.begin(); it != profileList.end(); ++it ) { if ((*it)->deviceClass() == icSigOutputClass) m_page->cmbPrintProfile->insertItem((*it)->productName()); @@ -195,8 +195,8 @@ void ColorSettingsTab::refillPrintProfiles(const KisID & s) //--------------------------------------------------------------------------------------------------- -PerformanceTab::PerformanceTab(QWidget *parent, const char *name ) - : WdgPerformanceSettings(parent, name) +PerformanceTab::PerformanceTab(TQWidget *tqparent, const char *name ) + : WdgPerformanceSettings(tqparent, name) { // XXX: Make sure only profiles that fit the specified color model // are shown in the profile combos @@ -216,8 +216,8 @@ void PerformanceTab::setDefault() //--------------------------------------------------------------------------------------------------- -TabletSettingsTab::TabletSettingsTab( QWidget *parent, const char *name) - : WdgTabletSettings( parent, name ) +TabletSettingsTab::TabletSettingsTab( TQWidget *tqparent, const char *name) + : WdgTabletSettings( tqparent, name ) { #ifdef EXTENDED_X11_TABLET_SUPPORT initTabletDevices(); @@ -240,9 +240,9 @@ void TabletSettingsTab::applySettings() #ifdef EXTENDED_X11_TABLET_SUPPORT TabletSettingsTab::DeviceSettings::DeviceSettings(KisCanvasWidget::X11TabletDevice *tabletDevice, bool enabled, - Q_INT32 xAxis, Q_INT32 yAxis, Q_INT32 pressureAxis, - Q_INT32 xTiltAxis, Q_INT32 yTiltAxis, Q_INT32 wheelAxis, - Q_INT32 toolIDAxis, Q_INT32 serialNumberAxis) + TQ_INT32 xAxis, TQ_INT32 yAxis, TQ_INT32 pressureAxis, + TQ_INT32 xTiltAxis, TQ_INT32 yTiltAxis, TQ_INT32 wheelAxis, + TQ_INT32 toolIDAxis, TQ_INT32 serialNumberAxis) : m_tabletDevice(tabletDevice), m_enabled(enabled), m_xAxis(xAxis), @@ -294,104 +294,104 @@ bool TabletSettingsTab::DeviceSettings::enabled() const return m_enabled; } -Q_INT32 TabletSettingsTab::DeviceSettings::numAxes() const +TQ_INT32 TabletSettingsTab::DeviceSettings::numAxes() const { return m_tabletDevice->numAxes(); } -void TabletSettingsTab::DeviceSettings::setXAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setXAxis(TQ_INT32 axis) { m_xAxis = axis; } -void TabletSettingsTab::DeviceSettings::setYAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setYAxis(TQ_INT32 axis) { m_yAxis = axis; } -void TabletSettingsTab::DeviceSettings::setPressureAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setPressureAxis(TQ_INT32 axis) { m_pressureAxis = axis; } -void TabletSettingsTab::DeviceSettings::setXTiltAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setXTiltAxis(TQ_INT32 axis) { m_xTiltAxis = axis; } -void TabletSettingsTab::DeviceSettings::setYTiltAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setYTiltAxis(TQ_INT32 axis) { m_yTiltAxis = axis; } -void TabletSettingsTab::DeviceSettings::setWheelAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setWheelAxis(TQ_INT32 axis) { m_wheelAxis = axis; } -void TabletSettingsTab::DeviceSettings::setToolIDAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setToolIDAxis(TQ_INT32 axis) { m_toolIDAxis = axis; } -void TabletSettingsTab::DeviceSettings::setSerialNumberAxis(Q_INT32 axis) +void TabletSettingsTab::DeviceSettings::setSerialNumberAxis(TQ_INT32 axis) { m_serialNumberAxis = axis; } -Q_INT32 TabletSettingsTab::DeviceSettings::xAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::xAxis() const { return m_xAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::yAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::yAxis() const { return m_yAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::pressureAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::pressureAxis() const { return m_pressureAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::xTiltAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::xTiltAxis() const { return m_xTiltAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::yTiltAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::yTiltAxis() const { return m_yTiltAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::wheelAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::wheelAxis() const { return m_wheelAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::toolIDAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::toolIDAxis() const { return m_toolIDAxis; } -Q_INT32 TabletSettingsTab::DeviceSettings::serialNumberAxis() const +TQ_INT32 TabletSettingsTab::DeviceSettings::serialNumberAxis() const { return m_serialNumberAxis; } -TabletSettingsTab::TabletDeviceSettingsDialog::TabletDeviceSettingsDialog(const QString& deviceName, DeviceSettings settings, - QWidget *parent, const char *name) - : super(parent, name, true, "", Ok | Cancel) +TabletSettingsTab::TabletDeviceSettingsDialog::TabletDeviceSettingsDialog(const TQString& deviceName, DeviceSettings settings, + TQWidget *tqparent, const char *name) + : super(tqparent, name, true, "", Ok | Cancel) { - setCaption(i18n("Configure %1").arg(deviceName)); + setCaption(i18n("Configure %1").tqarg(deviceName)); m_page = new WdgTabletDeviceSettings(this); setMainWidget(m_page); - resize(m_page->sizeHint()); + resize(m_page->tqsizeHint()); - for (Q_INT32 axis = 0; axis < settings.numAxes(); axis++) { - QString axisString; + for (TQ_INT32 axis = 0; axis < settings.numAxes(); axis++) { + TQString axisString; axisString.setNum(axis); @@ -472,7 +472,7 @@ TabletSettingsTab::TabletDeviceSettingsDialog::~TabletDeviceSettingsDialog() TabletSettingsTab::DeviceSettings TabletSettingsTab::TabletDeviceSettingsDialog::settings() { - const Q_INT32 noAxis = m_settings.numAxes(); + const TQ_INT32 noAxis = m_settings.numAxes(); if (m_page->cbX->currentItem() != noAxis ) { m_settings.setXAxis(m_page->cbX->currentItem()); @@ -527,9 +527,9 @@ TabletSettingsTab::DeviceSettings TabletSettingsTab::TabletDeviceSettingsDialog: void TabletSettingsTab::initTabletDevices() { - connect(cbTabletDevice, SIGNAL(activated(int)), SLOT(slotActivateDevice(int))); - connect(chkEnableTabletDevice, SIGNAL(toggled(bool)), SLOT(slotSetDeviceEnabled(bool))); - connect(btnConfigureTabletDevice, SIGNAL(clicked()), SLOT(slotConfigureDevice())); + connect(cbTabletDevice, TQT_SIGNAL(activated(int)), TQT_SLOT(slotActivateDevice(int))); + connect(chkEnableTabletDevice, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotSetDeviceEnabled(bool))); + connect(btnConfigureTabletDevice, TQT_SIGNAL(clicked()), TQT_SLOT(slotConfigureDevice())); KisCanvasWidget::X11XIDTabletDeviceMap& tabletDevices = KisCanvasWidget::tabletDeviceMap(); @@ -574,7 +574,7 @@ void TabletSettingsTab::slotConfigureDevice() TabletDeviceSettingsDialog dialog(cbTabletDevice->currentText(), m_deviceSettings[cbTabletDevice->currentItem()], this, "TabletDeviceSettings"); - if (dialog.exec() == QDialog::Accepted) + if (dialog.exec() == TQDialog::Accepted) { m_deviceSettings[cbTabletDevice->currentItem()] = dialog.settings(); } @@ -582,14 +582,14 @@ void TabletSettingsTab::slotConfigureDevice() void TabletSettingsTab::applyTabletDeviceSettings() { - for (Q_UINT32 deviceIndex = 0; deviceIndex < m_deviceSettings.count(); ++deviceIndex) { + for (TQ_UINT32 deviceIndex = 0; deviceIndex < m_deviceSettings.count(); ++deviceIndex) { m_deviceSettings[deviceIndex].applySettings(); } } #else // EXTENDED_X11_TABLET_SUPPORT -// Fix compilation. moc seems to not see the undefined symbol needed +// Fix compilation. tqmoc seems to not see the undefined symbol needed // for these slots to be declared. void TabletSettingsTab::slotActivateDevice(int /*deviceIndex*/) { @@ -611,13 +611,13 @@ void TabletSettingsTab::applyTabletDeviceSettings() //--------------------------------------------------------------------------------------------------- -DisplaySettingsTab::DisplaySettingsTab( QWidget *parent, const char *name) - : WdgDisplaySettings( parent, name ) +DisplaySettingsTab::DisplaySettingsTab( TQWidget *tqparent, const char *name) + : WdgDisplaySettings( tqparent, name ) { #ifdef HAVE_GL KisConfig cfg; - if (!QGLFormat::hasOpenGL()) { + if (!TQGLFormat::hasOpenGL()) { cbUseOpenGL->setEnabled(false); //cbUseOpenGLShaders->setEnabled(false); } else { @@ -630,7 +630,7 @@ DisplaySettingsTab::DisplaySettingsTab( QWidget *parent, const char *name) //cbUseOpenGLShaders->setEnabled(false); #endif - connect(cbUseOpenGL, SIGNAL(toggled(bool)), SLOT(slotUseOpenGLToggled(bool))); + connect(cbUseOpenGL, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotUseOpenGLToggled(bool))); } void DisplaySettingsTab::setDefault() @@ -646,15 +646,15 @@ void DisplaySettingsTab::slotUseOpenGLToggled(bool /*isChecked*/) } //--------------------------------------------------------------------------------------------------- -GridSettingsTab::GridSettingsTab(QWidget* parent) : WdgGridSettingsBase(parent) +GridSettingsTab::GridSettingsTab(TQWidget* tqparent) : WdgGridSettingsBase(tqparent) { KisConfig cfg; selectMainStyle->setCurrentItem(cfg.getGridMainStyle()); selectSubdivisionStyle->setCurrentItem(cfg.getGridSubdivisionStyle()); #if KDE_IS_VERSION(3,4,0) - colorMain->setDefaultColor( QColor( 99, 99, 99 ) ); - colorSubdivision->setDefaultColor( QColor( 200, 200, 200 ) ); + colorMain->setDefaultColor( TQColor( 99, 99, 99 ) ); + colorSubdivision->setDefaultColor( TQColor( 200, 200, 200 ) ); #endif colorMain->setColor(cfg.getGridMainColor()); colorSubdivision->setColor(cfg.getGridSubdivisionColor()); @@ -666,10 +666,10 @@ GridSettingsTab::GridSettingsTab(QWidget* parent) : WdgGridSettingsBase(parent) intOffsetY->setValue( cfg.getGridOffsetY()); linkSpacingToggled(true); - connect(bnLinkSpacing, SIGNAL(toggled(bool)), this, SLOT(linkSpacingToggled( bool ))); + connect(bnLinkSpacing, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(linkSpacingToggled( bool ))); - connect(intHSpacing, SIGNAL(valueChanged(int)),this,SLOT(spinBoxHSpacingChanged(int))); - connect(intVSpacing, SIGNAL(valueChanged(int)),this,SLOT(spinBoxVSpacingChanged(int))); + connect(intHSpacing, TQT_SIGNAL(valueChanged(int)),this,TQT_SLOT(spinBoxHSpacingChanged(int))); + connect(intVSpacing, TQT_SIGNAL(valueChanged(int)),this,TQT_SLOT(spinBoxVSpacingChanged(int))); } @@ -680,8 +680,8 @@ void GridSettingsTab::setDefault() selectMainStyle->setCurrentItem(0); selectSubdivisionStyle->setCurrentItem(1); - colorMain->setColor(QColor(99,99,99)); - colorSubdivision->setColor(QColor(199,199,199)); + colorMain->setColor(TQColor(99,99,99)); + colorSubdivision->setColor(TQColor(199,199,199)); intHSpacing->setValue( 10 ); intVSpacing->setValue( 10 ); @@ -723,10 +723,10 @@ void GridSettingsTab::linkSpacingToggled(bool b) //--------------------------------------------------------------------------------------------------- -PreferencesDialog::PreferencesDialog( QWidget* parent, const char* name ) - : KDialogBase( IconList, i18n("Preferences"), Ok | Cancel | Help | Default /*| Apply*/, Ok, parent, name, true, true ) +PreferencesDialog::PreferencesDialog( TQWidget* tqparent, const char* name ) + : KDialogBase( IconList, i18n("Preferences"), Ok | Cancel | Help | Default /*| Apply*/, Ok, tqparent, name, true, true ) { - QVBox *vbox; + TQVBox *vbox; vbox = addVBoxPage( i18n( "General"), i18n( "General"), BarIcon( "misc", KIcon::SizeMedium )); m_general = new GeneralTab( vbox ); |
