diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-09-06 20:59:29 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-09-06 20:59:29 +0000 |
commit | 11f31c37e5fa4889d9989f10272f44845449cb7b (patch) | |
tree | 4383da04a76c497950d957fc6120b0fd0d9082c2 /src/gui/widgets/QuantizeParameters.cpp | |
parent | 832eb69d571e8e518db45d0c0e6fbc0f00690209 (diff) | |
download | rosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.tar.gz rosegarden-11f31c37e5fa4889d9989f10272f44845449cb7b.zip |
Initial TQt conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/rosegarden@1172292 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/gui/widgets/QuantizeParameters.cpp')
-rw-r--r-- | src/gui/widgets/QuantizeParameters.cpp | 98 |
1 files changed, 49 insertions, 49 deletions
diff --git a/src/gui/widgets/QuantizeParameters.cpp b/src/gui/widgets/QuantizeParameters.cpp index 19ba96a..1cb2a58 100644 --- a/src/gui/widgets/QuantizeParameters.cpp +++ b/src/gui/widgets/QuantizeParameters.cpp @@ -24,7 +24,7 @@ #include "QuantizeParameters.h" -#include <qlayout.h> +#include <tqlayout.h> #include <kapplication.h> #include <klocale.h> @@ -37,53 +37,53 @@ #include "gui/editors/notation/NotePixmapFactory.h" #include <kcombobox.h> #include <kconfig.h> -#include <qcheckbox.h> -#include <qframe.h> -#include <qgroupbox.h> -#include <qhbox.h> -#include <qlabel.h> -#include <qobject.h> -#include <qpixmap.h> -#include <qpushbutton.h> -#include <qstring.h> -#include <qwidget.h> +#include <tqcheckbox.h> +#include <tqframe.h> +#include <tqgroupbox.h> +#include <tqhbox.h> +#include <tqlabel.h> +#include <tqobject.h> +#include <tqpixmap.h> +#include <tqpushbutton.h> +#include <tqstring.h> +#include <tqwidget.h> namespace Rosegarden { -QuantizeParameters::QuantizeParameters(QWidget *parent, +QuantizeParameters::QuantizeParameters(TQWidget *parent, QuantizerType defaultQuantizer, bool showNotationOption, bool showAdvancedButton, - QString configCategory, - QString preamble) : - QFrame(parent), + TQString configCategory, + TQString preamble) : + TQFrame(parent), m_configCategory(configCategory), m_standardQuantizations (BasicQuantizer::getStandardQuantizations()) { - m_mainLayout = new QGridLayout(this, + m_mainLayout = new TQGridLayout(this, preamble ? 3 : 4, 2, preamble ? 10 : 0, preamble ? 5 : 4); int zero = 0; if (preamble) { - QLabel *label = new QLabel(preamble, this); + TQLabel *label = new TQLabel(preamble, this); label->setAlignment(Qt::WordBreak); m_mainLayout->addMultiCellWidget(label, 0, 0, 0, 1); zero = 1; } - QGroupBox *quantizerBox = new QGroupBox + TQGroupBox *quantizerBox = new QGroupBox (1, Horizontal, i18n("Quantizer"), this); m_mainLayout->addWidget(quantizerBox, zero, 0); - QFrame *typeFrame = new QFrame(quantizerBox); + TQFrame *typeFrame = new TQFrame(quantizerBox); - QGridLayout *layout = new QGridLayout(typeFrame, 2, 2, 5, 3); - layout->addWidget(new QLabel(i18n("Quantizer type:"), typeFrame), 0, 0); + TQGridLayout *layout = new TQGridLayout(typeFrame, 2, 2, 5, 3); + layout->addWidget(new TQLabel(i18n("Quantizer type:"), typeFrame), 0, 0); m_typeCombo = new KComboBox(typeFrame); m_typeCombo->insertItem(i18n("Grid quantizer")); m_typeCombo->insertItem(i18n("Legato quantizer")); @@ -97,21 +97,21 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, if (!showNotationOption) m_notationTarget->hide(); - QHBox *parameterBox = new QHBox(this); + TQHBox *parameterBox = new TQHBox(this); m_mainLayout->addWidget(parameterBox, zero + 1, 0); m_notationBox = new QGroupBox (1, Horizontal, i18n("Notation parameters"), parameterBox); - QFrame *notationFrame = new QFrame(m_notationBox); + TQFrame *notationFrame = new TQFrame(m_notationBox); - layout = new QGridLayout(notationFrame, 4, 2, 5, 3); + layout = new TQGridLayout(notationFrame, 4, 2, 5, 3); - layout->addWidget(new QLabel(i18n("Base grid unit:"), notationFrame), + layout->addWidget(new TQLabel(i18n("Base grid unit:"), notationFrame), 1, 0); m_notationUnitCombo = new KComboBox(notationFrame); layout->addWidget(m_notationUnitCombo, 1, 1); - layout->addWidget(new QLabel(i18n("Complexity:"), + layout->addWidget(new TQLabel(i18n("Complexity:"), notationFrame), 0, 0); m_simplicityCombo = new KComboBox(notationFrame); @@ -122,7 +122,7 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, m_simplicityCombo->insertItem(i18n("Very low")); layout->addWidget(m_simplicityCombo, 0, 1); - layout->addWidget(new QLabel(i18n("Tuplet level:"), + layout->addWidget(new TQLabel(i18n("Tuplet level:"), notationFrame), 2, 0); m_maxTuplet = new KComboBox(notationFrame); m_maxTuplet->insertItem(i18n("None")); @@ -138,25 +138,25 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, m_maxTuplet->insertItem(i18n("Any")); layout->addWidget(m_maxTuplet, 2, 1); - m_counterpoint = new QCheckBox(i18n("Permit counterpoint"), notationFrame); + m_counterpoint = new TQCheckBox(i18n("Permit counterpoint"), notationFrame); layout->addMultiCellWidget(m_counterpoint, 3, 3, 0, 1); m_gridBox = new QGroupBox (1, Horizontal, i18n("Grid parameters"), parameterBox); - QFrame *gridFrame = new QFrame(m_gridBox); + TQFrame *gridFrame = new TQFrame(m_gridBox); - layout = new QGridLayout(gridFrame, 4, 2, 5, 3); + layout = new TQGridLayout(gridFrame, 4, 2, 5, 3); - layout->addWidget(new QLabel(i18n("Base grid unit:"), gridFrame), 0, 0); + layout->addWidget(new TQLabel(i18n("Base grid unit:"), gridFrame), 0, 0); m_gridUnitCombo = new KComboBox(gridFrame); layout->addWidget(m_gridUnitCombo, 0, 1); - m_swingLabel = new QLabel(i18n("Swing:"), gridFrame); + m_swingLabel = new TQLabel(i18n("Swing:"), gridFrame); layout->addWidget(m_swingLabel, 1, 0); m_swingCombo = new KComboBox(gridFrame); layout->addWidget(m_swingCombo, 1, 1); - m_iterativeLabel = new QLabel(i18n("Iterative amount:"), gridFrame); + m_iterativeLabel = new TQLabel(i18n("Iterative amount:"), gridFrame); layout->addWidget(m_iterativeLabel, 2, 0); m_iterativeCombo = new KComboBox(gridFrame); layout->addWidget(m_iterativeCombo, 2, 1); @@ -180,27 +180,27 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, m_advancedButton = 0; if (showAdvancedButton) { m_advancedButton = - new QPushButton(i18n("Show advanced options"), this); + new TQPushButton(i18n("Show advanced options"), this); m_mainLayout->addWidget(m_advancedButton, zero + 2, 0, Qt::AlignLeft); - QObject::connect(m_advancedButton, SIGNAL(clicked()), - this, SLOT(slotAdvancedChanged())); + TQObject::connect(m_advancedButton, TQT_SIGNAL(clicked()), + this, TQT_SLOT(slotAdvancedChanged())); } - QFrame *postFrame = new QFrame(m_postProcessingBox); + TQFrame *postFrame = new TQFrame(m_postProcessingBox); - layout = new QGridLayout(postFrame, 4, 1, 5, 3); - m_rebeam = new QCheckBox(i18n("Re-beam"), postFrame); + layout = new TQGridLayout(postFrame, 4, 1, 5, 3); + m_rebeam = new TQCheckBox(i18n("Re-beam"), postFrame); m_articulate = new QCheckBox (i18n("Add articulations (staccato, tenuto, slurs)"), postFrame); - m_makeViable = new QCheckBox(i18n("Tie notes at barlines etc"), postFrame); - m_deCounterpoint = new QCheckBox(i18n("Split-and-tie overlapping chords"), postFrame); + m_makeViable = new TQCheckBox(i18n("Tie notes at barlines etc"), postFrame); + m_deCounterpoint = new TQCheckBox(i18n("Split-and-tie overlapping chords"), postFrame); layout->addWidget(m_rebeam, 0, 0); layout->addWidget(m_articulate, 1, 0); layout->addWidget(m_makeViable, 2, 0); layout->addWidget(m_deCounterpoint, 3, 0); - QPixmap noMap = NotePixmapFactory::toQPixmap + TQPixmap noMap = NotePixmapFactory::toQPixmap (NotePixmapFactory::makeToolbarPixmap("menu-no-note")); int defaultType = 0; @@ -278,16 +278,16 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, timeT time = m_standardQuantizations[i]; timeT error = 0; - QPixmap pmap = NotePixmapFactory::toQPixmap + TQPixmap pmap = NotePixmapFactory::toQPixmap (NotePixmapFactory::makeNoteMenuPixmap(time, error)); - QString label = NotationStrings::makeNoteMenuLabel(time, false, error); + TQString label = NotationStrings::makeNoteMenuLabel(time, false, error); if (error == 0) { m_gridUnitCombo->insertItem(pmap, label); m_notationUnitCombo->insertItem(pmap, label); } else { - m_gridUnitCombo->insertItem(noMap, QString("%1").arg(time)); - m_notationUnitCombo->insertItem(noMap, QString("%1").arg(time)); + m_gridUnitCombo->insertItem(noMap, TQString("%1").arg(time)); + m_notationUnitCombo->insertItem(noMap, TQString("%1").arg(time)); } if (m_standardQuantizations[i] == defaultUnit) { @@ -298,14 +298,14 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, } for (int i = -100; i <= 200; i += 10) { - m_swingCombo->insertItem(i == 0 ? i18n("None") : QString("%1%").arg(i)); + m_swingCombo->insertItem(i == 0 ? i18n("None") : TQString("%1%").arg(i)); if (i == defaultSwing) m_swingCombo->setCurrentItem(m_swingCombo->count() - 1); } for (int i = 10; i <= 100; i += 10) { m_iterativeCombo->insertItem(i == 100 ? i18n("Full quantize") : - QString("%1%").arg(i)); + TQString("%1%").arg(i)); if (i == defaultIterate) m_iterativeCombo->setCurrentItem(m_iterativeCombo->count() - 1); } @@ -337,7 +337,7 @@ QuantizeParameters::QuantizeParameters(QWidget *parent, break; } - connect(m_typeCombo, SIGNAL(activated(int)), SLOT(slotTypeChanged(int))); + connect(m_typeCombo, TQT_SIGNAL(activated(int)), TQT_SLOT(slotTypeChanged(int))); } Quantizer * |