summaryrefslogtreecommitdiffstats
path: root/khexedit/optiondialog.cc
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-23 01:42:07 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-23 01:42:07 +0000
commita2277b6bc715464e83882b90c2a058139b8a6b54 (patch)
treeab09b14014f59b4d8e2ddd12226aa0b22e4dfc5d /khexedit/optiondialog.cc
parentd3f79e04b34bd1f70a458b81b28fc8799498c8dc (diff)
downloadtdeutils-a2277b6bc715464e83882b90c2a058139b8a6b54.tar.gz
tdeutils-a2277b6bc715464e83882b90c2a058139b8a6b54.zip
TQt4 port kdeutils
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeutils@1238125 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'khexedit/optiondialog.cc')
-rw-r--r--khexedit/optiondialog.cc74
1 files changed, 37 insertions, 37 deletions
diff --git a/khexedit/optiondialog.cc b/khexedit/optiondialog.cc
index c1bbb39..783a8c0 100644
--- a/khexedit/optiondialog.cc
+++ b/khexedit/optiondialog.cc
@@ -46,9 +46,9 @@
#include <tqobjectlist.h>
static void enableWidget( TQWidget *w, bool state )
{
- if( w->children() )
+ if( w->tqchildren() )
{
- TQObjectList *l = (TQObjectList*)w->children(); // silence please
+ TQObjectList *l = (TQObjectList*)w->tqchildren(); // silence please
for( uint i=0; i < l->count(); i++ )
{
TQObject *o = l->at(i);
@@ -64,11 +64,11 @@ static void enableWidget( TQWidget *w, bool state )
-COptionDialog::COptionDialog( TQWidget *parent, char *name, bool modal )
+COptionDialog::COptionDialog( TQWidget *tqparent, char *name, bool modal )
:KDialogBase( IconList, i18n("Configure"), Help|Default|Apply|Ok|Cancel,
- Ok, parent, name, modal, true )
+ Ok, tqparent, name, modal, true )
{
- setHelp( "khexedit/khexedit.html", TQString::null );
+ setHelp( "khexedit/khexedit.html", TQString() );
setupLayoutPage();
setupCursorPage();
@@ -260,7 +260,7 @@ void COptionDialog::setupCursorPage( void )
TQVBoxLayout *topLayout = new TQVBoxLayout( page, 0, spacingHint() );
TQVButtonGroup *group = new TQVButtonGroup( i18n("Blinking"), page );
- group->layout()->setMargin( spacingHint() );
+ group->tqlayout()->setMargin( spacingHint() );
topLayout->addWidget( group );
text = i18n("Do not b&link");
@@ -282,7 +282,7 @@ void COptionDialog::setupCursorPage( void )
TQT_SLOT( slotChanged()));
group = new TQVButtonGroup( i18n("Shape"), page );
- group->layout()->setMargin( spacingHint() );
+ group->tqlayout()->setMargin( spacingHint() );
topLayout->addWidget( group );
text = i18n("Always &use block (rectangular) cursor");
@@ -298,7 +298,7 @@ void COptionDialog::setupCursorPage( void )
text = i18n("Cursor Behavior When Editor Loses Focus");
group = new TQVButtonGroup( text, page );
- group->layout()->setMargin( spacingHint() );
+ group->tqlayout()->setMargin( spacingHint() );
topLayout->addWidget( group );
text = i18n("&Stop blinking (if blinking is enabled)");
@@ -351,7 +351,7 @@ void COptionDialog::setupColorPage( void )
modeList.append( i18n("Marked Background") );
modeList.append( i18n("Marked Text") );
modeList.append( i18n("Cursor Background") );
- modeList.append( i18n("Cursor Text (block shape)") );
+ modeList.append( i18n("Cursor Text (block tqshape)") );
modeList.append( i18n("Bookmark Background") );
modeList.append( i18n("Bookmark Text") );
modeList.append( i18n("Separator") );
@@ -439,7 +439,7 @@ void COptionDialog::setupFilePage( void )
modeList.append( i18n("Most Recent Document") );
modeList.append( i18n("All Recent Documents") );
mFile.openCombo->insertStringList( modeList );
- mFile.openCombo->setMinimumWidth( mFile.openCombo->sizeHint().width() );
+ mFile.openCombo->setMinimumWidth( mFile.openCombo->tqsizeHint().width() );
connect( mFile.openCombo, TQT_SIGNAL(activated(int)),
this, TQT_SLOT( slotChanged()));
@@ -548,7 +548,7 @@ void COptionDialog::setupMiscPage( void )
this, TQT_SLOT( slotChanged()));
TQVButtonGroup *group = new TQVButtonGroup( i18n("Sounds"), page );
- group->layout()->setMargin( spacingHint() );
+ group->tqlayout()->setMargin( spacingHint() );
topLayout->addWidget( group );
text = i18n("Make sound on data &input (eg. typing) failure");
mMisc.inputCheck = new TQCheckBox( text, group );
@@ -560,7 +560,7 @@ void COptionDialog::setupMiscPage( void )
this, TQT_SLOT( slotChanged()));
group = new TQVButtonGroup( i18n("Bookmark Visibility"), page );
- group->layout()->setMargin( spacingHint() );
+ group->tqlayout()->setMargin( spacingHint() );
topLayout->addWidget( group );
text = i18n("Use visible bookmarks in the offset column");
mMisc.bookmarkColumnCheck = new TQCheckBox( text, group );
@@ -696,9 +696,9 @@ void COptionDialog::slotDefault( void )
{
case page_layout:
{
- SDisplayLayout layout;
+ SDisplayLayout tqlayout;
SDisplayLine line;
- setLayout( layout, line );
+ setLayout( tqlayout, line );
}
break;
@@ -758,7 +758,7 @@ void COptionDialog::slotApply( void )
mDisplayState.line.setColumnSize(index, mLayout.columnSizeSpin->value());
emit lineSizeChoice( mDisplayState.line );
- SDisplayLayout &l = mDisplayState.layout;
+ SDisplayLayout &l = mDisplayState.tqlayout;
l.lockLine = mLayout.lockLineCheck->isChecked();
l.lockColumn = mLayout.lockColumnCheck->isChecked();
l.leftSeparatorWidth = mLayout.leftSepWidthSpin->value();
@@ -789,7 +789,7 @@ void COptionDialog::slotApply( void )
l.horzGridWidth = l.vertGridWidth = 1;
}
- emit layoutChoice( mDisplayState.layout );
+ emit tqlayoutChoice( mDisplayState.tqlayout );
}
break;
@@ -883,35 +883,35 @@ void COptionDialog::slotApply( void )
configChanged = false;
}
-void COptionDialog::setLayout( SDisplayLayout &layout, SDisplayLine &line )
+void COptionDialog::setLayout( SDisplayLayout &tqlayout, SDisplayLine &line )
{
mDisplayState.line = line;
- mDisplayState.layout = layout;
+ mDisplayState.tqlayout = tqlayout;
slotModeSelectorChanged( mLayout.formatCombo->currentItem() );
- mLayout.lockLineCheck->setChecked( layout.lockLine );
- mLayout.lockColumnCheck->setChecked( layout.lockColumn );
- mLayout.leftSepWidthSpin->setValue( layout.leftSeparatorWidth );
- mLayout.rightSepWidthSpin->setValue( layout.rightSeparatorWidth );
- mLayout.separatorSpin->setValue( layout.separatorMarginWidth );
- mLayout.edgeSpin->setValue( layout.edgeMarginWidth );
- mLayout.leftSepWidthSpin->setValue( layout.leftSeparatorWidth );
- mLayout.rightSepWidthSpin->setValue( layout.rightSeparatorWidth );
- mLayout.columnCheck->setChecked( layout.columnCharSpace );
- slotColumnSepCheck( layout.columnCharSpace );
- mLayout.columnSepSpin->setValue( layout.columnSpacing );
-
- if( layout.horzGridWidth == 0 && layout.vertGridWidth == 0 )
+ mLayout.lockLineCheck->setChecked( tqlayout.lockLine );
+ mLayout.lockColumnCheck->setChecked( tqlayout.lockColumn );
+ mLayout.leftSepWidthSpin->setValue( tqlayout.leftSeparatorWidth );
+ mLayout.rightSepWidthSpin->setValue( tqlayout.rightSeparatorWidth );
+ mLayout.separatorSpin->setValue( tqlayout.separatorMarginWidth );
+ mLayout.edgeSpin->setValue( tqlayout.edgeMarginWidth );
+ mLayout.leftSepWidthSpin->setValue( tqlayout.leftSeparatorWidth );
+ mLayout.rightSepWidthSpin->setValue( tqlayout.rightSeparatorWidth );
+ mLayout.columnCheck->setChecked( tqlayout.columnCharSpace );
+ slotColumnSepCheck( tqlayout.columnCharSpace );
+ mLayout.columnSepSpin->setValue( tqlayout.columnSpacing );
+
+ if( tqlayout.horzGridWidth == 0 && tqlayout.vertGridWidth == 0 )
{
mLayout.gridCombo->setCurrentItem(0);
}
- else if( layout.horzGridWidth != 0 && layout.vertGridWidth != 0 )
+ else if( tqlayout.horzGridWidth != 0 && tqlayout.vertGridWidth != 0 )
{
mLayout.gridCombo->setCurrentItem(3);
}
else
{
- mLayout.gridCombo->setCurrentItem( layout.vertGridWidth != 0 ? 1 : 2 );
+ mLayout.gridCombo->setCurrentItem( tqlayout.vertGridWidth != 0 ? 1 : 2 );
}
}
@@ -1021,7 +1021,7 @@ void COptionDialog::setFile( SDisplayMisc &misc )
void COptionDialog::setState( SDisplayState &state )
{
- setLayout( state.layout, state.line );
+ setLayout( state.tqlayout, state.line );
setCursor( state.cursor );
setColor( state.color );
setFont( state.font );
@@ -1050,8 +1050,8 @@ SDisplayCursor::EFocusMode COptionDialog::cursorFocusMode( void )
-CColorListBox::CColorListBox( TQWidget *parent, const char *name, WFlags f )
- :KListBox( parent, name, f ), mCurrentOnDragEnter(-1)
+CColorListBox::CColorListBox( TQWidget *tqparent, const char *name, WFlags f )
+ :KListBox( tqparent, name, f ), mCurrentOnDragEnter(-1)
{
connect( this, TQT_SIGNAL(selected(int)), this, TQT_SLOT(newColor(int)) );
setAcceptDrops( true);
@@ -1199,7 +1199,7 @@ void CColorListItem::paint( TQPainter *p )
p->drawText( mBoxWidth+3*2, fm.ascent() + fm.leading()/2, text() );
- p->setPen( Qt::black );
+ p->setPen( TQt::black );
p->drawRect( 3, 1, mBoxWidth, h-1 );
p->fillRect( 4, 2, mBoxWidth-2, h-3, mColor );
}