diff options
Diffstat (limited to 'lib/kofficeui/KoUnitWidgets.cpp')
-rw-r--r-- | lib/kofficeui/KoUnitWidgets.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/lib/kofficeui/KoUnitWidgets.cpp b/lib/kofficeui/KoUnitWidgets.cpp index a5af7bdf..476e35b3 100644 --- a/lib/kofficeui/KoUnitWidgets.cpp +++ b/lib/kofficeui/KoUnitWidgets.cpp @@ -24,7 +24,7 @@ #include <kglobal.h> #include <klocale.h> #include <tqpushbutton.h> -#include <layout.h> +#include <tqlayout.h> // ---------------------------------------------------------------- @@ -90,7 +90,7 @@ KoUnitDoubleValidator::validate( TQString &s, int &pos ) const TQString KoUnitDoubleBase::getVisibleText( double value ) const { - const TQString num ( TQString( "%1%2").arg( KGlobal::locale()->formatNumber( value, m_precision ), KoUnit::unitName( m_unit ) ) ); + const TQString num ( TQString( "%1%2").tqarg( KGlobal::locale()->formatNumber( value, m_precision ), KoUnit::unitName( m_unit ) ) ); kdDebug(30004) << "getVisibleText: " << TQString::number( value, 'f', 12 ) << " => " << num << endl; return num; } @@ -223,7 +223,7 @@ KoUnitDoubleLineEdit::KoUnitDoubleLineEdit( TQWidget *parent, const char *name ) : KLineEdit( parent, name ), KoUnitDoubleBase( KoUnit::U_PT, 2 ), m_value( 0.0 ), m_lower( 0.0 ), m_upper( 9999.99 ), m_lowerInPoints( 0.0 ), m_upperInPoints( 9999.99 ) { - setAlignment( TQt::AlignRight ); + tqsetAlignment( TQt::AlignRight ); m_validator = new KoUnitDoubleValidator( this, TQT_TQOBJECT(this) ); setValidator( m_validator ); setUnit( KoUnit::U_PT ); @@ -235,7 +235,7 @@ KoUnitDoubleLineEdit::KoUnitDoubleLineEdit( TQWidget *parent, double lower, doub : KLineEdit( parent, name ), KoUnitDoubleBase( unit, precision ), m_value( value ), m_lower( lower ), m_upper( upper ), m_lowerInPoints( lower ), m_upperInPoints( upper ) { - setAlignment( TQt::AlignRight ); + tqsetAlignment( TQt::AlignRight ); m_validator = new KoUnitDoubleValidator( this, TQT_TQOBJECT(this) ); setValidator( m_validator ); setUnit( unit ); @@ -287,7 +287,7 @@ double KoUnitDoubleLineEdit::value( void ) const KoUnitDoubleComboBox::KoUnitDoubleComboBox( TQWidget *parent, const char *name ) : KComboBox( true, parent, name ), KoUnitDoubleBase( KoUnit::U_PT, 2 ), m_value( 0.0 ), m_lower( 0.0 ), m_upper( 9999.99 ), m_lowerInPoints( 0.0 ), m_upperInPoints( 9999.99 ) { - lineEdit()->setAlignment( TQt::AlignRight ); + lineEdit()->tqsetAlignment( TQt::AlignRight ); m_validator = new KoUnitDoubleValidator( this, TQT_TQOBJECT(this) ); lineEdit()->setValidator( m_validator ); setUnit( KoUnit::U_PT ); @@ -300,7 +300,7 @@ KoUnitDoubleComboBox::KoUnitDoubleComboBox( TQWidget *parent, double lower, doub : KComboBox( true, parent, name ), KoUnitDoubleBase( unit, precision ), m_value( value ), m_lower( lower ), m_upper( upper ), m_lowerInPoints( lower ), m_upperInPoints( upper ) { - lineEdit()->setAlignment( TQt::AlignRight ); + lineEdit()->tqsetAlignment( TQt::AlignRight ); m_validator = new KoUnitDoubleValidator( this, TQT_TQOBJECT(this) ); lineEdit()->setValidator( m_validator ); setUnit( unit ); @@ -379,48 +379,48 @@ double KoUnitDoubleComboBox::value( void ) const KoUnitDoubleSpinComboBox::KoUnitDoubleSpinComboBox( TQWidget *parent, const char *name ) : TQWidget( parent ), m_step( 1.0 ) { - TQGridLayout *layout = new TQGridLayout( this, 2, 3 ); - //layout->setMargin( 2 ); + TQGridLayout *tqlayout = new TQGridLayout( this, 2, 3 ); + //tqlayout->setMargin( 2 ); TQPushButton *up = new TQPushButton( "+", this ); //up->setFlat( true ); up->setMaximumHeight( 15 ); up->setMaximumWidth( 15 ); - layout->addWidget( up, 0, 0 ); + tqlayout->addWidget( up, 0, 0 ); connect( up, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotUpClicked() ) ); TQPushButton *down = new TQPushButton( "-", this ); down->setMaximumHeight( 15 ); down->setMaximumWidth( 15 ); - layout->addWidget( down, 1, 0 ); + tqlayout->addWidget( down, 1, 0 ); connect( down, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotDownClicked() ) ); m_combo = new KoUnitDoubleComboBox( this, KoUnit::ptToUnit( 0.0, KoUnit::U_PT ), KoUnit::ptToUnit( 9999.99, KoUnit::U_PT ), 0.0, KoUnit::U_PT, 2, name ); connect( m_combo, TQT_SIGNAL( valueChanged( double ) ), this, TQT_SIGNAL( valueChanged( double ) ) ); - layout->addMultiCellWidget( m_combo, 0, 1, 2, 2 ); + tqlayout->addMultiCellWidget( m_combo, 0, 1, 2, 2 ); } KoUnitDoubleSpinComboBox::KoUnitDoubleSpinComboBox( TQWidget *parent, double lower, double upper, double step, double value, KoUnit::Unit unit, unsigned int precision, const char *name ) : TQWidget( parent ), m_step( step )//, m_lowerInPoints( lower ), m_upperInPoints( upper ) { - TQGridLayout *layout = new TQGridLayout( this, 2, 3 ); - //layout->setMargin( 2 ); + TQGridLayout *tqlayout = new TQGridLayout( this, 2, 3 ); + //tqlayout->setMargin( 2 ); TQPushButton *up = new TQPushButton( "+", this ); //up->setFlat( true ); up->setMaximumHeight( 15 ); up->setMaximumWidth( 15 ); - layout->addWidget( up, 0, 0 ); + tqlayout->addWidget( up, 0, 0 ); connect( up, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotUpClicked() ) ); TQPushButton *down = new TQPushButton( "-", this ); down->setMaximumHeight( 15 ); down->setMaximumWidth( 15 ); - layout->addWidget( down, 1, 0 ); + tqlayout->addWidget( down, 1, 0 ); connect( down, TQT_SIGNAL( clicked() ), this, TQT_SLOT( slotDownClicked() ) ); m_combo = new KoUnitDoubleComboBox( this, KoUnit::ptToUnit( lower, unit ), KoUnit::ptToUnit( upper, unit ), value, unit, precision, name ); connect( m_combo, TQT_SIGNAL( valueChanged( double ) ), this, TQT_SIGNAL( valueChanged( double ) ) ); - layout->addMultiCellWidget( m_combo, 0, 1, 2, 2 ); + tqlayout->addMultiCellWidget( m_combo, 0, 1, 2, 2 ); } void |