summaryrefslogtreecommitdiffstats
path: root/kspread/dialogs/kspread_dlg_layout.cc
diff options
context:
space:
mode:
Diffstat (limited to 'kspread/dialogs/kspread_dlg_layout.cc')
-rw-r--r--kspread/dialogs/kspread_dlg_layout.cc1092
1 files changed, 546 insertions, 546 deletions
diff --git a/kspread/dialogs/kspread_dlg_layout.cc b/kspread/dialogs/kspread_dlg_layout.cc
index e86e3271..6b5c233b 100644
--- a/kspread/dialogs/kspread_dlg_layout.cc
+++ b/kspread/dialogs/kspread_dlg_layout.cc
@@ -32,16 +32,16 @@
#include <stdlib.h>
#include <math.h>
-#include <qbitmap.h>
-#include <qcheckbox.h>
-#include <qframe.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qlistbox.h>
-#include <qfontdatabase.h>
-#include <qradiobutton.h>
-#include <qslider.h>
-#include <qwhatsthis.h>
+#include <tqbitmap.h>
+#include <tqcheckbox.h>
+#include <tqframe.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqlistbox.h>
+#include <tqfontdatabase.h>
+#include <tqradiobutton.h>
+#include <tqslider.h>
+#include <tqwhatsthis.h>
#include <kcolorbutton.h>
#include <kcombobox.h>
@@ -73,22 +73,22 @@ using namespace KSpread;
*
***************************************************************************/
-PatternSelect::PatternSelect( QWidget *parent, const char * )
- : QFrame( parent )
+PatternSelect::PatternSelect( TQWidget *tqparent, const char * )
+ : TQFrame( tqparent )
{
- penStyle = NoPen;
+ penStyle = Qt::NoPen;
penWidth = 1;
- penColor = colorGroup().text();
+ penColor = tqcolorGroup().text();
selected = false;
undefined = false;
}
-void PatternSelect::setPattern( const QColor &_color, int _width, PenStyle _style )
+void PatternSelect::setPattern( const TQColor &_color, int _width, Qt::PenStyle _style )
{
penStyle = _style;
penColor = _color;
penWidth = _width;
- repaint();
+ tqrepaint();
}
void PatternSelect::setUndefined()
@@ -96,15 +96,15 @@ void PatternSelect::setUndefined()
undefined = true;
}
-void PatternSelect::paintEvent( QPaintEvent *_ev )
+void PatternSelect::paintEvent( TQPaintEvent *_ev )
{
- QFrame::paintEvent( _ev );
+ TQFrame::paintEvent( _ev );
- QPainter painter( this );
+ TQPainter painter( this );
if ( !undefined )
{
- QPen pen( penColor, penWidth, penStyle);
+ TQPen pen( penColor, penWidth, penStyle);
painter.setPen( pen );
painter.drawLine( 6, height()/2, width() - 6,height()/2 );
}
@@ -114,7 +114,7 @@ void PatternSelect::paintEvent( QPaintEvent *_ev )
}
}
-void PatternSelect::mousePressEvent( QMouseEvent * )
+void PatternSelect::mousePressEvent( TQMouseEvent * )
{
slotSelect();
@@ -126,8 +126,8 @@ void PatternSelect::slotUnselect()
selected = false;
setLineWidth( 1 );
- setFrameStyle( QFrame::Panel | QFrame::Sunken );
- repaint();
+ setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
+ tqrepaint();
}
void PatternSelect::slotSelect()
@@ -135,8 +135,8 @@ void PatternSelect::slotSelect()
selected = true;
setLineWidth( 2 );
- setFrameStyle( QFrame::Panel | QFrame::Plain );
- repaint();
+ setFrameStyle( TQFrame::Panel | TQFrame::Plain );
+ tqrepaint();
}
@@ -147,22 +147,22 @@ void PatternSelect::slotSelect()
*
***************************************************************************/
-GeneralTab::GeneralTab( QWidget* parent, CellFormatDialog * dlg )
- : QWidget( parent ),
+GeneralTab::GeneralTab( TQWidget* tqparent, CellFormatDialog * dlg )
+ : TQWidget( tqparent ),
m_dlg( dlg )
{
- QGridLayout * layout = new QGridLayout( this, 1, 1, KDialog::marginHint(), KDialog::spacingHint(), "layout");
+ TQGridLayout * tqlayout = new TQGridLayout( this, 1, 1, KDialog::marginHint(), KDialog::spacingHint(), "tqlayout");
- QGroupBox * groupBox = new QGroupBox( this, "groupBox1" );
+ TQGroupBox * groupBox = new TQGroupBox( this, "groupBox1" );
groupBox->setColumnLayout(0, Qt::Vertical );
groupBox->setTitle( i18n( "Style" ) );
- groupBox->layout()->setSpacing( KDialog::spacingHint() );
- groupBox->layout()->setMargin( KDialog::marginHint() );
+ groupBox->tqlayout()->setSpacing( KDialog::spacingHint() );
+ groupBox->tqlayout()->setMargin( KDialog::marginHint() );
- QGridLayout * groupBoxLayout = new QGridLayout( groupBox->layout() );
- groupBoxLayout->setAlignment( Qt::AlignTop );
+ TQGridLayout * groupBoxLayout = new TQGridLayout( groupBox->tqlayout() );
+ groupBoxLayout->tqsetAlignment( TQt::AlignTop );
- QLabel * label1 = new QLabel( groupBox, "label1" );
+ TQLabel * label1 = new TQLabel( groupBox, "label1" );
label1->setText( i18n( "Name:" ) );
groupBoxLayout->addWidget( label1, 0, 0 );
@@ -170,19 +170,19 @@ GeneralTab::GeneralTab( QWidget* parent, CellFormatDialog * dlg )
m_nameEdit->setText( m_dlg->styleName );
groupBoxLayout->addWidget( m_nameEdit, 0, 1 );
- QLabel * label2 = new QLabel( groupBox, "label2" );
+ TQLabel * label2 = new TQLabel( groupBox, "label2" );
label2->setText( i18n( "Inherit style:" ) );
groupBoxLayout->addWidget( label2, 1, 0 );
m_parentBox = new KComboBox( false, groupBox, "m_parentBox" );
m_parentBox->clear();
m_parentBox->insertItem( i18n( "<None>" ) );
- QStringList tmp = m_dlg->getStyleManager()->styleNames();
+ TQStringList tmp = m_dlg->getStyleManager()->styleNames();
tmp.remove( m_dlg->styleName );
m_parentBox->insertStringList( tmp );
- if ( m_dlg->getStyle()->parent() )
- m_parentBox->setCurrentText( m_dlg->getStyle()->parentName() );
+ if ( m_dlg->getStyle()->tqparent() )
+ m_parentBox->setCurrentText( m_dlg->getStyle()->tqparentName() );
else
{
m_parentBox->setCurrentText( i18n( "<None>" ) );
@@ -191,15 +191,15 @@ GeneralTab::GeneralTab( QWidget* parent, CellFormatDialog * dlg )
m_parentBox->setEnabled( false );
}
- connect( m_parentBox, SIGNAL( textChanged( const QString & ) ), this, SLOT( slotNewParent( const QString & ) ) );
- connect( m_nameEdit, SIGNAL( lostFocus() ), this, SLOT( slotNameChanged() ) );
+ connect( m_parentBox, TQT_SIGNAL( textChanged( const TQString & ) ), this, TQT_SLOT( slotNewParent( const TQString & ) ) );
+ connect( m_nameEdit, TQT_SIGNAL( lostFocus() ), this, TQT_SLOT( slotNameChanged() ) );
groupBoxLayout->addWidget( m_parentBox, 1, 1 );
- QSpacerItem * spacer = new QSpacerItem( 20, 260, QSizePolicy::Minimum, QSizePolicy::Expanding );
+ TQSpacerItem * spacer = new TQSpacerItem( 20, 260, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
- layout->addWidget( groupBox, 0, 0 );
- layout->addItem( spacer, 1, 0 );
+ tqlayout->addWidget( groupBox, 0, 0 );
+ tqlayout->addItem( spacer, 1, 0 );
if ( m_dlg->getStyle()->type() == Style::BUILTIN )
{
@@ -207,7 +207,7 @@ GeneralTab::GeneralTab( QWidget* parent, CellFormatDialog * dlg )
m_parentBox->setEnabled( false );
}
- resize( QSize( 534, 447 ).expandedTo(minimumSizeHint()) );
+ resize( TQSize( 534, 447 ).expandedTo(tqminimumSizeHint()) );
}
GeneralTab::~GeneralTab()
@@ -219,18 +219,18 @@ void GeneralTab::slotNameChanged()
checkName();
}
-void GeneralTab::slotNewParent( const QString & parentName )
+void GeneralTab::slotNewParent( const TQString & tqparentName )
{
kdDebug() << "New Parent" << endl;
- if ( !checkParent( parentName ) )
+ if ( !checkParent( tqparentName ) )
return;
- if ( parentName.isEmpty() || parentName == i18n( "<None>" ) )
+ if ( tqparentName.isEmpty() || tqparentName == i18n( "<None>" ) )
m_dlg->getStyle()->setParent( 0 );
else
- m_dlg->getStyle()->setParent( m_dlg->getStyleManager()->style( parentName ) );
+ m_dlg->getStyle()->setParent( m_dlg->getStyleManager()->style( tqparentName ) );
- // Set difference to new parent, set GUI to parent values, add changes made before
+ // Set difference to new tqparent, set GUI to tqparent values, add changes made before
// m_dlg->initGUI();
}
@@ -248,29 +248,29 @@ bool GeneralTab::checkName()
return true;
}
-bool GeneralTab::checkParent( const QString & parentName )
+bool GeneralTab::checkParent( const TQString & tqparentName )
{
- if ( m_dlg->getStyle()->parentName() != parentName
- && m_parentBox->isEnabled() && parentName != i18n( "<None>" ) && !parentName.isEmpty() )
+ if ( m_dlg->getStyle()->tqparentName() != tqparentName
+ && m_parentBox->isEnabled() && tqparentName != i18n( "<None>" ) && !tqparentName.isEmpty() )
{
- if ( m_nameEdit->text() == parentName )
+ if ( m_nameEdit->text() == tqparentName )
{
KMessageBox::sorry( this, i18n( "A style cannot inherit from itself." ) );
return false;
}
- if ( !m_dlg->checkCircle( m_nameEdit->text(), parentName ) )
+ if ( !m_dlg->checkCircle( m_nameEdit->text(), tqparentName ) )
{
KMessageBox::sorry( this,
i18n( "The style cannot inherit from '%1' because of recursive references." )
- .arg( m_parentBox->currentText() ) );
+ .tqarg( m_parentBox->currentText() ) );
return false;
}
- CustomStyle * p = m_dlg->getStyleManager()->style( parentName );
+ CustomStyle * p = m_dlg->getStyleManager()->style( tqparentName );
if ( !p )
{
- KMessageBox::sorry( this, i18n( "The parent style does not exist." ) );
+ KMessageBox::sorry( this, i18n( "The tqparent style does not exist." ) );
return false;
}
}
@@ -290,7 +290,7 @@ bool GeneralTab::apply( CustomStyle * style )
{
if ( style->type() != Style::BUILTIN )
{
- QString name( style->name() );
+ TQString name( style->name() );
style->setName( m_nameEdit->text() );
if ( m_parentBox->isEnabled() )
{
@@ -318,7 +318,7 @@ bool GeneralTab::apply( CustomStyle * style )
***************************************************************************/
CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
- : QObject(),
+ : TQObject(),
m_doc( _sheet->doc() ),
m_sheet( _sheet ),
m_pView( _view ),
@@ -330,7 +330,7 @@ CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
isRowSelected = _view->selectionInfo()->isRowSelected();
isColumnSelected = _view->selectionInfo()->isColumnSelected();
- QRect range = _view->selectionInfo()->selection();
+ TQRect range = _view->selectionInfo()->selection();
left = range.left();
top = range.top();
right = range.right();
@@ -430,7 +430,7 @@ CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
textFontItalic = obj->format()->textFontItalic( left, top );
strike=obj->format()->textFontStrike( left, top );
underline = obj->format()->textFontUnderline( left, top );
- // Needed to initialize the font correctly ( bug in Qt )
+ // Needed to initialize the font correctly ( bug in TQt )
textFont = obj->format()->textFont( left, top );
obj->format()->currencyInfo( cCurrency );
@@ -461,7 +461,7 @@ CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
for ( int x = left; x <= right; x++ )
{
cl = m_pView->activeSheet()->columnFormat( x );
- widthSize = QMAX( cl->dblWidth(), widthSize );
+ widthSize = TQMAX( cl->dblWidth(), widthSize );
}
}
@@ -470,7 +470,7 @@ CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
for ( int y = top; y <= bottom; y++ )
{
rl = m_pView->activeSheet()->rowFormat(y);
- heightSize = QMAX( rl->dblHeight(), heightSize );
+ heightSize = TQMAX( rl->dblHeight(), heightSize );
}
}
@@ -629,7 +629,7 @@ CellFormatDialog::CellFormatDialog( View * _view, Sheet * _sheet )
CellFormatDialog::CellFormatDialog( View * _view, CustomStyle * _style,
StyleManager * _manager, Doc * doc )
- : QObject(),
+ : TQObject(),
m_doc( doc ),
m_sheet( 0 ),
m_pView( _view ),
@@ -696,7 +696,7 @@ void CellFormatDialog::initGUI()
strike = ( flags & (uint) Style::FStrike );
underline = ( flags & (uint) Style::FUnderline );
- // Needed to initialize the font correctly ( bug in Qt )
+ // Needed to initialize the font correctly ( bug in TQt )
textFont = m_style->font();
cCurrency = m_style->currency();
brushColor = m_style->backGroundBrush().color();
@@ -766,9 +766,9 @@ void CellFormatDialog::initMembers()
defaultHeightSize = sheet ? sheet->rowFormat(0)->dblHeight() : 0;
}
-bool CellFormatDialog::checkCircle( QString const & name, QString const & parent )
+bool CellFormatDialog::checkCircle( TQString const & name, TQString const & tqparent )
{
- return m_styleManager->checkCircle( name, parent );
+ return m_styleManager->checkCircle( name, tqparent );
}
void CellFormatDialog::checkBorderRight(Format *obj,int x,int y)
@@ -846,9 +846,9 @@ void CellFormatDialog::initParameters(Format *obj,int x,int y)
if ( underline != obj->textFontUnderline( x, y ) )
bUnderline = false;
if ( prefix != obj->prefix( x, y ) )
- prefix = QString::null;
+ prefix = TQString();
if ( postfix != obj->postfix( x, y ) )
- postfix = QString::null;
+ postfix = TQString();
if ( floatFormat != obj->floatFormat( x, y ) )
bFloatFormat = false;
if ( floatColor != obj->floatColor( x, y ) )
@@ -886,20 +886,20 @@ void CellFormatDialog::initParameters(Format *obj,int x,int y)
void CellFormatDialog::init()
{
- QColorGroup colorGroup = QApplication::palette().active();
+ TQColorGroup tqcolorGroup = TQApplication::tqpalette().active();
// Did we initialize the bitmaps ?
if ( formatOnlyNegSignedPixmap == 0L )
{
- QColor black = colorGroup.text(); // not necessarily black :)
+ TQColor black = tqcolorGroup.text(); // not necessarily black :)
formatOnlyNegSignedPixmap = paintFormatPixmap( "123.456", black, "-123.456", black );
- formatRedOnlyNegSignedPixmap = paintFormatPixmap( "123.456", black, "-123.456", Qt::red );
- formatRedNeverSignedPixmap = paintFormatPixmap( "123.456", black, "123.456", Qt::red );
+ formatRedOnlyNegSignedPixmap = paintFormatPixmap( "123.456", black, "-123.456", TQt::red );
+ formatRedNeverSignedPixmap = paintFormatPixmap( "123.456", black, "123.456", TQt::red );
formatAlwaysSignedPixmap = paintFormatPixmap( "+123.456", black, "-123.456", black );
- formatRedAlwaysSignedPixmap = paintFormatPixmap( "+123.456", black, "-123.456", Qt::red );
+ formatRedAlwaysSignedPixmap = paintFormatPixmap( "+123.456", black, "-123.456", TQt::red );
}
- tab = new QTabDialog( (QWidget*)m_pView, 0L, true );
+ tab = new TQTabDialog( (TQWidget*)m_pView, 0L, true );
//tab->setGeometry( tab->x(), tab->y(), 420, 400 );
if ( m_style )
@@ -936,31 +936,31 @@ void CellFormatDialog::init()
tab->adjustSize();
- connect( tab, SIGNAL( applyButtonPressed() ), this, SLOT( slotApply() ) );
+ connect( tab, TQT_SIGNAL( applyButtonPressed() ), this, TQT_SLOT( slotApply() ) );
tab->exec();
}
-QPixmap * CellFormatDialog::paintFormatPixmap( const char * _string1, const QColor & _color1,
- const char *_string2, const QColor & _color2 )
+TQPixmap * CellFormatDialog::paintFormatPixmap( const char * _string1, const TQColor & _color1,
+ const char *_string2, const TQColor & _color2 )
{
- QPixmap * pixmap = new QPixmap( 150, 14 );
+ TQPixmap * pixmap = new TQPixmap( 150, 14 );
- QPainter painter;
+ TQPainter painter;
painter.begin( pixmap );
- painter.fillRect( 0, 0, 150, 14, QApplication::palette().active().base() );
+ painter.fillRect( 0, 0, 150, 14, TQApplication::tqpalette().active().base() );
painter.setPen( _color1 );
- painter.drawText( 2, 11, _string1 );
+ painter.drawText( 2, 11, TQString(_string1) );
painter.setPen( _color2 );
- painter.drawText( 75, 11, _string2 );
+ painter.drawText( 75, 11, TQString(_string2) );
painter.end();
- QBitmap bm( pixmap->size() );
+ TQBitmap bm( pixmap->size() );
bm.fill( color0 );
painter.begin( &bm );
painter.setPen( color1 );
- painter.drawText( 2, 11, _string1 );
- painter.drawText( 75, 11, _string2 );
+ painter.drawText( 2, 11, TQString(_string1) );
+ painter.drawText( 75, 11, TQString(_string2) );
painter.end();
pixmap->setMask( bm );
@@ -1078,116 +1078,116 @@ void CellFormatDialog::slotApply()
*
***************************************************************************/
-CellFormatPageFloat::CellFormatPageFloat( QWidget* parent, CellFormatDialog *_dlg )
- : QWidget ( parent ),
+CellFormatPageFloat::CellFormatPageFloat( TQWidget* tqparent, CellFormatDialog *_dlg )
+ : TQWidget ( tqparent ),
dlg( _dlg )
{
- QVBoxLayout* layout = new QVBoxLayout( this, 6,10 );
+ TQVBoxLayout* tqlayout = new TQVBoxLayout( this, 6,10 );
- QButtonGroup *grp = new QButtonGroup( i18n("Format"),this);
- QGridLayout *grid = new QGridLayout(grp,11,2,KDialog::marginHint(), KDialog::spacingHint());
+ TQButtonGroup *grp = new TQButtonGroup( i18n("Format"),this);
+ TQGridLayout *grid = new TQGridLayout(grp,11,2,KDialog::marginHint(), KDialog::spacingHint());
int fHeight = grp->fontMetrics().height();
grid->addRowSpacing( 0, fHeight/2 ); // groupbox title
grp->setRadioButtonExclusive( true );
- generic=new QRadioButton(i18n("Generic"),grp);
- QWhatsThis::add(generic, i18n( "This is the default format and KSpread autodetects the actual data type depending on the current cell data. By default, KSpread right justifies numbers, dates and times within a cell and left justifies anything else." ) );
+ generic=new TQRadioButton(i18n("Generic"),grp);
+ TQWhatsThis::add(generic, i18n( "This is the default format and KSpread autodetects the actual data type depending on the current cell data. By default, KSpread right justifies numbers, dates and times within a cell and left justifies anything else." ) );
grid->addWidget(generic,1,0);
- number=new QRadioButton(i18n("Number"),grp);
- QWhatsThis::add(number, i18n( "The number notation uses the notation you globally choose in KControl -> Regional & Accessibility -> Numbers tab. Numbers are right justified by default." ) );
+ number=new TQRadioButton(i18n("Number"),grp);
+ TQWhatsThis::add(number, i18n( "The number notation uses the notation you globally choose in KControl -> Regional & Accessibility -> Numbers tab. Numbers are right justified by default." ) );
grid->addWidget(number,2,0);
- percent=new QRadioButton(i18n("Percent"),grp);
- QWhatsThis::add(percent, i18n( "When you have a number in the current cell and you switch from the dcell format from Generic to Percent, the current cell number will be multiplied by 100%.\nFor example if you enter 12 and set the cell format to Percent, the number will then be 1,200 %. Switching back to Generic cell format will bring it back to 12.\nYou can also use the Percent icon in the Format Toolbar." ) );
+ percent=new TQRadioButton(i18n("Percent"),grp);
+ TQWhatsThis::add(percent, i18n( "When you have a number in the current cell and you switch from the dcell format from Generic to Percent, the current cell number will be multiplied by 100%.\nFor example if you enter 12 and set the cell format to Percent, the number will then be 1,200 %. Switching back to Generic cell format will bring it back to 12.\nYou can also use the Percent icon in the Format Toolbar." ) );
grid->addWidget(percent,3,0);
- money=new QRadioButton(i18n("Money"),grp);
- QWhatsThis::add(money, i18n( "The Money format converts your number into money notation using the settings globally fixed in KControl in Regional & Accessibility -> Money. The currency symbol will be displayed and the precision will be the one set in KControl.\nYou can also use the Currency icon in the Format Toolbar to set the cell formatting to look like your current currency." ) );
+ money=new TQRadioButton(i18n("Money"),grp);
+ TQWhatsThis::add(money, i18n( "The Money format converts your number into money notation using the settings globally fixed in KControl in Regional & Accessibility -> Money. The currency symbol will be displayed and the precision will be the one set in KControl.\nYou can also use the Currency icon in the Format Toolbar to set the cell formatting to look like your current currency." ) );
grid->addWidget(money,4,0);
- scientific=new QRadioButton(i18n("Scientific"),grp);
- QWhatsThis::add(scientific, i18n( "The scientific format changes your number using the scientific notation. For example, 0.0012 will be changed to 1.2E-03. Going back using Generic cell format will display 0.0012 again." ) );
+ scientific=new TQRadioButton(i18n("Scientific"),grp);
+ TQWhatsThis::add(scientific, i18n( "The scientific format changes your number using the scientific notation. For example, 0.0012 will be changed to 1.2E-03. Going back using Generic cell format will display 0.0012 again." ) );
grid->addWidget(scientific,5,0);
- fraction=new QRadioButton(i18n("Fraction"),grp);
- QWhatsThis::add(fraction, i18n( "The fraction format changes your number into a fraction. For example, 0.1 can be changed to 1/8, 2/16, 1/10, etc. You define the type of fraction by choosing it in the field on the right. If the exact fraction is not possible in the fraction mode you choose, the nearest closest match is chosen.\n For example: when we have 1.5 as number, we choose Fraction and Sixteenths 1/16 the text displayed into cell is \"1 8/16\" which is an exact fraction. If you have 1.4 as number in your cell and you choose Fraction and Sixteenths 1/16 then the cell will display \"1 6/16\" which is the nearest closest Sixteenth fraction." ) );
+ fraction=new TQRadioButton(i18n("Fraction"),grp);
+ TQWhatsThis::add(fraction, i18n( "The fraction format changes your number into a fraction. For example, 0.1 can be changed to 1/8, 2/16, 1/10, etc. You define the type of fraction by choosing it in the field on the right. If the exact fraction is not possible in the fraction mode you choose, the nearest closest match is chosen.\n For example: when we have 1.5 as number, we choose Fraction and Sixteenths 1/16 the text displayed into cell is \"1 8/16\" which is an exact fraction. If you have 1.4 as number in your cell and you choose Fraction and Sixteenths 1/16 then the cell will display \"1 6/16\" which is the nearest closest Sixteenth fraction." ) );
grid->addWidget(fraction,6,0);
- date=new QRadioButton(i18n("Date format"),grp);
- QWhatsThis::add(date, i18n( "To enter a date, you should enter it in one of the formats set in KControl in Regional & Accessibility ->Time & Dates. There are two formats set here: the date format and the short date format.\nJust like you can drag down numbers you can also drag down dates and the next cells will also get dates." ) );
+ date=new TQRadioButton(i18n("Date format"),grp);
+ TQWhatsThis::add(date, i18n( "To enter a date, you should enter it in one of the formats set in KControl in Regional & Accessibility ->Time & Dates. There are two formats set here: the date format and the short date format.\nJust like you can drag down numbers you can also drag down dates and the next cells will also get dates." ) );
grid->addWidget(date,7,0);
- time=new QRadioButton(i18n("Time format"),grp);
- QWhatsThis::add(time, i18n( "This formats your cell content as a time. To enter a time, you should enter it in the Time format set in KControl in Regional & Accessibility ->Time & Dates. In the Cell Format dialog box you can set how the time should be displayed by choosing one of the available time format options. The default format is the system format set in KControl. When the number in the cell does not make sense as a time, KSpread will display 00:00 in the global format you have in KControl." ) );
+ time=new TQRadioButton(i18n("Time format"),grp);
+ TQWhatsThis::add(time, i18n( "This formats your cell content as a time. To enter a time, you should enter it in the Time format set in KControl in Regional & Accessibility ->Time & Dates. In the Cell Format dialog box you can set how the time should be displayed by choosing one of the available time format options. The default format is the system format set in KControl. When the number in the cell does not make sense as a time, KSpread will display 00:00 in the global format you have in KControl." ) );
grid->addWidget(time,8,0);
- textFormat=new QRadioButton(i18n("Text"),grp);
- QWhatsThis::add(textFormat, i18n( "This formats your cell content as text. This can be useful if you want a number treated as text instead as a number, for example for a ZIP code. Setting a number as text format will left justify it. When numbers are formatted as text, they cannot be used in calculations or formulas. It also change the way the cell is justified." ) );
+ textFormat=new TQRadioButton(i18n("Text"),grp);
+ TQWhatsThis::add(textFormat, i18n( "This formats your cell content as text. This can be useful if you want a number treated as text instead as a number, for example for a ZIP code. Setting a number as text format will left justify it. When numbers are formatted as text, they cannot be used in calculations or formulas. It also change the way the cell is justified." ) );
grid->addWidget(textFormat,9,0);
- customFormat=new QRadioButton(i18n("Custom"),grp);
- QWhatsThis::add(customFormat, i18n( "The custom format does not work yet. To be enabled in the next release." ) );
+ customFormat=new TQRadioButton(i18n("Custom"),grp);
+ TQWhatsThis::add(customFormat, i18n( "The custom format does not work yet. To be enabled in the next release." ) );
grid->addWidget(customFormat,10,0);
customFormat->setEnabled( false );
- QGroupBox *box2 = new QGroupBox( grp, "Box");
+ TQGroupBox *box2 = new TQGroupBox( grp, "Box");
box2->setTitle(i18n("Preview"));
- QGridLayout *grid3 = new QGridLayout(box2,1,3,KDialog::marginHint(), KDialog::spacingHint());
+ TQGridLayout *grid3 = new TQGridLayout(box2,1,3,KDialog::marginHint(), KDialog::spacingHint());
- exampleLabel=new QLabel(box2);
- QWhatsThis::add(exampleLabel, i18n( "This will display a preview of your choice so you can know what it does before clicking the OK button to validate it." ) );
+ exampleLabel=new TQLabel(box2);
+ TQWhatsThis::add(exampleLabel, i18n( "This will display a preview of your choice so you can know what it does before clicking the OK button to validate it." ) );
grid3->addWidget(exampleLabel,0,1);
grid->addMultiCellWidget(box2,9,10,1,1);
- customFormatEdit = new QLineEdit( grp );
+ customFormatEdit = new TQLineEdit( grp );
grid->addMultiCellWidget( customFormatEdit, 1, 1, 1, 1 );
customFormatEdit->setHidden( true );
- listFormat=new QListBox(grp);
+ listFormat=new TQListBox(grp);
grid->addMultiCellWidget(listFormat,2,7,1,1);
- QWhatsThis::add(listFormat, i18n( "Displays choices of format for the fraction, date or time formats." ) );
- layout->addWidget(grp);
+ TQWhatsThis::add(listFormat, i18n( "Displays choices of format for the fraction, date or time formats." ) );
+ tqlayout->addWidget(grp);
/* *** */
- QGroupBox *box = new QGroupBox( this, "Box");
+ TQGroupBox *box = new TQGroupBox( this, "Box");
- grid = new QGridLayout(box,3,4,KDialog::marginHint(), KDialog::spacingHint());
+ grid = new TQGridLayout(box,3,4,KDialog::marginHint(), KDialog::spacingHint());
- postfix = new QLineEdit( box, "LineEdit_1" );
- QWhatsThis::add(postfix, i18n( "You can add here a Postfix such as a $HK symbol to the end of each cell content in the checked format." ) );
+ postfix = new TQLineEdit( box, "LineEdit_1" );
+ TQWhatsThis::add(postfix, i18n( "You can add here a Postfix such as a $HK symbol to the end of each cell content in the checked format." ) );
grid->addWidget(postfix,2,1);
precision = new KIntNumInput( dlg->precision, box, 10 );
precision->setSpecialValueText(i18n("variable"));
precision->setRange(-1,10,1,false);
- QWhatsThis::add(precision, i18n( "You can control how many digits are displayed after the decimal point for numeric values. This can also be changed using the Increase precision or Decrease precision icons in the Format toolbar. " ) );
+ TQWhatsThis::add(precision, i18n( "You can control how many digits are displayed after the decimal point for numeric values. This can also be changed using the Increase precision or Decrease precision icons in the Format toolbar. " ) );
grid->addWidget(precision,1,1);
- prefix = new QLineEdit( box, "LineEdit_3" );
- QWhatsThis::add(prefix, i18n( "You can add here a Prefix such as a $ symbol at the start of each cell content in the checked format." ) );
+ prefix = new TQLineEdit( box, "LineEdit_3" );
+ TQWhatsThis::add(prefix, i18n( "You can add here a Prefix such as a $ symbol at the start of each cell content in the checked format." ) );
grid->addWidget(prefix,0,1);
- format = new QComboBox( box, "ListBox_1" );
- QWhatsThis::add(format, i18n( "You can choose whether positive values are displayed with a leading + sign and whether negative values are shown in red." ) );
+ format = new TQComboBox( box, "ListBox_1" );
+ TQWhatsThis::add(format, i18n( "You can choose whether positive values are displayed with a leading + sign and whether negative values are shown in red." ) );
grid->addWidget(format,0,3);
- QLabel* tmpQLabel;
- tmpQLabel = new QLabel( box, "Label_1" );
- grid->addWidget(tmpQLabel,2,0);
- tmpQLabel->setText( i18n("Postfix:") );
+ TQLabel* tmpTQLabel;
+ tmpTQLabel = new TQLabel( box, "Label_1" );
+ grid->addWidget(tmpTQLabel,2,0);
+ tmpTQLabel->setText( i18n("Postfix:") );
postfix->setText( dlg->postfix );
- tmpQLabel = new QLabel( box, "Label_2" );
- grid->addWidget(tmpQLabel,0,0);
+ tmpTQLabel = new TQLabel( box, "Label_2" );
+ grid->addWidget(tmpTQLabel,0,0);
- tmpQLabel->setText( i18n("Prefix:") );
- tmpQLabel = new QLabel( box, "Label_3" );
- grid->addWidget(tmpQLabel,1,0);
- tmpQLabel->setText( i18n("Precision:") );
+ tmpTQLabel->setText( i18n("Prefix:") );
+ tmpTQLabel = new TQLabel( box, "Label_3" );
+ grid->addWidget(tmpTQLabel,1,0);
+ tmpTQLabel->setText( i18n("Precision:") );
prefix->setText( dlg->prefix );
@@ -1197,22 +1197,22 @@ CellFormatPageFloat::CellFormatPageFloat( QWidget* parent, CellFormatDialog *_dl
format->insertItem( *_dlg->formatAlwaysSignedPixmap, 3 );
format->insertItem( *_dlg->formatRedAlwaysSignedPixmap, 4 );
- tmpQLabel = new QLabel( box, "Label_4" );
- grid->addWidget(tmpQLabel, 0, 2);
- tmpQLabel->setText( i18n("Format:") );
+ tmpTQLabel = new TQLabel( box, "Label_4" );
+ grid->addWidget(tmpTQLabel, 0, 2);
+ tmpTQLabel->setText( i18n("Format:") );
- currencyLabel = new QLabel( box, "LabelCurrency" );
+ currencyLabel = new TQLabel( box, "LabelCurrency" );
grid->addWidget(currencyLabel, 1, 2);
currencyLabel->setText( i18n("Currency:") );
- currency = new QComboBox( box, "ComboCurrency" );
+ currency = new TQComboBox( box, "ComboCurrency" );
grid->addWidget(currency, 1, 3);
currency->insertItem( i18n("Automatic") );
int index = 2; //ignore first two in the list
bool ok = true;
- QString text;
+ TQString text;
while ( ok )
{
@@ -1245,7 +1245,7 @@ CellFormatPageFloat::CellFormatPageFloat( QWidget* parent, CellFormatDialog *_dl
format->setCurrentItem( 3 );
else if ( dlg->floatFormat == Format::AlwaysSigned && dlg->floatColor == Format::NegRed )
format->setCurrentItem( 4 );
- layout->addWidget(box);
+ tqlayout->addWidget(box);
cellFormatType=dlg->formatType;
newFormatType = cellFormatType;
@@ -1265,7 +1265,7 @@ CellFormatPageFloat::CellFormatPageFloat( QWidget* parent, CellFormatDialog *_dl
currency->show();
if (dlg->bCurrency)
{
- QString tmp;
+ TQString tmp;
if (dlg->cCurrency.type != 1)
{
Currency curr(dlg->cCurrency.type);
@@ -1293,24 +1293,24 @@ CellFormatPageFloat::CellFormatPageFloat( QWidget* parent, CellFormatDialog *_dl
customFormat->setChecked(true);
}
- connect(generic,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(fraction,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(money,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(date,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(scientific,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(number,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(percent,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(time,SIGNAL(clicked ()),this,SLOT(slotChangeState()));
- connect(textFormat,SIGNAL(clicked()),this,SLOT(slotChangeState()));
- connect(customFormat,SIGNAL(clicked()),this,SLOT(slotChangeState()));
-
- connect(listFormat,SIGNAL(selectionChanged ()),this,SLOT(makeformat()));
- connect(precision,SIGNAL(valueChanged(int)),this,SLOT(slotChangeValue(int)));
- connect(prefix,SIGNAL(textChanged ( const QString & ) ),this,SLOT(makeformat()));
- connect(postfix,SIGNAL(textChanged ( const QString & ) ),this,SLOT(makeformat()));
- connect(currency,SIGNAL(activated ( const QString & ) ),this, SLOT(currencyChanged(const QString &)));
- connect(format,SIGNAL(activated ( int ) ),this,SLOT(formatChanged(int)));
- connect(format, SIGNAL(activated(int)), this, SLOT(makeformat()));
+ connect(generic,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(fraction,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(money,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(date,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(scientific,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(number,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(percent,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(time,TQT_SIGNAL(clicked ()),this,TQT_SLOT(slotChangeState()));
+ connect(textFormat,TQT_SIGNAL(clicked()),this,TQT_SLOT(slotChangeState()));
+ connect(customFormat,TQT_SIGNAL(clicked()),this,TQT_SLOT(slotChangeState()));
+
+ connect(listFormat,TQT_SIGNAL(selectionChanged ()),this,TQT_SLOT(makeformat()));
+ connect(precision,TQT_SIGNAL(valueChanged(int)),this,TQT_SLOT(slotChangeValue(int)));
+ connect(prefix,TQT_SIGNAL(textChanged ( const TQString & ) ),this,TQT_SLOT(makeformat()));
+ connect(postfix,TQT_SIGNAL(textChanged ( const TQString & ) ),this,TQT_SLOT(makeformat()));
+ connect(currency,TQT_SIGNAL(activated ( const TQString & ) ),this, TQT_SLOT(currencyChanged(const TQString &)));
+ connect(format,TQT_SIGNAL(activated ( int ) ),this,TQT_SLOT(formatChanged(int)));
+ connect(format, TQT_SIGNAL(activated(int)), this, TQT_SLOT(makeformat()));
slotChangeState();
m_bFormatColorChanged=false;
m_bFormatTypeChanged=false;
@@ -1328,7 +1328,7 @@ void CellFormatPageFloat::slotChangeValue(int)
}
void CellFormatPageFloat::slotChangeState()
{
- QStringList list;
+ TQStringList list;
listFormat->clear();
currency->hide();
currencyLabel->hide();
@@ -1402,9 +1402,9 @@ void CellFormatPageFloat::slotChangeState()
listFormat->setEnabled(true);
- list+=i18n("System: ")+dlg->locale()->formatTime(QTime::currentTime(),false);
- list+=i18n("System: ")+dlg->locale()->formatTime(QTime::currentTime(),true);
- QDateTime tmpTime (QDate (1, 1, 1900), QTime (10, 35, 25));
+ list+=i18n("System: ")+dlg->locale()->formatTime(TQTime::currentTime(),false);
+ list+=i18n("System: ")+dlg->locale()->formatTime(TQTime::currentTime(),true);
+ TQDateTime tmpTime (TQDate (1, 1, 1900), TQTime (10, 35, 25));
ValueFormatter *fmt = dlg->getDoc()->formatter();
@@ -1461,12 +1461,12 @@ void CellFormatPageFloat::slotChangeState()
void CellFormatPageFloat::init()
{
- QStringList list;
- QString tmp;
- QString tmp2;
- QDate tmpDate( 2000,2,18);
- list+=i18n("System: ")+dlg->locale()->formatDate (QDate::currentDate(), true);
- list+=i18n("System: ")+dlg->locale()->formatDate (QDate::currentDate(), false);
+ TQStringList list;
+ TQString tmp;
+ TQString tmp2;
+ TQDate tmpDate( 2000,2,18);
+ list+=i18n("System: ")+dlg->locale()->formatDate (TQDate::tqcurrentDate(), true);
+ list+=i18n("System: ")+dlg->locale()->formatDate (TQDate::tqcurrentDate(), false);
ValueFormatter *fmt = dlg->getDoc()->formatter();
@@ -1576,7 +1576,7 @@ void CellFormatPageFloat::init()
}
-void CellFormatPageFloat::currencyChanged(const QString &)
+void CellFormatPageFloat::currencyChanged(const TQString &)
{
int index = currency->currentItem();
if (index > 0)
@@ -1676,10 +1676,10 @@ void CellFormatPageFloat::updateFormatType ()
void CellFormatPageFloat::makeformat()
{
m_bFormatTypeChanged=true;
- QString tmp;
+ TQString tmp;
updateFormatType();
- QColor color;
+ TQColor color;
Format::FloatFormat floatFormat = Format::OnlyNegSigned;
switch( format->currentItem() )
{
@@ -1689,11 +1689,11 @@ void CellFormatPageFloat::makeformat()
break;
case 1:
floatFormat = Format::OnlyNegSigned;
- color = Qt::red;
+ color = TQt::red;
break;
case 2:
floatFormat = Format::AlwaysUnsigned;
- color = Qt::red;
+ color = TQt::red;
break;
case 3:
floatFormat = Format::AlwaysSigned;
@@ -1701,7 +1701,7 @@ void CellFormatPageFloat::makeformat()
break;
case 4:
floatFormat = Format::AlwaysSigned;
- color = Qt::red;
+ color = TQt::red;
break;
}
if (!dlg->value.isNumber() || dlg->value.asFloat() >= 0 || !format->isEnabled())
@@ -1711,9 +1711,9 @@ void CellFormatPageFloat::makeformat()
ValueFormatter *fmt = dlg->getDoc()->formatter();
tmp = fmt->formatText(dlg->value, newFormatType, precision->value(),
floatFormat,
- prefix->isEnabled() ? prefix->text() : QString::null,
- postfix->isEnabled() ? postfix->text() : QString::null,
- newFormatType == Money_format ? dlg->cCurrency.symbol : QString::null);
+ prefix->isEnabled() ? prefix->text() : TQString(),
+ postfix->isEnabled() ? postfix->text() : TQString(),
+ newFormatType == Money_format ? dlg->cCurrency.symbol : TQString());
if (tmp.length() > 50)
tmp = tmp.left (50);
exampleLabel->setText(tmp.prepend("<font color=" + color.name() + ">").append("</font>"));
@@ -1881,8 +1881,8 @@ void CellFormatPageFloat::apply(FormatManipulator* _obj)
*
***************************************************************************/
-CellFormatPageProtection::CellFormatPageProtection( QWidget* parent, CellFormatDialog * _dlg )
- : ProtectionTab( parent ),
+CellFormatPageProtection::CellFormatPageProtection( TQWidget* tqparent, CellFormatDialog * _dlg )
+ : ProtectionTab( tqparent ),
m_dlg( _dlg )
{
m_bDontPrint->setChecked( m_dlg->bDontPrintText );
@@ -1953,19 +1953,19 @@ void CellFormatPageProtection::apply(FormatManipulator* _obj)
*
***************************************************************************/
-CellFormatPageFont::CellFormatPageFont( QWidget* parent, CellFormatDialog *_dlg ) : FontTab( parent )
+CellFormatPageFont::CellFormatPageFont( TQWidget* tqparent, CellFormatDialog *_dlg ) : FontTab( tqparent )
{
dlg = _dlg;
bTextColorUndefined = !dlg->bTextColor;
- connect( textColorButton, SIGNAL( changed( const QColor & ) ),
- this, SLOT( slotSetTextColor( const QColor & ) ) );
+ connect( textColorButton, TQT_SIGNAL( changed( const TQColor & ) ),
+ this, TQT_SLOT( slotSetTextColor( const TQColor & ) ) );
- QStringList tmpListFont;
- QFontDatabase *fontDataBase = new QFontDatabase();
- tmpListFont = fontDataBase->families();
+ TQStringList tmpListFont;
+ TQFontDatabase *fontDataBase = new TQFontDatabase();
+ tmpListFont = fontDataBase->tqfamilies();
delete fontDataBase;
family_combo->insertStringList( tmpListFont);
@@ -1976,13 +1976,13 @@ CellFormatPageFont::CellFormatPageFont( QWidget* parent, CellFormatDialog *_dlg
selFont.setFamily( dlg->textFontFamily );
kdDebug(36001) << "Family = " << dlg->textFontFamily << endl;
- if ( !family_combo->findItem(dlg->textFontFamily))
+ if ( !family_combo->tqfindItem(dlg->textFontFamily))
{
family_combo->insertItem("",0);
family_combo->setCurrentItem(0);
}
else
- family_combo->setCurrentItem(family_combo->index(family_combo->findItem(dlg->textFontFamily)));
+ family_combo->setCurrentItem(family_combo->index(family_combo->tqfindItem(dlg->textFontFamily)));
}
else
{
@@ -1990,42 +1990,42 @@ CellFormatPageFont::CellFormatPageFont( QWidget* parent, CellFormatDialog *_dlg
family_combo->setCurrentItem(0);
}
- connect( family_combo, SIGNAL(highlighted(const QString &)),
- SLOT(family_chosen_slot(const QString &)) );
+ connect( family_combo, TQT_SIGNAL(highlighted(const TQString &)),
+ TQT_SLOT(family_chosen_slot(const TQString &)) );
- QStringList lst;
+ TQStringList lst;
lst.append("");
for ( unsigned int i = 1; i < 100; ++i )
- lst.append( QString( "%1" ).arg( i ) );
+ lst.append( TQString( "%1" ).tqarg( i ) );
size_combo->insertStringList( lst );
- size_combo->setInsertionPolicy(QComboBox::NoInsertion);
+ size_combo->setInsertionPolicy(TQComboBox::NoInsertion);
- connect( size_combo, SIGNAL(activated(const QString &)),
- SLOT(size_chosen_slot(const QString &)) );
- connect( size_combo ,SIGNAL( textChanged(const QString &)),
- this,SLOT(size_chosen_slot(const QString &)));
+ connect( size_combo, TQT_SIGNAL(activated(const TQString &)),
+ TQT_SLOT(size_chosen_slot(const TQString &)) );
+ connect( size_combo ,TQT_SIGNAL( textChanged(const TQString &)),
+ this,TQT_SLOT(size_chosen_slot(const TQString &)));
- connect( weight_combo, SIGNAL(activated(const QString &)),
- SLOT(weight_chosen_slot(const QString &)) );
+ connect( weight_combo, TQT_SIGNAL(activated(const TQString &)),
+ TQT_SLOT(weight_chosen_slot(const TQString &)) );
- connect( style_combo, SIGNAL(activated(const QString &)),
- SLOT(style_chosen_slot(const QString &)) );
+ connect( style_combo, TQT_SIGNAL(activated(const TQString &)),
+ TQT_SLOT(style_chosen_slot(const TQString &)) );
strike->setChecked(dlg->strike);
- connect( strike, SIGNAL( clicked()),
- SLOT(strike_chosen_slot()) );
+ connect( strike, TQT_SIGNAL( clicked()),
+ TQT_SLOT(strike_chosen_slot()) );
underline->setChecked(dlg->underline);
- connect( underline, SIGNAL( clicked()),
- SLOT(underline_chosen_slot()) );
+ connect( underline, TQT_SIGNAL( clicked()),
+ TQT_SLOT(underline_chosen_slot()) );
example_label->setText(i18n("Dolor Ipse"));
- connect(this,SIGNAL(fontSelected( const QFont& )),
- this,SLOT(display_example( const QFont&)));
+ connect(this,TQT_SIGNAL(fontSelected( const TQFont& )),
+ this,TQT_SLOT(display_example( const TQFont&)));
setCombos();
display_example( selFont );
@@ -2033,7 +2033,7 @@ CellFormatPageFont::CellFormatPageFont( QWidget* parent, CellFormatDialog *_dlg
this->resize( 400, 400 );
}
-void CellFormatPageFont::slotSetTextColor( const QColor &_color )
+void CellFormatPageFont::slotSetTextColor( const TQColor &_color )
{
textColor = _color;
bTextColorUndefined = false;
@@ -2109,23 +2109,23 @@ void CellFormatPageFont::strike_chosen_slot()
emit fontSelected(selFont);
}
-void CellFormatPageFont::family_chosen_slot(const QString & family)
+void CellFormatPageFont::family_chosen_slot(const TQString & family)
{
selFont.setFamily(family);
emit fontSelected(selFont);
}
-void CellFormatPageFont::size_chosen_slot(const QString & size)
+void CellFormatPageFont::size_chosen_slot(const TQString & size)
{
- QString size_string = size;
+ TQString size_string = size;
selFont.setPointSize(size_string.toInt());
emit fontSelected(selFont);
}
-void CellFormatPageFont::weight_chosen_slot(const QString & weight)
+void CellFormatPageFont::weight_chosen_slot(const TQString & weight)
{
- QString weight_string = weight;
+ TQString weight_string = weight;
if ( weight_string == i18n("Normal"))
selFont.setBold(false);
@@ -2134,9 +2134,9 @@ void CellFormatPageFont::weight_chosen_slot(const QString & weight)
emit fontSelected(selFont);
}
-void CellFormatPageFont::style_chosen_slot(const QString & style)
+void CellFormatPageFont::style_chosen_slot(const TQString & style)
{
- QString style_string = style;
+ TQString style_string = style;
if ( style_string == i18n("Roman"))
selFont.setItalic(false);
@@ -2146,28 +2146,28 @@ void CellFormatPageFont::style_chosen_slot(const QString & style)
}
-void CellFormatPageFont::display_example(const QFont& font)
+void CellFormatPageFont::display_example(const TQFont& font)
{
- QString string;
+ TQString string;
fontChanged=true;
example_label->setFont(font);
- example_label->repaint();
+ example_label->tqrepaint();
}
void CellFormatPageFont::setCombos()
{
- QString string;
- QComboBox* combo;
+ TQString string;
+ TQComboBox* combo;
int number_of_entries;
bool found;
if ( dlg->bTextColor )
textColor = dlg->textColor;
else
- textColor = colorGroup().text();
+ textColor = tqcolorGroup().text();
if ( !textColor.isValid() )
- textColor =colorGroup().text();
+ textColor =tqcolorGroup().text();
textColorButton->setColor( textColor );
@@ -2182,7 +2182,7 @@ void CellFormatPageFont::setCombos()
found = false;
for (int i = 0; i < number_of_entries ; i++){
- if ( string == (QString) combo->text(i)){
+ if ( string == (TQString) combo->text(i)){
combo->setCurrentItem(i);
found = true;
// kdDebug(36001) << "Found Size " << string.data() << " setting to item " i << endl;
@@ -2228,8 +2228,8 @@ void CellFormatPageFont::setCombos()
*
***************************************************************************/
-CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialog *_dlg )
- : PositionTab(parent ),
+CellFormatPagePosition::CellFormatPagePosition( TQWidget* tqparent, CellFormatDialog *_dlg )
+ : PositionTab(tqparent ),
dlg( _dlg )
{
if ( dlg->alignX == Format::Left )
@@ -2241,7 +2241,7 @@ CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialo
else if ( dlg->alignX == Format::Undefined )
standard->setChecked( true );
- connect(horizontalGroup, SIGNAL(clicked(int)), this, SLOT(slotStateChanged(int)));
+ connect(horizontalGroup, TQT_SIGNAL(clicked(int)), this, TQT_SLOT(slotStateChanged(int)));
if ( dlg->alignY ==Format::Top )
top->setChecked( true );
@@ -2265,13 +2265,13 @@ CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialo
mergeCell->setChecked(dlg->isMerged);
mergeCell->setEnabled(!dlg->oneCell && ((!dlg->isRowSelected) && (!dlg->isColumnSelected)));
- QGridLayout *grid2 = new QGridLayout(indentGroup, 1, 1, KDialog::marginHint(), KDialog::spacingHint());
+ TQGridLayout *grid2 = new TQGridLayout(indentGroup, 1, 1, KDialog::marginHint(), KDialog::spacingHint());
grid2->addRowSpacing( 0, indentGroup->fontMetrics().height()/8 ); // groupbox title
m_indent = new KoUnitDoubleSpinBox( indentGroup, 0.0, 400.0, 10.0,dlg->indent,dlg->getDoc()->unit() );
grid2->addWidget(m_indent, 0, 0);
width = new KoUnitDoubleSpinBox( m_widthPanel );
- QGridLayout *gridWidth = new QGridLayout(m_widthPanel, 1, 1, 0, 0);
+ TQGridLayout *gridWidth = new TQGridLayout(m_widthPanel, 1, 1, 0, 0);
gridWidth->addWidget(width, 0, 0);
width->setValue ( dlg->widthSize );
width->setUnit( dlg->getDoc()->unit() );
@@ -2281,12 +2281,12 @@ CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialo
if ( dlg->isRowSelected )
width->setEnabled(false);
- defaultWidth->setText(i18n("Default width (%1 %2)").arg(KoUnit::toUserValue(dlg->defaultWidthSize, dlg->getDoc()->unit()), 0, 'f', 2).arg(dlg->getDoc()->unitName()));
+ defaultWidth->setText(i18n("Default width (%1 %2)").tqarg(KoUnit::toUserValue(dlg->defaultWidthSize, dlg->getDoc()->unit()), 0, 'f', 2).tqarg(dlg->getDoc()->unitName()));
if ( dlg->isRowSelected )
defaultWidth->setEnabled(false);
height=new KoUnitDoubleSpinBox( m_heightPanel );
- QGridLayout *gridHeight = new QGridLayout(m_heightPanel, 1, 1, 0, 0);
+ TQGridLayout *gridHeight = new TQGridLayout(m_heightPanel, 1, 1, 0, 0);
gridHeight->addWidget(height, 0, 0);
height->setValue( dlg->heightSize );
height->setUnit( dlg->getDoc()->unit() );
@@ -2296,7 +2296,7 @@ CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialo
if ( dlg->isColumnSelected )
height->setEnabled(false);
- defaultHeight->setText(i18n("Default height (%1 %2)").arg(KoUnit::toUserValue(dlg->defaultHeightSize, dlg->getDoc()->unit()), 0, 'f', 2).arg(dlg->getDoc()->unitName())); //annma
+ defaultHeight->setText(i18n("Default height (%1 %2)").tqarg(KoUnit::toUserValue(dlg->defaultHeightSize, dlg->getDoc()->unit()), 0, 'f', 2).tqarg(dlg->getDoc()->unitName())); //annma
if ( dlg->isColumnSelected )
defaultHeight->setEnabled(false);
@@ -2307,11 +2307,11 @@ CellFormatPagePosition::CellFormatPagePosition( QWidget* parent, CellFormatDialo
defaultWidth->setEnabled(false);
}
- connect(defaultWidth , SIGNAL(clicked() ),this, SLOT(slotChangeWidthState()));
- connect(defaultHeight , SIGNAL(clicked() ),this, SLOT(slotChangeHeightState()));
- connect(vertical , SIGNAL(clicked() ),this, SLOT(slotChangeVerticalState()));
- connect(multi , SIGNAL(clicked() ), this, SLOT(slotChangeMultiState()));
- connect(angleRotation, SIGNAL(valueChanged(int)), this, SLOT(slotChangeAngle(int)));
+ connect(defaultWidth , TQT_SIGNAL(clicked() ),this, TQT_SLOT(slotChangeWidthState()));
+ connect(defaultHeight , TQT_SIGNAL(clicked() ),this, TQT_SLOT(slotChangeHeightState()));
+ connect(vertical , TQT_SIGNAL(clicked() ),this, TQT_SLOT(slotChangeVerticalState()));
+ connect(multi , TQT_SIGNAL(clicked() ), this, TQT_SLOT(slotChangeMultiState()));
+ connect(angleRotation, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotChangeAngle(int)));
slotStateChanged( 0 );
m_bOptionText = false;
@@ -2529,16 +2529,16 @@ double CellFormatPagePosition::getSizeWidth() const
*
***************************************************************************/
-BorderButton::BorderButton( QWidget *parent, const char *_name ) : QPushButton(parent,_name)
+BorderButton::BorderButton( TQWidget *tqparent, const char *_name ) : TQPushButton(tqparent,_name)
{
penStyle = Qt::NoPen;
penWidth = 1;
- penColor = colorGroup().text();
+ penColor = tqcolorGroup().text();
setToggleButton( true );
setOn( false);
setChanged(false);
}
-void BorderButton::mousePressEvent( QMouseEvent * )
+void BorderButton::mousePressEvent( TQMouseEvent * )
{
this->setOn(!isOn());
@@ -2547,9 +2547,9 @@ void BorderButton::mousePressEvent( QMouseEvent * )
void BorderButton::setUndefined()
{
- setPenStyle(SolidLine );
+ setPenStyle(Qt::SolidLine );
setPenWidth(1);
- setColor(colorGroup().midlight());
+ setColor(tqcolorGroup().midlight());
}
@@ -2558,7 +2558,7 @@ void BorderButton::unselect()
setOn(false);
setPenWidth(1);
setPenStyle(Qt::NoPen);
- setColor( colorGroup().text() );
+ setColor( tqcolorGroup().text() );
setChanged(true);
}
@@ -2570,8 +2570,8 @@ void BorderButton::unselect()
*
***************************************************************************/
-Border::Border( QWidget *parent, const char *_name,bool _oneCol, bool _oneRow )
- : QFrame( parent, _name )
+Border::Border( TQWidget *tqparent, const char *_name,bool _oneCol, bool _oneRow )
+ : TQFrame( tqparent, _name )
{
oneCol=_oneCol;
oneRow=_oneRow;
@@ -2580,13 +2580,13 @@ Border::Border( QWidget *parent, const char *_name,bool _oneCol, bool _oneRow )
#define OFFSETX 5
#define OFFSETY 5
-void Border::paintEvent( QPaintEvent *_ev )
+void Border::paintEvent( TQPaintEvent *_ev )
{
- QFrame::paintEvent( _ev );
- QPen pen;
- QPainter painter;
+ TQFrame::paintEvent( _ev );
+ TQPen pen;
+ TQPainter painter;
painter.begin( this );
- pen=QPen( colorGroup().midlight(),2,SolidLine);
+ pen=TQPen( tqcolorGroup().midlight(),2,SolidLine);
painter.setPen( pen );
painter.drawLine( OFFSETX-5, OFFSETY, OFFSETX , OFFSETY );
@@ -2617,7 +2617,7 @@ void Border::paintEvent( QPaintEvent *_ev )
emit redraw();
}
-void Border::mousePressEvent( QMouseEvent* _ev )
+void Border::mousePressEvent( TQMouseEvent* _ev )
{
emit choosearea(_ev);
}
@@ -2630,8 +2630,8 @@ void Border::mousePressEvent( QMouseEvent* _ev )
*
***************************************************************************/
-CellFormatPageBorder::CellFormatPageBorder( QWidget* parent, CellFormatDialog *_dlg )
- : QWidget( parent ),
+CellFormatPageBorder::CellFormatPageBorder( TQWidget* tqparent, CellFormatDialog *_dlg )
+ : TQWidget( tqparent ),
dlg( _dlg )
{
sheet = dlg->getSheet();
@@ -2646,15 +2646,15 @@ CellFormatPageBorder::CellFormatPageBorder( QWidget* parent, CellFormatDialog *_
style->setEnabled(false);
size->setEnabled(false);
- preview->setPattern( black , 1, SolidLine );
+ preview->setPattern( black , 1, Qt::SolidLine );
this->resize( 400, 400 );
}
void CellFormatPageBorder::InitializeGrids()
{
- QGridLayout *grid = new QGridLayout(this,5,2,KDialog::marginHint(), KDialog::spacingHint());
- QGridLayout *grid2 = NULL;
- QGroupBox* tmpQGroupBox = NULL;
+ TQGridLayout *grid = new TQGridLayout(this,5,2,KDialog::marginHint(), KDialog::spacingHint());
+ TQGridLayout *grid2 = NULL;
+ TQGroupBox* tmpTQGroupBox = NULL;
/***********************/
/* here is the data to initialize all the border buttons with */
@@ -2664,11 +2664,11 @@ void CellFormatPageBorder::InitializeGrids()
const char shortcutButtonNames[BorderShortcutType_END][20] =
{"remove", "all", "outline"};
- QString borderButtonIconNames[BorderType_END] =
+ TQString borderButtonIconNames[BorderType_END] =
{"border_top", "border_bottom", "border_left", "border_right",
"border_vertical", "border_horizontal", "border_fall", "border_up"};
- QString shortcutButtonIconNames[BorderShortcutType_END] =
+ TQString shortcutButtonIconNames[BorderShortcutType_END] =
{ "border_remove", "", "border_outline"};
int borderButtonPositions[BorderType_END][2] =
@@ -2678,40 +2678,40 @@ void CellFormatPageBorder::InitializeGrids()
{ {0,0}, {0,1},{0,2} };
/***********************/
- /* set up a layout box for most of the border setting buttons */
- tmpQGroupBox = new QGroupBox( this, "GroupBox_1" );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setTitle( i18n("Border") );
- tmpQGroupBox->setAlignment( AlignLeft );
- grid2 = new QGridLayout(tmpQGroupBox,6,5,KDialog::marginHint(), KDialog::spacingHint());
- int fHeight = tmpQGroupBox->fontMetrics().height();
+ /* set up a tqlayout box for most of the border setting buttons */
+ tmpTQGroupBox = new TQGroupBox( this, "GroupBox_1" );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->setTitle( i18n("Border") );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
+ grid2 = new TQGridLayout(tmpTQGroupBox,6,5,KDialog::marginHint(), KDialog::spacingHint());
+ int fHeight = tmpTQGroupBox->fontMetrics().height();
grid2->addRowSpacing( 0, fHeight/2 ); // groupbox title
- area=new Border(tmpQGroupBox,"area",dlg->oneCol,dlg->oneRow);
+ area=new Border(tmpTQGroupBox,"area",dlg->oneCol,dlg->oneRow);
grid2->addMultiCellWidget(area,2,4,1,3);
- area->setBackgroundColor( colorGroup().base() );
+ area->setBackgroundColor( tqcolorGroup().base() );
/* initailize the buttons that are in this box */
for (int i=BorderType_Top; i < BorderType_END; i++)
{
- borderButtons[i] = new BorderButton(tmpQGroupBox,
+ borderButtons[i] = new BorderButton(tmpTQGroupBox,
borderButtonNames[i]);
loadIcon(borderButtonIconNames[i], borderButtons[i]);
grid2->addWidget(borderButtons[i], borderButtonPositions[i][0] + 1,
borderButtonPositions[i][1]);
}
- grid->addMultiCellWidget(tmpQGroupBox,0,2,0,0);
+ grid->addMultiCellWidget(tmpTQGroupBox,0,2,0,0);
/* the remove, all, and outline border buttons are in a second box down
below.*/
- tmpQGroupBox = new QGroupBox( this, "GroupBox_3" );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setTitle( i18n("Preselect") );
- tmpQGroupBox->setAlignment( AlignLeft );
+ tmpTQGroupBox = new TQGroupBox( this, "GroupBox_3" );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->setTitle( i18n("Preselect") );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
- grid2 = new QGridLayout(tmpQGroupBox,1,3,KDialog::marginHint(), KDialog::spacingHint());
+ grid2 = new TQGridLayout(tmpTQGroupBox,1,3,KDialog::marginHint(), KDialog::spacingHint());
/* the "all" button is different depending on what kind of region is currently
selected */
@@ -2730,7 +2730,7 @@ void CellFormatPageBorder::InitializeGrids()
for (int i=BorderShortcutType_Remove; i < BorderShortcutType_END; i++)
{
- shortcutButtons[i] = new BorderButton(tmpQGroupBox,
+ shortcutButtons[i] = new BorderButton(tmpTQGroupBox,
shortcutButtonNames[i]);
loadIcon(shortcutButtonIconNames[i], shortcutButtons[i]);
grid2->addWidget(shortcutButtons[i], shortcutButtonPositions[i][0],
@@ -2742,16 +2742,16 @@ void CellFormatPageBorder::InitializeGrids()
shortcutButtons[BorderShortcutType_All]->setEnabled(false);
}
- grid->addMultiCellWidget(tmpQGroupBox,3,4,0,0);
+ grid->addMultiCellWidget(tmpTQGroupBox,3,4,0,0);
/* now set up the group box with the pattern selector */
- tmpQGroupBox = new QGroupBox( this, "GroupBox_10" );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setTitle( i18n("Pattern") );
- tmpQGroupBox->setAlignment( AlignLeft );
+ tmpTQGroupBox = new TQGroupBox( this, "GroupBox_10" );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->setTitle( i18n("Pattern") );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
- grid2 = new QGridLayout(tmpQGroupBox,7,2,KDialog::marginHint(), KDialog::spacingHint());
- fHeight = tmpQGroupBox->fontMetrics().height();
+ grid2 = new TQGridLayout(tmpTQGroupBox,7,2,KDialog::marginHint(), KDialog::spacingHint());
+ fHeight = tmpTQGroupBox->fontMetrics().height();
grid2->addRowSpacing( 0, fHeight/2 ); // groupbox title
char name[] = "PatternXX";
@@ -2761,8 +2761,8 @@ void CellFormatPageBorder::InitializeGrids()
{
name[7] = '0' + (i+1) / 10;
name[8] = '0' + (i+1) % 10;
- pattern[i] = new PatternSelect( tmpQGroupBox, name );
- pattern[i]->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ pattern[i] = new PatternSelect( tmpTQGroupBox, name );
+ pattern[i]->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(pattern[i], i % 5 + 1, i / 5);
/* this puts them in the pattern:
1 6
@@ -2773,23 +2773,23 @@ void CellFormatPageBorder::InitializeGrids()
*/
}
- color = new KColorButton (tmpQGroupBox, "PushButton_1" );
+ color = new KColorButton (tmpTQGroupBox, "PushButton_1" );
grid2->addWidget(color,7,1);
- QLabel *tmpQLabel = new QLabel( tmpQGroupBox, "Label_6" );
- tmpQLabel->setText( i18n("Color:") );
- grid2->addWidget(tmpQLabel,7,0);
+ TQLabel *tmpTQLabel = new TQLabel( tmpTQGroupBox, "Label_6" );
+ tmpTQLabel->setText( i18n("Color:") );
+ grid2->addWidget(tmpTQLabel,7,0);
/* tack on the 'customize' border pattern selector */
- QGridLayout *grid3 = new QGridLayout( this, 2, 2, KDialog::marginHint(), KDialog::spacingHint() );
- customize = new QCheckBox(i18n("Customize"),tmpQGroupBox);
+ TQGridLayout *grid3 = new TQGridLayout( this, 2, 2, KDialog::marginHint(), KDialog::spacingHint() );
+ customize = new TQCheckBox(i18n("Customize"),tmpTQGroupBox);
grid3->addWidget(customize,0,0);
- connect( customize, SIGNAL( clicked()), SLOT(cutomize_chosen_slot()) );
+ connect( customize, TQT_SIGNAL( clicked()), TQT_SLOT(cutomize_chosen_slot()) );
- size=new QComboBox(true,tmpQGroupBox);
+ size=new TQComboBox(true,tmpTQGroupBox);
grid3->addWidget(size,1,1);
size->setValidator(new KIntValidator( size ));
- QString tmp;
+ TQString tmp;
for ( int i=0;i<10;i++)
{
tmp=tmp.setNum(i);
@@ -2797,40 +2797,40 @@ void CellFormatPageBorder::InitializeGrids()
}
size->setCurrentItem(1);
- style=new QComboBox(tmpQGroupBox);
+ style=new TQComboBox(tmpTQGroupBox);
grid3->addWidget(style,1,0);
style->insertItem(paintFormatPixmap(DotLine),0 );
style->insertItem(paintFormatPixmap(DashLine) ,1);
style->insertItem(paintFormatPixmap(DashDotLine),2 );
style->insertItem(paintFormatPixmap(DashDotDotLine),3 );
style->insertItem(paintFormatPixmap(SolidLine),4);
- style->setBackgroundColor( colorGroup().background() );
+ style->setBackgroundColor( tqcolorGroup().background() );
grid2->addMultiCell(grid3,6,6,0,1);
- grid->addMultiCellWidget(tmpQGroupBox,0,3,1,1);
+ grid->addMultiCellWidget(tmpTQGroupBox,0,3,1,1);
/* Now the preview box is put together */
- tmpQGroupBox = new QGroupBox(this, "GroupBox_4" );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setTitle( i18n("Preview") );
- tmpQGroupBox->setAlignment( AlignLeft );
+ tmpTQGroupBox = new TQGroupBox(this, "GroupBox_4" );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->setTitle( i18n("Preview") );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
- grid2 = new QGridLayout(tmpQGroupBox,1,1,KDialog::marginHint(), KDialog::spacingHint());
- fHeight = tmpQGroupBox->fontMetrics().height();
+ grid2 = new TQGridLayout(tmpTQGroupBox,1,1,KDialog::marginHint(), KDialog::spacingHint());
+ fHeight = tmpTQGroupBox->fontMetrics().height();
grid2->addRowSpacing( 0, fHeight/2 ); // groupbox title
- preview = new PatternSelect( tmpQGroupBox, "Pattern_preview" );
- preview->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ preview = new PatternSelect( tmpTQGroupBox, "Pattern_preview" );
+ preview->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(preview,1,0);
- grid->addWidget(tmpQGroupBox,4,1);
+ grid->addWidget(tmpTQGroupBox,4,1);
}
void CellFormatPageBorder::InitializeBorderButtons()
{
for (int i=BorderType_Top; i < BorderType_END; i++)
{
- if (dlg->borders[i].style != Qt::NoPen ||
+ if (dlg->borders[i].style != TQt::NoPen ||
!dlg->borders[i].bStyle )
{
/* the horozontil and vertical buttons might be disabled depending on what
@@ -2859,51 +2859,51 @@ void CellFormatPageBorder::InitializeBorderButtons()
void CellFormatPageBorder::InitializePatterns()
{
- pattern[0]->setPattern( black, 1, DotLine );
- pattern[1]->setPattern( black, 1, DashLine );
- pattern[2]->setPattern( black, 1, SolidLine );
- pattern[3]->setPattern( black, 1, DashDotLine );
- pattern[4]->setPattern( black, 1, DashDotDotLine );
- pattern[5]->setPattern( black, 2, SolidLine );
- pattern[6]->setPattern( black, 3, SolidLine );
- pattern[7]->setPattern( black, 4, SolidLine );
- pattern[8]->setPattern( black, 5, SolidLine );
- pattern[9]->setPattern( black, 1, NoPen );
+ pattern[0]->setPattern( black, 1, Qt::DotLine );
+ pattern[1]->setPattern( black, 1, Qt::DashLine );
+ pattern[2]->setPattern( black, 1, Qt::SolidLine );
+ pattern[3]->setPattern( black, 1, Qt::DashDotLine );
+ pattern[4]->setPattern( black, 1, Qt::DashDotDotLine );
+ pattern[5]->setPattern( black, 2, Qt::SolidLine );
+ pattern[6]->setPattern( black, 3, Qt::SolidLine );
+ pattern[7]->setPattern( black, 4, Qt::SolidLine );
+ pattern[8]->setPattern( black, 5, Qt::SolidLine );
+ pattern[9]->setPattern( black, 1, Qt::NoPen );
slotSetColorButton( black );
}
void CellFormatPageBorder::SetConnections()
{
- connect( color, SIGNAL( changed( const QColor & ) ),
- this, SLOT( slotSetColorButton( const QColor & ) ) );
+ connect( color, TQT_SIGNAL( changed( const TQColor & ) ),
+ this, TQT_SLOT( slotSetColorButton( const TQColor & ) ) );
for (int i=0; i < NUM_BORDER_PATTERNS; i++)
{
- connect( pattern[i], SIGNAL( clicked( PatternSelect* ) ),
- this, SLOT( slotUnselect2( PatternSelect* ) ) );
+ connect( pattern[i], TQT_SIGNAL( clicked( PatternSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( PatternSelect* ) ) );
}
for (int i = BorderType_Top; i < BorderType_END; i++)
{
- connect( borderButtons[i], SIGNAL( clicked (BorderButton *) ),
- this, SLOT( changeState( BorderButton *) ) );
+ connect( borderButtons[i], TQT_SIGNAL( clicked (BorderButton *) ),
+ this, TQT_SLOT( changeState( BorderButton *) ) );
}
for (int i = BorderShortcutType_Remove; i < BorderShortcutType_END; i++)
{
- connect( shortcutButtons[i], SIGNAL( clicked(BorderButton *) ),
- this, SLOT( preselect(BorderButton *) ) );
+ connect( shortcutButtons[i], TQT_SIGNAL( clicked(BorderButton *) ),
+ this, TQT_SLOT( preselect(BorderButton *) ) );
}
- connect( area ,SIGNAL( redraw()),this,SLOT(draw()));
- connect( area ,SIGNAL( choosearea(QMouseEvent * )),
- this,SLOT( slotPressEvent(QMouseEvent *)));
+ connect( area ,TQT_SIGNAL( redraw()),this,TQT_SLOT(draw()));
+ connect( area ,TQT_SIGNAL( choosearea(TQMouseEvent * )),
+ this,TQT_SLOT( slotPressEvent(TQMouseEvent *)));
- connect( style, SIGNAL( activated(int)), this, SLOT(slotChangeStyle(int)));
- connect( size, SIGNAL( textChanged(const QString &)),
- this, SLOT(slotChangeStyle(const QString &)));
- connect( size ,SIGNAL( activated(int)), this, SLOT(slotChangeStyle(int)));
+ connect( style, TQT_SIGNAL( activated(int)), this, TQT_SLOT(slotChangeStyle(int)));
+ connect( size, TQT_SIGNAL( textChanged(const TQString &)),
+ this, TQT_SLOT(slotChangeStyle(const TQString &)));
+ connect( size ,TQT_SIGNAL( activated(int)), this, TQT_SLOT(slotChangeStyle(int)));
}
void CellFormatPageBorder::cutomize_chosen_slot()
@@ -2919,11 +2919,11 @@ void CellFormatPageBorder::cutomize_chosen_slot()
style->setEnabled( false );
size->setEnabled( false );
pattern[2]->slotSelect();
- preview->setPattern( black , 1, SolidLine );
+ preview->setPattern( black , 1, Qt::SolidLine );
}
}
-void CellFormatPageBorder::slotChangeStyle(const QString &)
+void CellFormatPageBorder::slotChangeStyle(const TQString &)
{
/* if they try putting text in the size box, then erase the line */
slotChangeStyle(0);
@@ -2932,30 +2932,30 @@ void CellFormatPageBorder::slotChangeStyle(const QString &)
void CellFormatPageBorder::slotChangeStyle(int)
{
int index = style->currentItem();
- QString tmp;
+ TQString tmp;
int penSize = size->currentText().toInt();
if ( !penSize)
{
- preview->setPattern( preview->getColor(), penSize, NoPen );
+ preview->setPattern( preview->getColor(), penSize, Qt::NoPen );
}
else
{
switch(index)
{
case 0:
- preview->setPattern( preview->getColor(), penSize, DotLine );
+ preview->setPattern( preview->getColor(), penSize, Qt::DotLine );
break;
case 1:
- preview->setPattern( preview->getColor(), penSize, DashLine );
+ preview->setPattern( preview->getColor(), penSize, Qt::DashLine );
break;
case 2:
- preview->setPattern( preview->getColor(), penSize, DashDotLine );
+ preview->setPattern( preview->getColor(), penSize, Qt::DashDotLine );
break;
case 3:
- preview->setPattern( preview->getColor(), penSize, DashDotDotLine );
+ preview->setPattern( preview->getColor(), penSize, Qt::DashDotDotLine );
break;
case 4:
- preview->setPattern( preview->getColor(), penSize, SolidLine );
+ preview->setPattern( preview->getColor(), penSize, Qt::SolidLine );
break;
default:
kdDebug(36001)<<"Error in combobox\n";
@@ -2965,23 +2965,23 @@ void CellFormatPageBorder::slotChangeStyle(int)
slotUnselect2(preview);
}
-QPixmap CellFormatPageBorder::paintFormatPixmap(PenStyle _style)
+TQPixmap CellFormatPageBorder::paintFormatPixmap(PenStyle _style)
{
- QPixmap pixmap( style->width(), 14 );
- QPainter painter;
- QPen pen;
- pen=QPen( colorGroup().text(),1,_style);
+ TQPixmap pixmap( style->width(), 14 );
+ TQPainter painter;
+ TQPen pen;
+ pen=TQPen( tqcolorGroup().text(),1,_style);
painter.begin( &pixmap );
- painter.fillRect( 0, 0, style->width(), 14, colorGroup().background() );
+ painter.fillRect( 0, 0, style->width(), 14, tqcolorGroup().background() );
painter.setPen( pen );
painter.drawLine( 0, 7, style->width(), 7 );
painter.end();
return pixmap;
}
-void CellFormatPageBorder::loadIcon( QString _pix, BorderButton *_button)
+void CellFormatPageBorder::loadIcon( TQString _pix, BorderButton *_button)
{
- _button->setPixmap( QPixmap( BarIcon(_pix, Factory::global()) ) );
+ _button->setPixmap( TQPixmap( BarIcon(_pix, Factory::global()) ) );
}
void CellFormatPageBorder::apply(FormatManipulator* obj)
@@ -3013,7 +3013,7 @@ void CellFormatPageBorder::applyTopOutline(FormatManipulator* obj)
{
BorderButton * top = borderButtons[BorderType_Top];
- QPen tmpPen( top->getColor(), top->getPenWidth(), top->getPenStyle());
+ TQPen tmpPen( top->getColor(), top->getPenWidth(), top->getPenStyle());
if ( dlg->getStyle() )
{
@@ -3030,7 +3030,7 @@ void CellFormatPageBorder::applyBottomOutline(FormatManipulator* obj)
{
BorderButton * bottom = borderButtons[BorderType_Bottom];
- QPen tmpPen( bottom->getColor(), bottom->getPenWidth(), bottom->getPenStyle() );
+ TQPen tmpPen( bottom->getColor(), bottom->getPenWidth(), bottom->getPenStyle() );
if ( dlg->getStyle() )
{
@@ -3046,7 +3046,7 @@ void CellFormatPageBorder::applyBottomOutline(FormatManipulator* obj)
void CellFormatPageBorder::applyLeftOutline(FormatManipulator* obj)
{
BorderButton * left = borderButtons[BorderType_Left];
- QPen tmpPen( left->getColor(), left->getPenWidth(), left->getPenStyle() );
+ TQPen tmpPen( left->getColor(), left->getPenWidth(), left->getPenStyle() );
if ( dlg->getStyle() )
{
@@ -3062,7 +3062,7 @@ void CellFormatPageBorder::applyLeftOutline(FormatManipulator* obj)
void CellFormatPageBorder::applyRightOutline(FormatManipulator* obj)
{
BorderButton* right = borderButtons[BorderType_Right];
- QPen tmpPen( right->getColor(), right->getPenWidth(), right->getPenStyle() );
+ TQPen tmpPen( right->getColor(), right->getPenWidth(), right->getPenStyle() );
if ( dlg->getStyle() )
{
@@ -3079,9 +3079,9 @@ void CellFormatPageBorder::applyDiagonalOutline(FormatManipulator* obj)
{
BorderButton * fallDiagonal = borderButtons[BorderType_FallingDiagonal];
BorderButton * goUpDiagonal = borderButtons[BorderType_RisingDiagonal];
- QPen tmpPenFall( fallDiagonal->getColor(), fallDiagonal->getPenWidth(),
+ TQPen tmpPenFall( fallDiagonal->getColor(), fallDiagonal->getPenWidth(),
fallDiagonal->getPenStyle());
- QPen tmpPenGoUp( goUpDiagonal->getColor(), goUpDiagonal->getPenWidth(),
+ TQPen tmpPenGoUp( goUpDiagonal->getColor(), goUpDiagonal->getPenWidth(),
goUpDiagonal->getPenStyle());
if ( dlg->getStyle() )
@@ -3102,7 +3102,7 @@ void CellFormatPageBorder::applyDiagonalOutline(FormatManipulator* obj)
void CellFormatPageBorder::applyHorizontalOutline(FormatManipulator* obj)
{
- QPen tmpPen( borderButtons[BorderType_Horizontal]->getColor(),
+ TQPen tmpPen( borderButtons[BorderType_Horizontal]->getColor(),
borderButtons[BorderType_Horizontal]->getPenWidth(),
borderButtons[BorderType_Horizontal]->getPenStyle());
@@ -3120,7 +3120,7 @@ void CellFormatPageBorder::applyHorizontalOutline(FormatManipulator* obj)
void CellFormatPageBorder::applyVerticalOutline(FormatManipulator* obj)
{
BorderButton* vertical = borderButtons[BorderType_Vertical];
- QPen tmpPen( vertical->getColor(), vertical->getPenWidth(),
+ TQPen tmpPen( vertical->getColor(), vertical->getPenWidth(),
vertical->getPenStyle());
if ( dlg->getStyle() )
@@ -3135,7 +3135,7 @@ void CellFormatPageBorder::applyVerticalOutline(FormatManipulator* obj)
}
-void CellFormatPageBorder::slotSetColorButton( const QColor &_color )
+void CellFormatPageBorder::slotSetColorButton( const TQColor &_color )
{
currentColor = _color;
@@ -3223,7 +3223,7 @@ void CellFormatPageBorder::preselect( BorderButton *_p )
vertical->setChanged(true);
}
}
- area->repaint();
+ area->tqrepaint();
}
void CellFormatPageBorder::changeState( BorderButton *_p)
@@ -3240,10 +3240,10 @@ void CellFormatPageBorder::changeState( BorderButton *_p)
{
_p->setPenWidth(1);
_p->setPenStyle(Qt::NoPen);
- _p->setColor( colorGroup().text() );
+ _p->setColor( tqcolorGroup().text() );
}
- area->repaint();
+ area->tqrepaint();
}
void CellFormatPageBorder::draw()
@@ -3256,39 +3256,39 @@ void CellFormatPageBorder::draw()
BorderButton* fallingDiagonal = borderButtons[BorderType_FallingDiagonal];
BorderButton* vertical = borderButtons[BorderType_Vertical];
BorderButton* horizontal = borderButtons[BorderType_Horizontal];
- QPen pen;
- QPainter painter;
+ TQPen pen;
+ TQPainter painter;
painter.begin( area );
- if ((bottom->getPenStyle())!=Qt::NoPen)
+ if ((bottom->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( bottom->getColor(), bottom->getPenWidth(),bottom->getPenStyle());
+ pen=TQPen( bottom->getColor(), bottom->getPenWidth(),bottom->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX, area->height()-OFFSETY, area->width()-OFFSETX , area->height()-OFFSETY );
}
- if ((top->getPenStyle())!=Qt::NoPen)
+ if ((top->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( top->getColor(), top->getPenWidth(),top->getPenStyle());
+ pen=TQPen( top->getColor(), top->getPenWidth(),top->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX, OFFSETY, area->width() -OFFSETX, OFFSETY );
}
- if ((left->getPenStyle())!=Qt::NoPen)
+ if ((left->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( left->getColor(), left->getPenWidth(),left->getPenStyle());
+ pen=TQPen( left->getColor(), left->getPenWidth(),left->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX, OFFSETY, OFFSETX , area->height()-OFFSETY );
}
- if ((right->getPenStyle())!=Qt::NoPen)
+ if ((right->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( right->getColor(), right->getPenWidth(),right->getPenStyle());
+ pen=TQPen( right->getColor(), right->getPenWidth(),right->getPenStyle());
painter.setPen( pen );
painter.drawLine( area->width()-OFFSETX, OFFSETY, area->width()-OFFSETX,
area->height()-OFFSETY );
}
- if ((fallingDiagonal->getPenStyle())!=Qt::NoPen)
+ if ((fallingDiagonal->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( fallingDiagonal->getColor(), fallingDiagonal->getPenWidth(),
+ pen=TQPen( fallingDiagonal->getColor(), fallingDiagonal->getPenWidth(),
fallingDiagonal->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX, OFFSETY, area->width()-OFFSETX,
@@ -3301,9 +3301,9 @@ void CellFormatPageBorder::draw()
area->height()-OFFSETY );
}
}
- if ((risingDiagonal->getPenStyle())!=Qt::NoPen)
+ if ((risingDiagonal->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( risingDiagonal->getColor(), risingDiagonal->getPenWidth(),
+ pen=TQPen( risingDiagonal->getColor(), risingDiagonal->getPenWidth(),
risingDiagonal->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX, area->height()-OFFSETY , area->width()-OFFSETX ,
@@ -3316,16 +3316,16 @@ void CellFormatPageBorder::draw()
}
}
- if ((vertical->getPenStyle())!=Qt::NoPen)
+ if ((vertical->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( vertical->getColor(), vertical->getPenWidth(),
+ pen=TQPen( vertical->getColor(), vertical->getPenWidth(),
vertical->getPenStyle());
painter.setPen( pen );
painter.drawLine( area->width()/2, 5 , area->width()/2 , area->height()-5 );
}
- if ((horizontal->getPenStyle())!=Qt::NoPen)
+ if ((horizontal->getPenStyle())!=TQt::NoPen)
{
- pen=QPen( horizontal->getColor(), horizontal->getPenWidth(),
+ pen=TQPen( horizontal->getColor(), horizontal->getPenWidth(),
horizontal->getPenStyle());
painter.setPen( pen );
painter.drawLine( OFFSETX,area->height()/2,area->width()-OFFSETX,
@@ -3350,7 +3350,7 @@ void CellFormatPageBorder::invertState(BorderButton *_p)
}
}
-void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
+void CellFormatPageBorder::slotPressEvent(TQMouseEvent *_ev)
{
BorderButton* top = borderButtons[BorderType_Top];
BorderButton* bottom = borderButtons[BorderType_Bottom];
@@ -3360,8 +3360,8 @@ void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
BorderButton* horizontal = borderButtons[BorderType_Horizontal];
- QRect rect(OFFSETX,OFFSETY-8,area->width()-OFFSETX,OFFSETY+8);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ TQRect rect(OFFSETX,OFFSETY-8,area->width()-OFFSETX,OFFSETY+8);
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((top->getPenWidth()!=preview->getPenWidth()) ||
(top->getColor()!=currentColor) ||
@@ -3378,7 +3378,7 @@ void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
}
rect.setCoords(OFFSETX,area->height()-OFFSETY-8,area->width()-OFFSETX,
area->height()-OFFSETY+8);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((bottom->getPenWidth()!=preview->getPenWidth()) ||
(bottom->getColor()!=currentColor) ||
@@ -3395,7 +3395,7 @@ void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
}
rect.setCoords(OFFSETX-8,OFFSETY,OFFSETX+8,area->height()-OFFSETY);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((left->getPenWidth()!=preview->getPenWidth()) ||
(left->getColor()!=currentColor) ||
@@ -3412,7 +3412,7 @@ void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
}
rect.setCoords(area->width()-OFFSETX-8,OFFSETY,area->width()-OFFSETX+8,
area->height()-OFFSETY);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((right->getPenWidth()!=preview->getPenWidth()) ||
(right->getColor()!=currentColor) ||
@@ -3431,12 +3431,12 @@ void CellFormatPageBorder::slotPressEvent(QMouseEvent *_ev)
//don't work because I don't know how create a rectangle
//for diagonal
/*rect.setCoords(OFFSETX,OFFSETY,XLEN-OFFSETX,YHEI-OFFSETY);
-if (rect.contains(QPoint(_ev->x(),_ev->y())))
+if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
invertState(fallDiagonal);
}
rect.setCoords(OFFSETX,YHEI-OFFSETY,XLEN-OFFSETX,OFFSETY);
-if (rect.contains(QPoint(_ev->x(),_ev->y())))
+if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
invertState(goUpDiagonal);
} */
@@ -3446,7 +3446,7 @@ if (rect.contains(QPoint(_ev->x(),_ev->y())))
rect.setCoords(area->width()/2-8,OFFSETY,area->width()/2+8,
area->height()-OFFSETY);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((vertical->getPenWidth()!=preview->getPenWidth()) ||
(vertical->getColor()!=currentColor) ||
@@ -3466,7 +3466,7 @@ if (rect.contains(QPoint(_ev->x(),_ev->y())))
{
rect.setCoords(OFFSETX,area->height()/2-8,area->width()-OFFSETX,
area->height()/2+8);
- if (rect.contains(QPoint(_ev->x(),_ev->y())))
+ if (rect.tqcontains(TQPoint(_ev->x(),_ev->y())))
{
if (((horizontal->getPenWidth()!=preview->getPenWidth()) ||
(horizontal->getColor()!=currentColor) ||
@@ -3483,7 +3483,7 @@ if (rect.contains(QPoint(_ev->x(),_ev->y())))
}
}
- area->repaint();
+ area->tqrepaint();
}
@@ -3494,35 +3494,35 @@ if (rect.contains(QPoint(_ev->x(),_ev->y())))
*
***************************************************************************/
-BrushSelect::BrushSelect( QWidget *parent, const char * ) : QFrame( parent )
+BrushSelect::BrushSelect( TQWidget *tqparent, const char * ) : TQFrame( tqparent )
{
brushStyle = Qt::NoBrush;
- brushColor = Qt::red;
+ brushColor = TQt::red;
selected = false;
}
-void BrushSelect::setPattern( const QColor &_color,BrushStyle _style )
+void BrushSelect::setPattern( const TQColor &_color,Qt::BrushStyle _style )
{
brushStyle = _style;
brushColor = _color;
- repaint();
+ tqrepaint();
}
-void BrushSelect::paintEvent( QPaintEvent *_ev )
+void BrushSelect::paintEvent( TQPaintEvent *_ev )
{
- QFrame::paintEvent( _ev );
+ TQFrame::paintEvent( _ev );
- QPainter painter;
- QBrush brush(brushColor,brushStyle);
+ TQPainter painter;
+ TQBrush brush(brushColor,brushStyle);
painter.begin( this );
- painter.setPen( Qt::NoPen );
+ painter.setPen( TQt::NoPen );
painter.setBrush( brush);
painter.drawRect( 2, 2, width()-4, height()-4);
painter.end();
}
-void BrushSelect::mousePressEvent( QMouseEvent * )
+void BrushSelect::mousePressEvent( TQMouseEvent * )
{
slotSelect();
@@ -3534,8 +3534,8 @@ void BrushSelect::slotUnselect()
selected = false;
setLineWidth( 1 );
- setFrameStyle( QFrame::Panel | QFrame::Sunken );
- repaint();
+ setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
+ tqrepaint();
}
void BrushSelect::slotSelect()
@@ -3543,8 +3543,8 @@ void BrushSelect::slotSelect()
selected = true;
setLineWidth( 2 );
- setFrameStyle( QFrame::Panel | QFrame::Plain );
- repaint();
+ setFrameStyle( TQFrame::Panel | TQFrame::Plain );
+ tqrepaint();
}
@@ -3555,186 +3555,186 @@ void BrushSelect::slotSelect()
*
***************************************************************************/
-CellFormatPagePattern::CellFormatPagePattern( QWidget* parent, CellFormatDialog *_dlg ) : QWidget( parent )
+CellFormatPagePattern::CellFormatPagePattern( TQWidget* tqparent, CellFormatDialog *_dlg ) : TQWidget( tqparent )
{
dlg = _dlg;
bBgColorUndefined = !dlg->bBgColor;
- QGridLayout *grid = new QGridLayout(this,5,2,KDialog::marginHint(), KDialog::spacingHint());
+ TQGridLayout *grid = new TQGridLayout(this,5,2,KDialog::marginHint(), KDialog::spacingHint());
- QGroupBox* tmpQGroupBox;
- tmpQGroupBox = new QGroupBox( this, "GroupBox_20" );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setTitle( i18n("Pattern") );
- tmpQGroupBox->setAlignment( AlignLeft );
+ TQGroupBox* tmpTQGroupBox;
+ tmpTQGroupBox = new TQGroupBox( this, "GroupBox_20" );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->setTitle( i18n("Pattern") );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
- QGridLayout *grid2 = new QGridLayout(tmpQGroupBox,8,3,KDialog::marginHint(), KDialog::spacingHint());
- int fHeight = tmpQGroupBox->fontMetrics().height();
+ TQGridLayout *grid2 = new TQGridLayout(tmpTQGroupBox,8,3,KDialog::marginHint(), KDialog::spacingHint());
+ int fHeight = tmpTQGroupBox->fontMetrics().height();
grid2->addRowSpacing( 0, fHeight/2 ); // groupbox title
- brush1 = new BrushSelect( tmpQGroupBox, "Frame_1" );
- brush1->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush1 = new BrushSelect( tmpTQGroupBox, "Frame_1" );
+ brush1->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush1,1,0);
- brush2 = new BrushSelect( tmpQGroupBox, "Frame_2" );
- brush2->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush2 = new BrushSelect( tmpTQGroupBox, "Frame_2" );
+ brush2->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush2,1,1);
- brush3 = new BrushSelect( tmpQGroupBox, "Frame_3" );
- brush3->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush3 = new BrushSelect( tmpTQGroupBox, "Frame_3" );
+ brush3->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush3,1,2);
- brush4 = new BrushSelect( tmpQGroupBox, "Frame_4" );
- brush4->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush4 = new BrushSelect( tmpTQGroupBox, "Frame_4" );
+ brush4->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush4,2,0);
- brush5 = new BrushSelect( tmpQGroupBox, "Frame_5" );
- brush5->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush5 = new BrushSelect( tmpTQGroupBox, "Frame_5" );
+ brush5->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush5,2,1);
- brush6 = new BrushSelect( tmpQGroupBox, "Frame_6" );
- brush6->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush6 = new BrushSelect( tmpTQGroupBox, "Frame_6" );
+ brush6->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush6,2,2);
- brush7 = new BrushSelect( tmpQGroupBox, "Frame_7" );
- brush7->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush7 = new BrushSelect( tmpTQGroupBox, "Frame_7" );
+ brush7->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush7,3,0);
- brush8 = new BrushSelect( tmpQGroupBox, "Frame_8" );
- brush8->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush8 = new BrushSelect( tmpTQGroupBox, "Frame_8" );
+ brush8->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush8,3,1);
- brush9 = new BrushSelect( tmpQGroupBox, "Frame_9" );
- brush9->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush9 = new BrushSelect( tmpTQGroupBox, "Frame_9" );
+ brush9->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush9,3,2);
- brush10 = new BrushSelect( tmpQGroupBox, "Frame_10" );
- brush10->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush10 = new BrushSelect( tmpTQGroupBox, "Frame_10" );
+ brush10->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush10,4,0);
- brush11 = new BrushSelect( tmpQGroupBox, "Frame_11" );
- brush11->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush11 = new BrushSelect( tmpTQGroupBox, "Frame_11" );
+ brush11->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush11,4,1);
- brush12 = new BrushSelect( tmpQGroupBox, "Frame_12" );
- brush12->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush12 = new BrushSelect( tmpTQGroupBox, "Frame_12" );
+ brush12->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush12,4,2);
- brush13 = new BrushSelect( tmpQGroupBox, "Frame_13" );
- brush13->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush13 = new BrushSelect( tmpTQGroupBox, "Frame_13" );
+ brush13->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush13,5,0);
- brush14 = new BrushSelect( tmpQGroupBox, "Frame_14" );
- brush14->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush14 = new BrushSelect( tmpTQGroupBox, "Frame_14" );
+ brush14->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush14,5,1);
- brush15 = new BrushSelect( tmpQGroupBox, "Frame_15" );
- brush15->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ brush15 = new BrushSelect( tmpTQGroupBox, "Frame_15" );
+ brush15->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(brush15,5,2);
- QGridLayout *grid3 = new QGridLayout( 1, 2 );
- color = new KColorButton (tmpQGroupBox, "ColorButton_1" );
+ TQGridLayout *grid3 = new TQGridLayout( 1, 2 );
+ color = new KColorButton (tmpTQGroupBox, "ColorButton_1" );
grid3->addWidget(color,0,1);
- QLabel *tmpQLabel = new QLabel( tmpQGroupBox, "Label_1" );
- tmpQLabel->setText( i18n("Color:") );
- grid3->addWidget(tmpQLabel,0,0);
+ TQLabel *tmpTQLabel = new TQLabel( tmpTQGroupBox, "Label_1" );
+ tmpTQLabel->setText( i18n("Color:") );
+ grid3->addWidget(tmpTQLabel,0,0);
grid2->addMultiCell(grid3,6,6,0,2);
- grid3 = new QGridLayout( 1, 3 );
+ grid3 = new TQGridLayout( 1, 3 );
grid3->setSpacing(KDialog::spacingHint());
- tmpQLabel = new QLabel( tmpQGroupBox, "Label_2" );
- grid3->addWidget(tmpQLabel,0,0);
- tmpQLabel->setText( i18n("Background color:") );
+ tmpTQLabel = new TQLabel( tmpTQGroupBox, "Label_2" );
+ grid3->addWidget(tmpTQLabel,0,0);
+ tmpTQLabel->setText( i18n("Background color:") );
- bgColorButton = new KColorButton( tmpQGroupBox, "ColorButton" );
+ bgColorButton = new KColorButton( tmpTQGroupBox, "ColorButton" );
grid3->addWidget(bgColorButton,0,1);
if ( dlg->bBgColor )
bgColor = dlg->bgColor;
else
- bgColor = colorGroup().base();
+ bgColor = tqcolorGroup().base();
if (!bgColor.isValid())
- bgColor = colorGroup().base();
+ bgColor = tqcolorGroup().base();
bgColorButton->setColor( bgColor );
- connect( bgColorButton, SIGNAL( changed( const QColor & ) ),
- this, SLOT( slotSetBackgroundColor( const QColor & ) ) );
+ connect( bgColorButton, TQT_SIGNAL( changed( const TQColor & ) ),
+ this, TQT_SLOT( slotSetBackgroundColor( const TQColor & ) ) );
- notAnyColor=new QPushButton(i18n("No Color"),tmpQGroupBox);
+ notAnyColor=new TQPushButton(i18n("No Color"),tmpTQGroupBox);
grid3->addWidget(notAnyColor,0,2);
- connect( notAnyColor, SIGNAL( clicked( ) ),
- this, SLOT( slotNotAnyColor( ) ) );
+ connect( notAnyColor, TQT_SIGNAL( clicked( ) ),
+ this, TQT_SLOT( slotNotAnyColor( ) ) );
b_notAnyColor=false;
grid2->addMultiCell(grid3,7,7,0,2);
- grid->addMultiCellWidget(tmpQGroupBox,0,3,0,0);
+ grid->addMultiCellWidget(tmpTQGroupBox,0,3,0,0);
- tmpQGroupBox = new QGroupBox( this, "GroupBox1" );
- tmpQGroupBox->setTitle( i18n("Preview") );
- tmpQGroupBox->setFrameStyle( QFrame::Box | QFrame::Sunken );
- tmpQGroupBox->setAlignment( AlignLeft );
+ tmpTQGroupBox = new TQGroupBox( this, "GroupBox1" );
+ tmpTQGroupBox->setTitle( i18n("Preview") );
+ tmpTQGroupBox->setFrameStyle( TQFrame::Box | TQFrame::Sunken );
+ tmpTQGroupBox->tqsetAlignment( AlignLeft );
- grid2 = new QGridLayout(tmpQGroupBox,2,1,KDialog::marginHint(), KDialog::spacingHint());
- fHeight = tmpQGroupBox->fontMetrics().height();
+ grid2 = new TQGridLayout(tmpTQGroupBox,2,1,KDialog::marginHint(), KDialog::spacingHint());
+ fHeight = tmpTQGroupBox->fontMetrics().height();
grid2->addRowSpacing( 0, fHeight/2 ); // groupbox title
- current = new BrushSelect( tmpQGroupBox, "Current" );
- current->setFrameStyle( QFrame::Panel | QFrame::Sunken );
+ current = new BrushSelect( tmpTQGroupBox, "Current" );
+ current->setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
grid2->addWidget(current,1,0);
- grid->addWidget( tmpQGroupBox,4,0);
-
- connect( brush1, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush2, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush3, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush4, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush5, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush6, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush7, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush8, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush9, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush10, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush11, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush12, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush13, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush14, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
- connect( brush15, SIGNAL( clicked( BrushSelect* ) ),
- this, SLOT( slotUnselect2( BrushSelect* ) ) );
-
- brush1->setPattern( Qt::red, Qt::VerPattern );
- brush2->setPattern( Qt::red,Qt::HorPattern );
- brush3->setPattern( Qt::red,Qt::Dense1Pattern );
- brush4->setPattern( Qt::red,Qt::Dense2Pattern );
- brush5->setPattern( Qt::red,Qt::Dense3Pattern );
- brush6->setPattern( Qt::red,Qt::Dense4Pattern );
- brush7->setPattern( Qt::red,Qt::Dense5Pattern );
- brush8->setPattern( Qt::red,Qt::Dense6Pattern );
- brush9->setPattern( Qt::red,Qt::Dense7Pattern );
- brush10->setPattern( Qt::red,Qt::CrossPattern );
- brush11->setPattern( Qt::red,Qt::BDiagPattern );
- brush12->setPattern( Qt::red,Qt::FDiagPattern );
- brush13->setPattern( Qt::red,Qt::VerPattern );
- brush14->setPattern( Qt::red,Qt::DiagCrossPattern );
- brush15->setPattern( Qt::red,Qt::NoBrush );
+ grid->addWidget( tmpTQGroupBox,4,0);
+
+ connect( brush1, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush2, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush3, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush4, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush5, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush6, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush7, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush8, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush9, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush10, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush11, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush12, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush13, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush14, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+ connect( brush15, TQT_SIGNAL( clicked( BrushSelect* ) ),
+ this, TQT_SLOT( slotUnselect2( BrushSelect* ) ) );
+
+ brush1->setPattern( TQt::red,Qt::VerPattern );
+ brush2->setPattern( TQt::red,Qt::HorPattern );
+ brush3->setPattern( TQt::red,Qt::Dense1Pattern );
+ brush4->setPattern( TQt::red,Qt::Dense2Pattern );
+ brush5->setPattern( TQt::red,Qt::Dense3Pattern );
+ brush6->setPattern( TQt::red,Qt::Dense4Pattern );
+ brush7->setPattern( TQt::red,Qt::Dense5Pattern );
+ brush8->setPattern( TQt::red,Qt::Dense6Pattern );
+ brush9->setPattern( TQt::red,Qt::Dense7Pattern );
+ brush10->setPattern( TQt::red,Qt::CrossPattern );
+ brush11->setPattern( TQt::red,Qt::BDiagPattern );
+ brush12->setPattern( TQt::red,Qt::FDiagPattern );
+ brush13->setPattern( TQt::red,Qt::VerPattern );
+ brush14->setPattern( TQt::red,Qt::DiagCrossPattern );
+ brush15->setPattern( TQt::red,Qt::NoBrush );
current->setPattern(dlg->brushColor,dlg->brushStyle);
current->slotSelect();
@@ -3742,8 +3742,8 @@ CellFormatPagePattern::CellFormatPagePattern( QWidget* parent, CellFormatDialog
color->setColor(dlg->brushColor);
current->setBackgroundColor( bgColor );
- connect( color, SIGNAL( changed( const QColor & ) ),
- this, SLOT( slotSetColorButton( const QColor & ) ) );
+ connect( color, TQT_SIGNAL( changed( const TQColor & ) ),
+ this, TQT_SLOT( slotSetColorButton( const TQColor & ) ) );
slotSetColorButton( dlg->brushColor );
init();
@@ -3753,11 +3753,11 @@ CellFormatPagePattern::CellFormatPagePattern( QWidget* parent, CellFormatDialog
void CellFormatPagePattern::slotNotAnyColor()
{
b_notAnyColor = true;
- bgColorButton->setColor( colorGroup().base() );
- current->setBackgroundColor( colorGroup().base() );
+ bgColorButton->setColor( tqcolorGroup().base() );
+ current->setBackgroundColor( tqcolorGroup().base() );
}
-void CellFormatPagePattern::slotSetBackgroundColor( const QColor &_color )
+void CellFormatPagePattern::slotSetBackgroundColor( const TQColor &_color )
{
bgColor =_color;
current->setBackgroundColor( bgColor );
@@ -3767,63 +3767,63 @@ void CellFormatPagePattern::slotSetBackgroundColor( const QColor &_color )
void CellFormatPagePattern::init()
{
- if (dlg->brushStyle == Qt::VerPattern)
+ if (dlg->brushStyle == TQt::VerPattern)
{
brush1->slotSelect();
}
- else if (dlg->brushStyle == Qt::HorPattern)
+ else if (dlg->brushStyle == TQt::HorPattern)
{
brush2->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense1Pattern)
+ else if (dlg->brushStyle == TQt::Dense1Pattern)
{
brush3->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense2Pattern)
+ else if (dlg->brushStyle == TQt::Dense2Pattern)
{
brush4->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense3Pattern)
+ else if (dlg->brushStyle == TQt::Dense3Pattern)
{
brush5->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense4Pattern)
+ else if (dlg->brushStyle == TQt::Dense4Pattern)
{
brush6->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense5Pattern)
+ else if (dlg->brushStyle == TQt::Dense5Pattern)
{
brush7->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense6Pattern)
+ else if (dlg->brushStyle == TQt::Dense6Pattern)
{
brush8->slotSelect();
}
- else if (dlg->brushStyle == Qt::Dense7Pattern)
+ else if (dlg->brushStyle == TQt::Dense7Pattern)
{
brush9->slotSelect();
}
- else if (dlg->brushStyle == Qt::CrossPattern)
+ else if (dlg->brushStyle == TQt::CrossPattern)
{
brush10->slotSelect();
}
- else if (dlg->brushStyle == Qt::BDiagPattern)
+ else if (dlg->brushStyle == TQt::BDiagPattern)
{
brush11->slotSelect();
}
- else if (dlg->brushStyle == Qt::FDiagPattern)
+ else if (dlg->brushStyle == TQt::FDiagPattern)
{
brush12->slotSelect();
}
- else if (dlg->brushStyle == Qt::VerPattern)
+ else if (dlg->brushStyle == TQt::VerPattern)
{
brush13->slotSelect();
}
- else if (dlg->brushStyle == Qt::DiagCrossPattern)
+ else if (dlg->brushStyle == TQt::DiagCrossPattern)
{
brush14->slotSelect();
}
- else if (dlg->brushStyle == Qt::NoBrush)
+ else if (dlg->brushStyle == TQt::NoBrush)
{
brush15->slotSelect();
}
@@ -3831,7 +3831,7 @@ void CellFormatPagePattern::init()
kdDebug(36001) << "Error in brushStyle" << endl;
}
-void CellFormatPagePattern::slotSetColorButton( const QColor &_color )
+void CellFormatPagePattern::slotSetColorButton( const TQColor &_color )
{
currentColor = _color;
@@ -3896,12 +3896,12 @@ void CellFormatPagePattern::apply( CustomStyle * style )
if ( selectedBrush != 0L
&& ( dlg->brushStyle != selectedBrush->getBrushStyle()
|| dlg->brushColor != selectedBrush->getBrushColor() ) )
- style->changeBackGroundBrush( QBrush( selectedBrush->getBrushColor(), selectedBrush->getBrushStyle() ) );
+ style->changeBackGroundBrush( TQBrush( selectedBrush->getBrushColor(), selectedBrush->getBrushStyle() ) );
/*
TODO: check...
if ( b_notAnyColor)
- style->changeBgColor( QColor() );
+ style->changeBgColor( TQColor() );
else
*/
if ( bgColor != dlg->getStyle()->bgColor() )
@@ -3913,13 +3913,13 @@ void CellFormatPagePattern::apply(FormatManipulator *_obj)
if ( selectedBrush != 0L
&& ( dlg->brushStyle != selectedBrush->getBrushStyle()
|| dlg->brushColor != selectedBrush->getBrushColor() ) )
- _obj->setBackgroundBrush( QBrush( selectedBrush->getBrushColor(), selectedBrush->getBrushStyle() ) );
+ _obj->setBackgroundBrush( TQBrush( selectedBrush->getBrushColor(), selectedBrush->getBrushStyle() ) );
if ( bgColor == dlg->bgColor )
return;
if ( b_notAnyColor)
- _obj->setBackgroundColor( QColor() );
+ _obj->setBackgroundColor( TQColor() );
else if ( !bBgColorUndefined )
_obj->setBackgroundColor( bgColor );
}