summaryrefslogtreecommitdiffstats
path: root/lib/compatibility/kmdi/qextmdi
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-16 19:02:47 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-16 19:02:47 +0000
commite985f7e545f4739493965aad69bbecb136dc9346 (patch)
tree54afd409d8acd6202dd8ab611d24e78c28e4c0a0 /lib/compatibility/kmdi/qextmdi
parentf7670c198945adc3b95ad69a959fe5f8ae55b493 (diff)
downloadtdewebdev-e985f7e545f4739493965aad69bbecb136dc9346.tar.gz
tdewebdev-e985f7e545f4739493965aad69bbecb136dc9346.zip
TQt4 port kdewebdev
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1237029 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'lib/compatibility/kmdi/qextmdi')
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdelibs_export.h4
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdemacros.h.in20
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdockwidget.cpp684
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdockwidget.h145
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdockwidget_p.h6
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdockwidget_private.cpp150
-rw-r--r--lib/compatibility/kmdi/qextmdi/kdockwidget_private.h25
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildarea.cpp52
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildarea.h29
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildfrm.cpp220
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildfrm.h44
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.cpp34
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.h17
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildview.cpp138
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdichildview.h49
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdidefines.h8
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdidockcontainer.cpp110
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdidockcontainer.h21
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.cpp14
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.h19
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdifocuslist.cpp15
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdifocuslist.h9
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdiguiclient.cpp36
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdiguiclient.h6
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdiiterator.h6
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdilistiterator.h6
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdimainfrm.cpp198
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdimainfrm.h31
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmdinulliterator.h6
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmditaskbar.cpp44
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmditaskbar.h20
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.cpp26
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.h9
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmultitabbar.cpp156
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmultitabbar.h27
-rw-r--r--lib/compatibility/kmdi/qextmdi/kmultitabbar_p.h11
-rw-r--r--lib/compatibility/kmdi/qextmdi/ktabbar.cpp54
-rw-r--r--lib/compatibility/kmdi/qextmdi/ktabbar.h9
-rw-r--r--lib/compatibility/kmdi/qextmdi/ktabwidget.cpp44
-rw-r--r--lib/compatibility/kmdi/qextmdi/ktabwidget.h19
40 files changed, 1277 insertions, 1244 deletions
diff --git a/lib/compatibility/kmdi/qextmdi/kdelibs_export.h b/lib/compatibility/kmdi/qextmdi/kdelibs_export.h
index 0ca49784..c46b5005 100644
--- a/lib/compatibility/kmdi/qextmdi/kdelibs_export.h
+++ b/lib/compatibility/kmdi/qextmdi/kdelibs_export.h
@@ -26,7 +26,7 @@
/* needed, because e.g. Q_OS_UNIX is so frequently used */
#include <tqglobal.h>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
#include <kdelibs_export_win.h>
#else /* Q_OS_UNIX */
@@ -68,7 +68,7 @@
#endif /*_KDELIBS_EXPORT_H*/
-/* workaround for kdecore: stupid moc's grammar doesn't accept two macros
+/* workaround for kdecore: stupid tqmoc's grammar doesn't accept two macros
between 'class' keyword and <classname>: */
#ifdef KDE_DEPRECATED
# ifndef KDECORE_EXPORT_DEPRECATED
diff --git a/lib/compatibility/kmdi/qextmdi/kdemacros.h.in b/lib/compatibility/kmdi/qextmdi/kdemacros.h.in
index 95ac5d8e..9308c18d 100644
--- a/lib/compatibility/kmdi/qextmdi/kdemacros.h.in
+++ b/lib/compatibility/kmdi/qextmdi/kdemacros.h.in
@@ -40,7 +40,7 @@
#ifdef __KDE_HAVE_GCC_VISIBILITY
#define KDE_NO_EXPORT __attribute__ ((visibility("hidden")))
#define KDE_EXPORT __attribute__ ((visibility("default")))
-#elif defined(Q_WS_WIN)
+#elif defined(TQ_WS_WIN)
#define KDE_NO_EXPORT
#define KDE_EXPORT __declspec(dllexport)
#else
@@ -49,13 +49,13 @@
#endif
/**
- * KDE_Q_EXPORT_PLUGIN is a workaround for Qt not being able to
+ * KDE_TQ_EXPORT_PLUGIN is a workaround for TQt not being able to
* cope with symbol visibility.
*/
-#define KDE_Q_EXPORT_PLUGIN(PLUGIN) \
- Q_EXTERN_C KDE_EXPORT const char* qt_ucm_query_verification_data(); \
- Q_EXTERN_C KDE_EXPORT QUnknownInterface* ucm_instantiate(); \
- Q_EXPORT_PLUGIN(PLUGIN)
+#define KDE_TQ_EXPORT_PLUGIN(PLUGIN) \
+ TQ_EXTERN_C KDE_EXPORT const char* qt_ucm_query_verification_data(); \
+ TQ_EXTERN_C KDE_EXPORT TQUnknownInterface* ucm_instantiate(); \
+ TQ_EXPORT_PLUGIN(PLUGIN)
/**
* The KDE_PACKED can be used to hint the compiler that a particular
@@ -101,15 +101,15 @@
* \endcode
*
* \note
- * It does not make much sense to use the KDE_DEPRECATED keyword for a Qt signal;
+ * It does not make much sense to use the KDE_DEPRECATED keyword for a TQt signal;
* this is because usually get called by the class which they belong to,
* and one'd assume that a class author doesn't use deprecated methods of his
* own class. The only exception to this are signals which are connected to
- * other signals; they get invoked from moc-generated code. In any case,
+ * other signals; they get invoked from tqmoc-generated code. In any case,
* printing a warning message in either case is not useful.
* For slots, it can make sense (since slots can be invoked directly) but be
* aware that if the slots get triggered by a signal, the will get called from
- * moc code as well and thus the warnings are useless.
+ * tqmoc code as well and thus the warnings are useless.
*
* \par
* Also note that it is not possible to use KDE_DEPRECATED for classes which
@@ -172,7 +172,7 @@
*
* \note The added functions must be added to the header at the same location
* as the macro; changing the order of virtual functions in a header is also
- * binary incompatible as it breaks the layout of the vtable.
+ * binary incompatible as it breaks the tqlayout of the vtable.
*/
#define RESERVE_VIRTUAL_1 \
diff --git a/lib/compatibility/kmdi/qextmdi/kdockwidget.cpp b/lib/compatibility/kmdi/qextmdi/kdockwidget.cpp
index 32a5eaf0..fdb463dc 100644
--- a/lib/compatibility/kmdi/qextmdi/kdockwidget.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kdockwidget.cpp
@@ -43,7 +43,7 @@
#include <kglobalsettings.h>
#include "config.h"
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#include <X11/X.h>
#include <X11/Xlib.h>
#endif
@@ -99,8 +99,8 @@ static const char* const not_close_xpm[]={
*
* @author Max Judin.
*/
-KDockMainWindow::KDockMainWindow( TQWidget* parent, const char *name, WFlags f)
-:KMainWindow( parent, name, f )
+KDockMainWindow::KDockMainWindow( TQWidget* tqparent, const char *name, WFlags f)
+:KMainWindow( tqparent, name, f )
{
TQString new_name = TQString(name) + TQString("_DockManager");
dockManager = new KDockManager( this, new_name.latin1() );
@@ -122,7 +122,7 @@ void KDockMainWindow::setMainDockWidget( KDockWidget* mdw )
void KDockMainWindow::setView( TQWidget *view )
{
if ( view->isA("KDockWidget") ){
- if ( view->parent() != this ) ((KDockWidget*)view)->applyToWidget( this );
+ if ( TQT_BASE_OBJECT(view->tqparent()) != TQT_BASE_OBJECT(this) ) ((KDockWidget*)view)->applyToWidget( this );
}
#ifndef NO_KDE2
@@ -132,9 +132,9 @@ void KDockMainWindow::setView( TQWidget *view )
#endif
}
-KDockWidget* KDockMainWindow::createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* parent, const TQString& strCaption, const TQString& strTabPageLabel)
+KDockWidget* KDockMainWindow::createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* tqparent, const TQString& strCaption, const TQString& strTabPageLabel)
{
- return new KDockWidget( dockManager, name.latin1(), pixmap, parent, strCaption, strTabPageLabel );
+ return new KDockWidget( dockManager, name.latin1(), pixmap, tqparent, strCaption, strTabPageLabel );
}
void KDockMainWindow::makeDockVisible( KDockWidget* dock )
@@ -185,15 +185,15 @@ void KDockMainWindow::slotDockWidgetUndocked()
}
/*************************************************************************/
-KDockWidgetAbstractHeaderDrag::KDockWidgetAbstractHeaderDrag( KDockWidgetAbstractHeader* parent, KDockWidget* dock, const char* name )
-:TQFrame( parent, name )
+KDockWidgetAbstractHeaderDrag::KDockWidgetAbstractHeaderDrag( KDockWidgetAbstractHeader* tqparent, KDockWidget* dock, const char* name )
+:TQFrame( tqparent, name )
{
dw = dock;
installEventFilter( dock->dockManager() );
}
/*************************************************************************/
-KDockWidgetHeaderDrag::KDockWidgetHeaderDrag( KDockWidgetAbstractHeader* parent, KDockWidget* dock, const char* name )
-:KDockWidgetAbstractHeaderDrag( parent, dock, name )
+KDockWidgetHeaderDrag::KDockWidgetHeaderDrag( KDockWidgetAbstractHeader* tqparent, KDockWidget* dock, const char* name )
+:KDockWidgetAbstractHeaderDrag( tqparent, dock, name )
{
}
@@ -203,38 +203,38 @@ void KDockWidgetHeaderDrag::paintEvent( TQPaintEvent* )
paint.begin( this );
- style().drawPrimitive (TQStyle::PE_DockWindowHandle, &paint, TQRect(0,0,width(), height()), colorGroup());
+ tqstyle().tqdrawPrimitive (TQStyle::PE_DockWindowHandle, &paint, TQRect(0,0,width(), height()), tqcolorGroup());
paint.end();
}
/*************************************************************************/
-KDockWidgetAbstractHeader::KDockWidgetAbstractHeader( KDockWidget* parent, const char* name )
-:TQFrame( parent, name )
+KDockWidgetAbstractHeader::KDockWidgetAbstractHeader( KDockWidget* tqparent, const char* name )
+:TQFrame( tqparent, name )
{
}
/*************************************************************************/
-KDockWidgetHeader::KDockWidgetHeader( KDockWidget* parent, const char* name )
-:KDockWidgetAbstractHeader( parent, name )
+KDockWidgetHeader::KDockWidgetHeader( KDockWidget* tqparent, const char* name )
+:KDockWidgetAbstractHeader( tqparent, name )
{
#ifdef BORDERLESS_WINDOWS
setCursor(TQCursor(ArrowCursor));
#endif
- d = new KDockWidgetHeaderPrivate( this );
+ d = new KDockWidgetHeaderPrivate( TQT_TQOBJECT(this) );
- layout = new TQHBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
+ tqlayout = new TQHBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
- drag = new KDockWidgetHeaderDrag( this, parent );
+ drag = new KDockWidgetHeaderDrag( this, tqparent );
closeButton = new KDockButton_Private( this, "DockCloseButton" );
TQToolTip::add( closeButton, i18n("Close") );
- closeButton->setPixmap( style().stylePixmap (TQStyle::SP_TitleBarCloseButton , this));
+ closeButton->setPixmap( tqstyle().stylePixmap (TQStyle::SP_TitleBarCloseButton , this));
closeButton->setFixedSize(closeButton->pixmap()->width(),closeButton->pixmap()->height());
- connect( closeButton, TQT_SIGNAL(clicked()), parent, TQT_SIGNAL(headerCloseButtonClicked()));
- connect( closeButton, TQT_SIGNAL(clicked()), parent, TQT_SLOT(undock()));
+ connect( closeButton, TQT_SIGNAL(clicked()), tqparent, TQT_SIGNAL(headerCloseButtonClicked()));
+ connect( closeButton, TQT_SIGNAL(clicked()), tqparent, TQT_SLOT(undock()));
stayButton = new KDockButton_Private( this, "DockStayButton" );
- TQToolTip::add( stayButton, i18n("Freeze the window geometry", "Freeze") );
+ TQToolTip::add( stayButton, i18n("Freeze the window tqgeometry", "Freeze") );
stayButton->setToggleButton( true );
stayButton->setPixmap( const_cast< const char** >(not_close_xpm) );
stayButton->setFixedSize(closeButton->pixmap()->width(),closeButton->pixmap()->height());
@@ -244,36 +244,36 @@ KDockWidgetHeader::KDockWidgetHeader( KDockWidget* parent, const char* name )
TQToolTip::add( dockbackButton, i18n("Dock this window", "Dock") );
dockbackButton->setPixmap( const_cast< const char** >(dockback_xpm));
dockbackButton->setFixedSize(closeButton->pixmap()->width(),closeButton->pixmap()->height());
- connect( dockbackButton, TQT_SIGNAL(clicked()), parent, TQT_SIGNAL(headerDockbackButtonClicked()));
- connect( dockbackButton, TQT_SIGNAL(clicked()), parent, TQT_SLOT(dockBack()));
+ connect( dockbackButton, TQT_SIGNAL(clicked()), tqparent, TQT_SIGNAL(headerDockbackButtonClicked()));
+ connect( dockbackButton, TQT_SIGNAL(clicked()), tqparent, TQT_SLOT(dockBack()));
d->toDesktopButton = new KDockButton_Private( this, "ToDesktopButton" );
TQToolTip::add( d->toDesktopButton, i18n("Detach") );
d->toDesktopButton->setPixmap( const_cast< const char** >(todesktop_xpm));
d->toDesktopButton->setFixedSize(closeButton->pixmap()->width(),closeButton->pixmap()->height());
- connect( d->toDesktopButton, TQT_SIGNAL(clicked()), parent, TQT_SLOT(toDesktop()));
+ connect( d->toDesktopButton, TQT_SIGNAL(clicked()), tqparent, TQT_SLOT(toDesktop()));
stayButton->hide();
d->dummy = new TQWidget( this );
d->dummy->setFixedSize( 1,closeButton->pixmap()->height() );
- layout->addWidget( drag );
- layout->addWidget( dockbackButton );
- layout->addWidget( d->toDesktopButton );
- layout->addWidget( d->dummy);
- layout->addWidget( stayButton );
- layout->addWidget( closeButton );
- layout->activate();
+ tqlayout->addWidget( drag );
+ tqlayout->addWidget( dockbackButton );
+ tqlayout->addWidget( d->toDesktopButton );
+ tqlayout->addWidget( d->dummy);
+ tqlayout->addWidget( stayButton );
+ tqlayout->addWidget( closeButton );
+ tqlayout->activate();
d->dummy->hide();
- drag->setFixedHeight( layout->minimumSize().height() );
+ drag->setFixedHeight( tqlayout->tqminimumSize().height() );
}
void KDockWidgetHeader::setTopLevel( bool isTopLevel )
{
d->topLevel = isTopLevel;
if ( isTopLevel ){
- KDockWidget* par = (KDockWidget*)parent();
+ KDockWidget* par = (KDockWidget*)tqparent();
if( par) {
if( par->isDockBackPossible())
dockbackButton->show();
@@ -291,7 +291,7 @@ void KDockWidgetHeader::setTopLevel( bool isTopLevel )
if( d->showToDesktopButton )
d->toDesktopButton->show();
}
- layout->activate();
+ tqlayout->activate();
bool dontShowDummy=drag->isVisibleTo(this) || dockbackButton->isVisibleTo(this) ||
d->toDesktopButton->isVisibleTo(this) || stayButton->isVisibleTo(this) ||
@@ -318,75 +318,75 @@ void KDockWidgetHeader::setDragPanel( KDockWidgetHeaderDrag* nd )
{
if ( !nd ) return;
- delete layout;
- layout = new TQHBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
+ delete tqlayout;
+ tqlayout = new TQHBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
delete drag;
drag = nd;
- if (drag->parentWidget()!=this) {
+ if (drag->tqparentWidget()!=this) {
drag->reparent(this,TQPoint(0,0));
}
- layout->addWidget( drag );
- layout->addWidget( dockbackButton );
- layout->addWidget( d->dummy );
- layout->addWidget( d->toDesktopButton );
- layout->addWidget( stayButton );
+ tqlayout->addWidget( drag );
+ tqlayout->addWidget( dockbackButton );
+ tqlayout->addWidget( d->dummy );
+ tqlayout->addWidget( d->toDesktopButton );
+ tqlayout->addWidget( stayButton );
bool dontShowDummy=drag->isVisibleTo(this) || dockbackButton->isVisibleTo(this) ||
d->toDesktopButton->isVisibleTo(this) || stayButton->isVisibleTo(this) ||
closeButton->isVisibleTo(this);
for (TQPtrListIterator<KDockButton_Private> it( d->btns );it.current();++it) {
- layout->addWidget(it.current());
+ tqlayout->addWidget(it.current());
dontShowDummy=dontShowDummy || (it.current()->isVisibleTo(this));
}
if (dontShowDummy) d->dummy->hide(); else d->dummy->show();
- layout->addWidget( closeButton );
- layout->activate();
- kdDebug(282)<<"KdockWidgetHeader::setDragPanel:minimum height="<<layout->minimumSize().height()<<endl;
+ tqlayout->addWidget( closeButton );
+ tqlayout->activate();
+ kdDebug(282)<<"KdockWidgetHeader::setDragPanel:minimum height="<<tqlayout->tqminimumSize().height()<<endl;
#ifdef __GNUC__
#warning FIXME
#endif
- drag->setFixedHeight( closeButton->height()); // /*layout->minimumS*/sizeHint().height() );
+ drag->setFixedHeight( closeButton->height()); // /*tqlayout->minimumS*/tqsizeHint().height() );
}
void KDockWidgetHeader::addButton(KDockButton_Private* btn) {
if (!btn) return;
- if (btn->parentWidget()!=this) {
+ if (btn->tqparentWidget()!=this) {
btn->reparent(this,TQPoint(0,0));
}
btn->setFixedSize(closeButton->pixmap()->width(),closeButton->pixmap()->height());
- if (!d->btns.containsRef(btn)) d->btns.append(btn);
+ if (!d->btns.tqcontainsRef(btn)) d->btns.append(btn);
btn->show();
- delete layout;
- layout = new TQHBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
+ delete tqlayout;
+ tqlayout = new TQHBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
- layout->addWidget( drag );
- layout->addWidget( dockbackButton );
- layout->addWidget( d->toDesktopButton );
- layout->addWidget( d->dummy);
- layout->addWidget( stayButton );
+ tqlayout->addWidget( drag );
+ tqlayout->addWidget( dockbackButton );
+ tqlayout->addWidget( d->toDesktopButton );
+ tqlayout->addWidget( d->dummy);
+ tqlayout->addWidget( stayButton );
bool dontShowDummy=drag->isVisibleTo(this) || dockbackButton->isVisibleTo(this) ||
d->toDesktopButton->isVisibleTo(this) || stayButton->isVisibleTo(this) ||
closeButton->isVisibleTo(this);
for (TQPtrListIterator<KDockButton_Private> it( d->btns );it.current();++it) {
- layout->addWidget(it.current());
+ tqlayout->addWidget(it.current());
dontShowDummy=dontShowDummy || (it.current()->isVisibleTo(this));
}
if (dontShowDummy) d->dummy->hide(); else d->dummy->show();
- layout->addWidget( closeButton );
- layout->activate();
- drag->setFixedHeight( layout->minimumSize().height() );
+ tqlayout->addWidget( closeButton );
+ tqlayout->activate();
+ drag->setFixedHeight( tqlayout->tqminimumSize().height() );
}
void KDockWidgetHeader::removeButton(KDockButton_Private* btn) {
- if (btn->parentWidget()==this) {
- if (d->btns.containsRef(btn)) d->btns.removeRef(btn);
+ if (btn->tqparentWidget()==this) {
+ if (d->btns.tqcontainsRef(btn)) d->btns.removeRef(btn);
delete btn;
}
}
@@ -425,12 +425,12 @@ void KDockWidgetHeader::setDragEnabled(bool b)
#ifndef NO_KDE2
void KDockWidgetHeader::saveConfig( KConfig* c )
{
- c->writeEntry( TQString("%1%2").arg(parent()->name()).arg(":stayButton"), stayButton->isOn() );
+ c->writeEntry( TQString("%1%2").tqarg(tqparent()->name()).tqarg(":stayButton"), stayButton->isOn() );
}
void KDockWidgetHeader::loadConfig( KConfig* c )
{
- setDragEnabled( !c->readBoolEntry( TQString("%1%2").arg(parent()->name()).arg(":stayButton"), false ) );
+ setDragEnabled( !c->readBoolEntry( TQString("%1%2").tqarg(tqparent()->name()).tqarg(":stayButton"), false ) );
}
#endif
@@ -479,11 +479,11 @@ public:
/*************************************************************************/
-KDockWidget::KDockWidget( KDockManager* dockManager, const char* name, const TQPixmap &pixmap, TQWidget* parent, const TQString& strCaption, const TQString& strTabPageLabel, WFlags f)
+KDockWidget::KDockWidget( KDockManager* dockManager, const char* name, const TQPixmap &pixmap, TQWidget* tqparent, const TQString& strCaption, const TQString& strTabPageLabel, WFlags f)
#ifdef BORDERLESS_WINDOWS
-: TQWidget( parent, name, f )//| WType_Dialog | WStyle_Customize | WStyle_NoBorder )
+: TQWidget( tqparent, name, f )//| WType_Dialog | WStyle_Customize | WStyle_NoBorder )
#else
-: TQWidget( parent, name, f )
+: TQWidget( tqparent, name, f )
#endif
,formerBrotherDockWidget(0L)
,currentDockPos(DockNone)
@@ -495,13 +495,13 @@ KDockWidget::KDockWidget( KDockManager* dockManager, const char* name, const TQP
{
d = new KDockWidgetPrivate(); // create private data
- d->_parent = parent;
+ d->_parent = tqparent;
- layout = new TQVBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
+ tqlayout = new TQVBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
manager = dockManager;
- manager->childDock->append( this );
+ manager->childDock->append( TQT_TQOBJECT(this) );
installEventFilter( manager );
eDocking = DockFullDocking;
@@ -526,17 +526,17 @@ KDockWidget::KDockWidget( KDockManager* dockManager, const char* name, const TQP
widget = 0L;
TQObject::connect(this, TQT_SIGNAL(hasUndocked()), manager->main, TQT_SLOT(slotDockWidgetUndocked()) );
- applyToWidget( parent, TQPoint(0,0) );
+ applyToWidget( tqparent, TQPoint(0,0) );
}
void KDockWidget::setPixmap(const TQPixmap& pixmap) {
delete pix;
pix=new TQPixmap(pixmap);
setIcon(*pix);
- KDockTabGroup *dtg=parentDockTabGroup();
+ KDockTabGroup *dtg=tqparentDockTabGroup();
if (dtg)
dtg->changeTab(this,pixmap,dtg->tabLabel(this));
- TQWidget *contWid=parentDockContainer();
+ TQWidget *contWid=tqparentDockContainer();
if (contWid) {
KDockContainer *x = dynamic_cast<KDockContainer*>(contWid);
if (x) {
@@ -565,8 +565,8 @@ KDockWidget::~KDockWidget()
}
}
emit iMBeingClosed();
- if (manager->d) manager->d->containerDocks.remove(this);
- manager->childDock->remove( this );
+ if (manager->d) manager->d->containerDocks.remove(TQT_TQOBJECT(this));
+ manager->childDock->remove( TQT_TQOBJECT(this) );
delete pix;
delete d; // destroy private data
d=0;
@@ -577,7 +577,7 @@ void KDockWidget::paintEvent(TQPaintEvent* pe)
TQWidget::paintEvent(pe);
TQPainter paint;
paint.begin( this );
- style().drawPrimitive (TQStyle::PE_Panel, &paint, TQRect(0,0,width(), height()), colorGroup());
+ tqstyle().tqdrawPrimitive (TQStyle::PE_Panel, &paint, TQRect(0,0,width(), height()), tqcolorGroup());
paint.end();
}
@@ -585,7 +585,7 @@ void KDockWidget::leaveEvent(TQEvent *e)
{
TQWidget::leaveEvent(e);
#ifdef BORDERLESS_WINDOWS
- if (parent()) return;
+ if (tqparent()) return;
// setCursor(TQCursor(ArrowCursor));
#endif
}
@@ -593,7 +593,7 @@ void KDockWidget::leaveEvent(TQEvent *e)
void KDockWidget::mousePressEvent(TQMouseEvent* mme)
{
#ifdef BORDERLESS_WINDOWS
- if (!parent())
+ if (!tqparent())
{
kdDebug(282)<<"KDockWidget::mousePressEvent"<<endl;
@@ -604,7 +604,7 @@ void KDockWidget::mousePressEvent(TQMouseEvent* mme)
int styleheight;
TQPoint mp;
mp=mme->pos();
- styleheight=2*style().pixelMetric(TQStyle::PM_DefaultFrameWidth,this);
+ styleheight=2*tqstyle().tqpixelMetric(TQStyle::PM_DefaultFrameWidth,this);
bbottom=mp.y()>=height()-styleheight;
btop=mp.y()<=styleheight;
bleft=mp.x()<=styleheight;
@@ -663,7 +663,7 @@ void KDockWidget::mouseMoveEvent(TQMouseEvent* mme)
{
TQWidget::mouseMoveEvent(mme);
#ifdef BORDERLESS_WINDOWS
- if (parent()) return;
+ if (tqparent()) return;
if (d->resizing)
{
@@ -692,7 +692,7 @@ void KDockWidget::mouseMoveEvent(TQMouseEvent* mme)
int styleheight;
TQPoint mp;
mp=mme->pos();
- styleheight=2*style().pixelMetric(TQStyle::PM_DefaultFrameWidth,this);
+ styleheight=2*tqstyle().tqpixelMetric(TQStyle::PM_DefaultFrameWidth,this);
bbottom=mp.y()>=height()-styleheight;
btop=mp.y()<=styleheight;
bleft=mp.x()<=styleheight;
@@ -748,15 +748,15 @@ void KDockWidget::setHeader( KDockWidgetAbstractHeader* h )
if ( header ){
delete header;
- delete layout;
+ delete tqlayout;
header = h;
- layout = new TQVBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
- layout->addWidget( header );
+ tqlayout = new TQVBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
+ tqlayout->addWidget( header );
setWidget( widget );
} else {
header = h;
- layout->addWidget( header );
+ tqlayout->addWidget( header );
}
kdDebug(282)<<caption()<<": KDockWidget::setHeader"<<endl;
setEnableDocking(eDocking);
@@ -772,14 +772,14 @@ void KDockWidget::setEnableDocking( int pos )
void KDockWidget::updateHeader()
{
- if ( parent() ){
+ if ( tqparent() ){
#ifdef BORDERLESS_WINDOWS
- layout->setMargin(0);
+ tqlayout->setMargin(0);
setMouseTracking(false);
setCursor(TQCursor(ArrowCursor));
#endif
- if ( (parent() == manager->main) || isGroup || (eDocking == KDockWidget::DockNone) ){
+ if ( (TQT_BASE_OBJECT(tqparent()) == TQT_BASE_OBJECT(manager->main)) || isGroup || (eDocking == KDockWidget::DockNone) ){
header->hide();
} else {
header->setTopLevel( false );
@@ -792,7 +792,7 @@ void KDockWidget::updateHeader()
header->setTopLevel( true );
header->show();
#ifdef BORDERLESS_WINDOWS
- layout->setMargin(2*style().pixelMetric(TQStyle::PM_DefaultFrameWidth,this));
+ tqlayout->setMargin(2*tqstyle().tqpixelMetric(TQStyle::PM_DefaultFrameWidth,this));
setMouseTracking(true);
#endif
}
@@ -800,7 +800,7 @@ void KDockWidget::updateHeader()
void KDockWidget::applyToWidget( TQWidget* s, const TQPoint& p )
{
- if ( parent() != s )
+ if ( TQT_BASE_OBJECT(tqparent()) != TQT_BASE_OBJECT(s) )
{
hide();
reparent(s, 0, TQPoint(0,0), false);
@@ -811,7 +811,7 @@ void KDockWidget::applyToWidget( TQWidget* s, const TQPoint& p )
}
if ( manager && s == manager->main ){
- setGeometry( TQRect(TQPoint(0,0), manager->main->geometry().size()) );
+ setGeometry( TQRect(TQPoint(0,0), manager->main->tqgeometry().size()) );
}
if ( !s )
@@ -819,7 +819,7 @@ void KDockWidget::applyToWidget( TQWidget* s, const TQPoint& p )
move(p);
#ifndef NO_KDE2
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if (d->transient && d->_parent)
XSetTransientForHint( qt_xdisplay(), winId(), d->_parent->winId() );
@@ -829,7 +829,7 @@ void KDockWidget::applyToWidget( TQWidget* s, const TQPoint& p )
#else
KWin::setType( winId(), d->windowType );
#endif // BORDERLESS_WINDOW
-#endif // Q_WS_X11
+#endif // TQ_WS_X11
#endif
}
@@ -840,11 +840,11 @@ void KDockWidget::applyToWidget( TQWidget* s, const TQPoint& p )
void KDockWidget::show()
{
- if ( parent() || manager->main->isVisible() )
- if ( !parent() ){
+ if ( tqparent() || manager->main->isVisible() )
+ if ( !tqparent() ){
emit manager->setDockDefaultPos( this );
emit setDockDefaultPos();
- if ( parent() ){
+ if ( tqparent() ){
makeDockVisible();
} else {
TQWidget::show();
@@ -859,16 +859,16 @@ void KDockWidget::show()
void KDockWidget::setDockWindowType (NET::WindowType windowType)
{
d->windowType = windowType;
- applyToWidget( parentWidget(), TQPoint(0,0) );
+ applyToWidget( tqparentWidget(), TQPoint(0,0) );
}
#endif
-void KDockWidget::setDockWindowTransient (TQWidget *parent, bool transientEnabled)
+void KDockWidget::setDockWindowTransient (TQWidget *tqparent, bool transientEnabled)
{
- d->_parent = parent;
+ d->_parent = tqparent;
d->transient = transientEnabled;
- applyToWidget( parentWidget(), TQPoint(0,0) );
+ applyToWidget( tqparentWidget(), TQPoint(0,0) );
}
TQWidget *KDockWidget::transientTo() {
@@ -899,13 +899,13 @@ bool KDockWidget::event( TQEvent *event )
emit manager->change();
break;
case TQEvent::CaptionChange:
- if ( parentWidget() ){
- if ( parent()->inherits("KDockSplitter") ){
- ((KDockSplitter*)(parent()))->updateName();
+ if ( tqparentWidget() ){
+ if ( tqparent()->inherits("KDockSplitter") ){
+ ((KDockSplitter*)(tqparent()))->updateName();
}
- if ( parentDockTabGroup() ){
- setDockTabName( parentDockTabGroup() );
- parentDockTabGroup()->setTabLabel( this, tabPageLabel() );
+ if ( tqparentDockTabGroup() ){
+ setDockTabName( tqparentDockTabGroup() );
+ tqparentDockTabGroup()->setTabLabel( this, tabPageLabel() );
}
}
break;
@@ -920,18 +920,18 @@ bool KDockWidget::event( TQEvent *event )
KDockWidget *KDockWidget::findNearestDockWidget(DockPosition pos)
{
- if (!parent()) return 0;
- if (!parent()->inherits("KDockSplitter")) return 0;
- Orientation orientation=((pos==DockLeft) || (pos==DockRight)) ? Vertical:Horizontal;
- if (((KDockSplitter*)(parent()))->orientation()==orientation)
+ if (!tqparent()) return 0;
+ if (!tqparent()->inherits("KDockSplitter")) return 0;
+ Qt::Orientation orientation=((pos==DockLeft) || (pos==DockRight)) ?Qt::Vertical:Qt::Horizontal;
+ if (((KDockSplitter*)(tqparent()))->orientation()==orientation)
{
KDockWidget *neighbor=
((pos==DockLeft)||(pos==DockTop))?
- static_cast<KDockWidget*>(((KDockSplitter*)(parent()))->getFirst()):
- static_cast<KDockWidget*>(((KDockSplitter*)(parent()))->getLast());
+ static_cast<KDockWidget*>(((KDockSplitter*)(tqparent()))->getFirst()):
+ static_cast<KDockWidget*>(((KDockSplitter*)(tqparent()))->getLast());
if (neighbor==this)
- return (static_cast<KDockWidget*>(parent()->parent())->findNearestDockWidget(pos));
+ return (static_cast<KDockWidget*>(TQT_TQWIDGET(tqparent()->tqparent()))->findNearestDockWidget(pos));
else
if (neighbor->getWidget() && (neighbor->getWidget()->qt_cast("KDockTabGroup")))
return (KDockWidget*)(((KDockTabGroup*)neighbor->getWidget())->page(0));
@@ -939,7 +939,7 @@ KDockWidget *KDockWidget::findNearestDockWidget(DockPosition pos)
return neighbor;
}
else
- return (static_cast<KDockWidget*>(parent()->parent())->findNearestDockWidget(pos));
+ return (static_cast<KDockWidget*>(TQT_TQWIDGET(tqparent()->tqparent()))->findNearestDockWidget(pos));
return 0;
}
@@ -983,10 +983,10 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
// kdDebug(282)<<"KDockWidget::manualDock(): success = false (2)"<<endl;
}
- if ( parent() && !parent()->inherits("KDockSplitter") && !parentDockTabGroup() &&
- !(dynamic_cast<KDockContainer*>(parent())) && !parentDockContainer()){
+ if ( tqparent() && !tqparent()->inherits("KDockSplitter") && !tqparentDockTabGroup() &&
+ !(dynamic_cast<KDockContainer*>(tqparent())) && !tqparentDockContainer()){
// kdDebug(282)<<"KDockWidget::manualDock(): success = false (3)"<<endl;
-// kdDebug(282)<<parent()->name()<<endl;
+// kdDebug(282)<<tqparent()->name()<<endl;
succes = false;
}
@@ -1021,28 +1021,28 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
}
// kdDebug(282)<<"Looking for KDockTabGroup"<<endl;
- KDockTabGroup* parentTab = target->parentDockTabGroup();
- if ( parentTab ){
+ KDockTabGroup* tqparentTab = target->tqparentDockTabGroup();
+ if ( tqparentTab ){
// add to existing TabGroup
- applyToWidget( parentTab );
- parentTab->insertTab( this, icon() ? *icon() : TQPixmap(),
+ applyToWidget( tqparentTab );
+ tqparentTab->insertTab( this, icon() ? *icon() : TQPixmap(),
tabPageLabel(), tabIndex );
- TQWidget *wantTransient=parentTab->transientTo();
+ TQWidget *wantTransient=tqparentTab->transientTo();
target->setDockWindowTransient(wantTransient,wantTransient);
- setDockTabName( parentTab );
+ setDockTabName( tqparentTab );
if( !toolTipStr.isEmpty())
- parentTab->setTabToolTip( this, toolTipStr);
+ tqparentTab->setTabToolTip( this, toolTipStr);
currentDockPos = KDockWidget::DockCenter;
emit manager->change();
- return (KDockWidget*)parentTab->parent();
+ return (KDockWidget*)tqparentTab->tqparent();
}
else
{
// kdDebug(282)<<"Looking for KDockContainer"<<endl;
- TQWidget *contWid=target->parentDockContainer();
+ TQWidget *contWid=target->tqparentDockContainer();
if (!contWid) contWid=target->widget;
if (contWid)
{
@@ -1060,21 +1060,21 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
cont->insertWidget( this, icon() ? *icon() : TQPixmap(),
tabPageLabel(), tabIndex );
setLatestKDockContainer(contWid);
-// setDockTabName( parentTab );
+// setDockTabName( tqparentTab );
if( !toolTipStr.isEmpty())
cont->setToolTip( this, toolTipStr);
currentDockPos = KDockWidget::DockCenter;
emit manager->change();
- return (KDockWidget*)(cont->parentDockWidget());
+ return (KDockWidget*)(cont->tqparentDockWidget());
}
}
}
// create a new dockwidget that will contain the target and this
- TQWidget* parentDock = target->parentWidget();
- KDockWidget* newDock = new KDockWidget( manager, "tempName", TQPixmap(""), parentDock );
+ TQWidget* tqparentDock = target->tqparentWidget();
+ KDockWidget* newDock = new KDockWidget( manager, "tempName", TQPixmap(TQString("")), tqparentDock );
newDock->currentDockPos = target->currentDockPos;
if ( dockPos == KDockWidget::DockCenter ){
@@ -1084,12 +1084,12 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
}
newDock->eDocking = (target->eDocking & eDocking) & (~(int)KDockWidget::DockCenter);
- newDock->applyToWidget( parentDock );
+ newDock->applyToWidget( tqparentDock );
- if ( !parentDock ){
+ if ( !tqparentDock ){
// dock to a toplevel dockwidget means newDock is toplevel now
newDock->move( target->frameGeometry().topLeft() );
- newDock->resize( target->geometry().size() );
+ newDock->resize( target->tqgeometry().size() );
if ( target->isVisibleToTLW() ) newDock->show();
}
@@ -1124,7 +1124,7 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
tab->insertTab( this, icon() ? *icon() : TQPixmap(),
tabPageLabel(), tabIndex );
- TQRect geom=newDock->geometry();
+ TQRect geom=newDock->tqgeometry();
TQWidget *wantTransient=tab->transientTo();
newDock->setDockWindowTransient(wantTransient,wantTransient);
newDock->setGeometry(geom);
@@ -1143,13 +1143,13 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
// if to dock not to the center of the target dockwidget,
// dock to newDock
KDockSplitter* panner = 0L;
- if ( dockPos == KDockWidget::DockTop || dockPos == KDockWidget::DockBottom ) panner = new KDockSplitter( newDock, "_dock_split_", Horizontal, spliPos, manager->splitterHighResolution() );
- if ( dockPos == KDockWidget::DockLeft || dockPos == KDockWidget::DockRight ) panner = new KDockSplitter( newDock, "_dock_split_", Vertical , spliPos, manager->splitterHighResolution() );
+ if ( dockPos == KDockWidget::DockTop || dockPos == KDockWidget::DockBottom ) panner = new KDockSplitter( newDock, "_dock_split_",Qt::Horizontal, spliPos, manager->splitterHighResolution() );
+ if ( dockPos == KDockWidget::DockLeft || dockPos == KDockWidget::DockRight ) panner = new KDockSplitter( newDock, "_dock_split_",Qt::Vertical , spliPos, manager->splitterHighResolution() );
newDock->setWidget( panner );
panner->setOpaqueResize(manager->splitterOpaqueResize());
panner->setKeepSize(manager->splitterKeepSize());
- panner->setFocusPolicy( NoFocus );
+ panner->setFocusPolicy( TQ_NoFocus );
target->applyToWidget( panner );
applyToWidget( panner );
target->formerDockPos = target->currentDockPos;
@@ -1178,9 +1178,9 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
panner->show();
}
- if ( parentDock ){
- if ( parentDock->inherits("KDockSplitter") ){
- KDockSplitter* sp = (KDockSplitter*)parentDock;
+ if ( tqparentDock ){
+ if ( tqparentDock->inherits("KDockSplitter") ){
+ KDockSplitter* sp = (KDockSplitter*)tqparentDock;
sp->deactivate();
if ( sp->getFirst() == target )
sp->activate( newDock, 0L );
@@ -1197,18 +1197,18 @@ KDockWidget* KDockWidget::manualDock( KDockWidget* target, DockPosition dockPos,
return newDock;
}
-KDockTabGroup* KDockWidget::parentDockTabGroup() const
+KDockTabGroup* KDockWidget::tqparentDockTabGroup() const
{
- if ( !parent() ) return 0L;
- TQWidget* candidate = parentWidget()->parentWidget();
+ if ( !tqparent() ) return 0L;
+ TQWidget* candidate = tqparentWidget()->tqparentWidget();
if ( candidate && candidate->inherits("KDockTabGroup") ) return (KDockTabGroup*)candidate;
return 0L;
}
-TQWidget *KDockWidget::parentDockContainer() const
+TQWidget *KDockWidget::tqparentDockContainer() const
{
- if (!parent()) return 0L;
- TQWidget* candidate = parentWidget()->parentWidget();
+ if (!tqparent()) return 0L;
+ TQWidget* candidate = tqparentWidget()->tqparentWidget();
if (candidate && dynamic_cast<KDockContainer*>(candidate)) return candidate;
return 0L;
}
@@ -1218,18 +1218,18 @@ void KDockWidget::setForcedFixedWidth(int w)
{
d->forcedWidth=w;
setFixedWidth(w);
- if (!parent()) return;
- if (parent()->inherits("KDockSplitter"))
- static_cast<KDockSplitter*>(parent()->qt_cast("KDockSplitter"))->setForcedFixedWidth(this,w);
+ if (!tqparent()) return;
+ if (tqparent()->inherits("KDockSplitter"))
+ static_cast<KDockSplitter*>(tqparent()->qt_cast("KDockSplitter"))->setForcedFixedWidth(this,w);
}
void KDockWidget::setForcedFixedHeight(int h)
{
d->forcedHeight=h;
setFixedHeight(h);
- if (!parent()) return;
- if (parent()->inherits("KDockSplitter"))
- static_cast<KDockSplitter*>(parent()->qt_cast("KDockSplitter"))->setForcedFixedHeight(this,h);
+ if (!tqparent()) return;
+ if (tqparent()->inherits("KDockSplitter"))
+ static_cast<KDockSplitter*>(tqparent()->qt_cast("KDockSplitter"))->setForcedFixedHeight(this,h);
}
int KDockWidget::forcedFixedWidth()
@@ -1249,9 +1249,9 @@ void KDockWidget::restoreFromForcedFixedSize()
setMaximumWidth(32000);
setMinimumHeight(0);
setMaximumHeight(32000);
- if (!parent()) return;
- if (parent()->inherits("KDockSplitter"))
- static_cast<KDockSplitter*>(parent()->qt_cast("KDockSplitter"))->restoreFromForcedFixedSize(this);
+ if (!tqparent()) return;
+ if (tqparent()->inherits("KDockSplitter"))
+ static_cast<KDockSplitter*>(tqparent()->qt_cast("KDockSplitter"))->restoreFromForcedFixedSize(this);
}
void KDockWidget::toDesktop()
@@ -1276,8 +1276,8 @@ void KDockWidget::undock()
manager->d->dragRect = TQRect ();
manager->drawDragRectangle ();
- TQWidget* parentW = parentWidget();
- if ( !parentW ){
+ TQWidget* tqparentW = tqparentWidget();
+ if ( !tqparentW ){
hide();
if (!d->blockHasUndockedSignal)
emit hasUndocked();
@@ -1290,74 +1290,74 @@ void KDockWidget::undock()
manager->blockSignals(true);
manager->undockProcess = true;
- bool isV = parentW->isVisibleToTLW();
+ bool isV = tqparentW->isVisibleToTLW();
//UNDOCK HAS TO BE IMPLEMENTED CORRECTLY :)
- KDockTabGroup* parentTab = parentDockTabGroup();
- if ( parentTab ){
- d->index = parentTab->indexOf( this); // memorize the page position in the tab widget
- parentTab->removePage( this );
+ KDockTabGroup* tqparentTab = tqparentDockTabGroup();
+ if ( tqparentTab ){
+ d->index = tqparentTab->indexOf( this); // memorize the page position in the tab widget
+ tqparentTab->removePage( this );
/*
- TQWidget *wantTransient=parentTab->transientTo();
+ TQWidget *wantTransient=tqparentTab->transientTo();
target->setDockWindowTransient(wantTransient,wantTransient);
*/
- setFormerBrotherDockWidget((KDockWidget*)parentTab->page(0));
+ setFormerBrotherDockWidget((KDockWidget*)tqparentTab->page(0));
applyToWidget( 0L );
- if ( parentTab->count() == 1 ){
+ if ( tqparentTab->count() == 1 ){
// last subdock widget in the tab control
- KDockWidget* lastTab = (KDockWidget*)parentTab->page(0);
- parentTab->removePage( lastTab );
-/* TQWidget *wantTransient=parentTab->transientTo();
+ KDockWidget* lastTab = (KDockWidget*)tqparentTab->page(0);
+ tqparentTab->removePage( lastTab );
+/* TQWidget *wantTransient=tqparentTab->transientTo();
target->setDockWindowTransient(wantTransient,wantTransient);*/
lastTab->applyToWidget( 0L );
- lastTab->move( parentTab->mapToGlobal(parentTab->frameGeometry().topLeft()) );
+ lastTab->move( tqparentTab->mapToGlobal(tqparentTab->frameGeometry().topLeft()) );
- // KDockTabGroup always have a parent that is a KDockWidget
- KDockWidget* parentOfTab = (KDockWidget*)parentTab->parent();
- delete parentTab; // KDockTabGroup
+ // KDockTabGroup always have a tqparent that is a KDockWidget
+ KDockWidget* tqparentOfTab = (KDockWidget*)tqparentTab->tqparent();
+ delete tqparentTab; // KDockTabGroup
- TQWidget* parentOfDockWidget = parentOfTab->parentWidget();
- if ( !parentOfDockWidget ){
+ TQWidget* tqparentOfDockWidget = tqparentOfTab->tqparentWidget();
+ if ( !tqparentOfDockWidget ){
if ( isV ) lastTab->show();
} else {
- if ( parentOfDockWidget->inherits("KDockSplitter") ){
- KDockSplitter* split = (KDockSplitter*)parentOfDockWidget;
+ if ( tqparentOfDockWidget->inherits("KDockSplitter") ){
+ KDockSplitter* split = (KDockSplitter*)tqparentOfDockWidget;
lastTab->applyToWidget( split );
split->deactivate();
- if ( split->getFirst() == parentOfTab ){
+ if ( split->getFirst() == tqparentOfTab ){
split->activate( lastTab );
- if ( ((KDockWidget*)split->parent())->splitterOrientation == Vertical )
- emit ((KDockWidget*)split->getAnother(parentOfTab))->docking( parentOfTab, KDockWidget::DockLeft );
+ if ( ((KDockWidget*)split->tqparent())->splitterOrientation ==Qt::Vertical )
+ emit ((KDockWidget*)split->getAnother(tqparentOfTab))->docking( tqparentOfTab, KDockWidget::DockLeft );
else
- emit ((KDockWidget*)split->getAnother(parentOfTab))->docking( parentOfTab, KDockWidget::DockTop );
+ emit ((KDockWidget*)split->getAnother(tqparentOfTab))->docking( tqparentOfTab, KDockWidget::DockTop );
} else {
split->activate( 0L, lastTab );
- if ( ((KDockWidget*)split->parent())->splitterOrientation == Vertical )
- emit ((KDockWidget*)split->getAnother(parentOfTab))->docking( parentOfTab, KDockWidget::DockRight );
+ if ( ((KDockWidget*)split->tqparent())->splitterOrientation ==Qt::Vertical )
+ emit ((KDockWidget*)split->getAnother(tqparentOfTab))->docking( tqparentOfTab, KDockWidget::DockRight );
else
- emit ((KDockWidget*)split->getAnother(parentOfTab))->docking( parentOfTab, KDockWidget::DockBottom );
+ emit ((KDockWidget*)split->getAnother(tqparentOfTab))->docking( tqparentOfTab, KDockWidget::DockBottom );
}
split->show();
} else {
- lastTab->applyToWidget( parentOfDockWidget );
+ lastTab->applyToWidget( tqparentOfDockWidget );
}
lastTab->show();
}
manager->blockSignals(false);
- emit manager->replaceDock( parentOfTab, lastTab );
- lastTab->currentDockPos = parentOfTab->currentDockPos;
- emit parentOfTab->iMBeingClosed();
+ emit manager->replaceDock( tqparentOfTab, lastTab );
+ lastTab->currentDockPos = tqparentOfTab->currentDockPos;
+ emit tqparentOfTab->iMBeingClosed();
manager->blockSignals(true);
- delete parentOfTab;
+ delete tqparentOfTab;
} else {
- setDockTabName( parentTab );
+ setDockTabName( tqparentTab );
}
} else {
/*********************************************************************************************/
- //TQWidget* containerWidget = (TQWidget*)parent();
+ //TQWidget* containerWidget = (TQWidget*)tqparent();
bool undockedFromContainer=false;
if (d->container)
{
@@ -1366,41 +1366,41 @@ void KDockWidget::undock()
KDockContainer* dc = dynamic_cast<KDockContainer*>(d->container.operator->());
if (dc) {
dc->undockWidget(this);
- setFormerBrotherDockWidget(dc->parentDockWidget());
+ setFormerBrotherDockWidget(dc->tqparentDockWidget());
}
applyToWidget( 0L );
}
if (!undockedFromContainer) {
/*********************************************************************************************/
- if ( parentW->inherits("KDockSplitter") ){
- KDockSplitter* parentSplitterOfDockWidget = (KDockSplitter*)parentW;
- d->splitPosInPercent = parentSplitterOfDockWidget->separatorPos();
+ if ( tqparentW->inherits("KDockSplitter") ){
+ KDockSplitter* tqparentSplitterOfDockWidget = (KDockSplitter*)tqparentW;
+ d->splitPosInPercent = tqparentSplitterOfDockWidget->separatorPos();
- KDockWidget* secondWidget = (KDockWidget*)parentSplitterOfDockWidget->getAnother( this );
- KDockWidget* group = (KDockWidget*)parentSplitterOfDockWidget->parentWidget();
+ KDockWidget* secondWidget = (KDockWidget*)tqparentSplitterOfDockWidget->getAnother( this );
+ KDockWidget* group = (KDockWidget*)tqparentSplitterOfDockWidget->tqparentWidget();
setFormerBrotherDockWidget(secondWidget);
applyToWidget( 0L );
group->hide();
- if ( !group->parentWidget() ){
+ if ( !group->tqparentWidget() ){
secondWidget->applyToWidget( 0L, group->frameGeometry().topLeft() );
secondWidget->resize( group->width(), group->height() );
} else {
- TQWidget* obj = group->parentWidget();
+ TQWidget* obj = group->tqparentWidget();
secondWidget->applyToWidget( obj );
if ( obj->inherits("KDockSplitter") ){
- KDockSplitter* parentOfGroup = (KDockSplitter*)obj;
- parentOfGroup->deactivate();
+ KDockSplitter* tqparentOfGroup = (KDockSplitter*)obj;
+ tqparentOfGroup->deactivate();
- if ( parentOfGroup->getFirst() == group )
- parentOfGroup->activate( secondWidget );
+ if ( tqparentOfGroup->getFirst() == group )
+ tqparentOfGroup->activate( secondWidget );
else
- parentOfGroup->activate( 0L, secondWidget );
+ tqparentOfGroup->activate( 0L, secondWidget );
}
}
secondWidget->currentDockPos = group->currentDockPos;
secondWidget->formerDockPos = group->formerDockPos;
- delete parentSplitterOfDockWidget;
+ delete tqparentSplitterOfDockWidget;
manager->blockSignals(false);
emit manager->replaceDock( group, secondWidget );
emit group->iMBeingClosed();
@@ -1430,7 +1430,7 @@ void KDockWidget::setWidget( TQWidget* mw )
{
if ( !mw ) return;
- if ( mw->parent() != this ){
+ if ( TQT_BASE_OBJECT(mw->tqparent()) != TQT_BASE_OBJECT(this) ){
mw->reparent(this, 0, TQPoint(0,0), false);
}
@@ -1438,16 +1438,16 @@ void KDockWidget::setWidget( TQWidget* mw )
if (!mw->ownCursor()) mw->setCursor(TQCursor(ArrowCursor));
#endif
widget = mw;
- delete layout;
+ delete tqlayout;
- layout = new TQVBoxLayout( this );
- layout->setResizeMode( TQLayout::Minimum );
+ tqlayout = new TQVBoxLayout( this );
+ tqlayout->setResizeMode( TQLayout::Minimum );
KDockContainer* dc = dynamic_cast<KDockContainer*>(widget);
if (dc)
{
d->isContainer=true;
- manager->d->containerDocks.append(this);
+ manager->d->containerDocks.append(TQT_TQOBJECT(this));
}
else
{
@@ -1456,8 +1456,8 @@ void KDockWidget::setWidget( TQWidget* mw )
{
header->show();
- layout->addWidget( header );
- layout->addWidget( widget,1 );
+ tqlayout->addWidget( header );
+ tqlayout->addWidget( widget,1 );
}
updateHeader();
emit widgetSet(mw);
@@ -1475,24 +1475,24 @@ void KDockWidget::setDockTabName( KDockTabGroup* tab )
listOfCaption.remove( listOfCaption.length()-1, 1 );
listOfName.remove( listOfName.length()-1, 1 );
- tab->parentWidget()->setName( listOfName.utf8() );
- tab->parentWidget()->setCaption( listOfCaption );
+ tab->tqparentWidget()->setName( listOfName.utf8() );
+ tab->tqparentWidget()->setCaption( listOfCaption );
- tab->parentWidget()->repaint( false ); // KDockWidget->repaint
- if ( tab->parentWidget()->parent() )
- if ( tab->parentWidget()->parent()->inherits("KDockSplitter") )
- ((KDockSplitter*)(tab->parentWidget()->parent()))->updateName();
+ tab->tqparentWidget()->tqrepaint( false ); // KDockWidget->tqrepaint
+ if ( tab->tqparentWidget()->tqparent() )
+ if ( tab->tqparentWidget()->tqparent()->inherits("KDockSplitter") )
+ ((KDockSplitter*)(tab->tqparentWidget()->tqparent()))->updateName();
}
bool KDockWidget::mayBeHide() const
{
- bool f = (parent() != manager->main);
+ bool f = (TQT_BASE_OBJECT(tqparent()) != TQT_BASE_OBJECT(manager->main));
return ( !isGroup && !isTabGroup && f && isVisible() && ( eDocking != (int)KDockWidget::DockNone ) );
}
bool KDockWidget::mayBeShow() const
{
- bool f = (parent() != manager->main);
+ bool f = (TQT_BASE_OBJECT(tqparent()) != TQT_BASE_OBJECT(manager->main));
return ( !isGroup && !isTabGroup && f && !isVisible() );
}
@@ -1514,11 +1514,11 @@ void KDockWidget::changeHideShowState()
void KDockWidget::makeDockVisible()
{
- if ( parentDockTabGroup() ){
- parentDockTabGroup()->showPage( this );
+ if ( tqparentDockTabGroup() ){
+ tqparentDockTabGroup()->showPage( this );
}
- if (parentDockContainer()) {
- TQWidget *contWid=parentDockContainer();
+ if (tqparentDockContainer()) {
+ TQWidget *contWid=tqparentDockContainer();
KDockContainer *x = dynamic_cast<KDockContainer*>(contWid);
if (x) {
x->showWidget(this);
@@ -1526,13 +1526,13 @@ void KDockWidget::makeDockVisible()
}
if ( isVisible() ) return;
- TQWidget* p = parentWidget();
+ TQWidget* p = tqparentWidget();
while ( p ){
if ( !p->isVisible() )
p->show();
- p = p->parentWidget();
+ p = p->tqparentWidget();
}
- if( !parent() ) // is undocked
+ if( !tqparent() ) // is undocked
dockBack();
show();
}
@@ -1551,13 +1551,13 @@ void KDockWidget::loseFormerBrotherDockWidget()
TQObject::disconnect( formerBrotherDockWidget, TQT_SIGNAL(iMBeingClosed()),
this, TQT_SLOT(loseFormerBrotherDockWidget()) );
formerBrotherDockWidget = 0L;
- repaint();
+ tqrepaint();
}
void KDockWidget::dockBack()
{
if( formerBrotherDockWidget) {
- // search all children if it tries to dock back to a child
+ // search all tqchildren if it tries to dock back to a child
bool found = false;
TQObjectList* cl = queryList("KDockWidget");
TQObjectListIt it( *cl );
@@ -1582,7 +1582,7 @@ void KDockWidget::dockBack()
// else dockback to the dockmainwindow (default behavior)
manualDock( ((KDockMainWindow*)manager->main)->getMainDockWidget(), formerDockPos, d->splitPosInPercent, TQPoint(0,0), false, d->index);
formerBrotherDockWidget = 0L;
- if (parent())
+ if (tqparent())
makeDockVisible();
}
@@ -1676,7 +1676,7 @@ void KDockManager::activate()
while ( (obj=(KDockWidget*)it.current()) ) {
++it;
if ( obj->widget ) obj->widget->show();
- if ( !obj->parentDockTabGroup() ){
+ if ( !obj->tqparentDockTabGroup() ){
obj->show();
}
}
@@ -1700,11 +1700,11 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
break;
case TQEvent::MouseButtonPress:
- if ( ((TQMouseEvent*)event)->button() == LeftButton ){
+ if ( ((TQMouseEvent*)event)->button() == Qt::LeftButton ){
if ( curdw->eDocking != (int)KDockWidget::DockNone ){
dropCancel = true;
curdw->setFocus();
- qApp->processOneEvent();
+ tqApp->processOneEvent();
currentDragWidget = curdw;
currentMoveWidget = 0L;
@@ -1713,7 +1713,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
findChildDockWidget( curdw, childDockWidgetList );
//d->oldDragRect = TQRect(); should fix rectangle not erased problem
- d->dragRect = TQRect(curdw->geometry());
+ d->dragRect = TQRect(curdw->tqgeometry());
TQPoint p = curdw->mapToGlobal(TQPoint(0,0));
d->dragRect.moveTopLeft(p);
drawDragRectangle();
@@ -1725,7 +1725,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
}
break;
case TQEvent::MouseButtonRelease:
- if ( ((TQMouseEvent*)event)->button() == LeftButton ){
+ if ( ((TQMouseEvent*)event)->button() == Qt::LeftButton ){
if ( dragging ){
if ( !dropCancel )
drop();
@@ -1735,7 +1735,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
if (d->readyToDrag) {
d->readyToDrag = false;
//d->oldDragRect = TQRect(); should fix rectangle not erased problem
- d->dragRect = TQRect(curdw->geometry());
+ d->dragRect = TQRect(curdw->tqgeometry());
TQPoint p = curdw->mapToGlobal(TQPoint(0,0));
d->dragRect.moveTopLeft(p);
drawDragRectangle();
@@ -1753,7 +1753,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
#ifdef BORDERLESS_WINDOWS
//BEGIN TEST
KDockWidget *oldMoveWidget;
- if (!curdw->parent())
+ if (!curdw->tqparent())
{
curdw->move(TQCursor::pos()-d->dragOffset);
pDockWdgAtCursor = findDockWidgetAt( TQCursor::pos()-TQPoint(0,d->dragOffset.y()+3) );
@@ -1775,7 +1775,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
break;
} else {
if (dropCancel && curdw) {
- d->dragRect = TQRect(curdw->geometry());
+ d->dragRect = TQRect(curdw->tqgeometry());
TQPoint p = curdw->mapToGlobal(TQPoint(0,0));
d->dragRect.moveTopLeft(p);
}else
@@ -1803,7 +1803,7 @@ bool KDockManager::eventFilter( TQObject *obj, TQEvent *event )
if (d->readyToDrag) {
d->readyToDrag = false;
}
- if ( (((TQMouseEvent*)event)->state() == LeftButton) &&
+ if ( (((TQMouseEvent*)event)->state() == Qt::LeftButton) &&
(curdw->eDocking != (int)KDockWidget::DockNone) ) {
startDrag( curdw);
}
@@ -1831,7 +1831,7 @@ KDockWidget* KDockManager::findDockWidgetAt( const TQPoint& pos )
return 0L;
}
#if defined(_OS_WIN32_) || defined(Q_OS_WIN32)
- p = p->topLevelWidget();
+ p = p->tqtopLevelWidget();
#endif
TQWidget* w = 0L;
findChildDockWidget( w, p, p->mapFromGlobal(pos) );
@@ -1841,13 +1841,13 @@ KDockWidget* KDockManager::findDockWidgetAt( const TQPoint& pos )
}
w = p;
}
- if ( qt_find_obj_child( w, "KDockSplitter", "_dock_split_" ) ) return 0L;
- if ( qt_find_obj_child( w, "KDockTabGroup", "_dock_tab" ) ) return 0L;
+ if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "KDockSplitter", "_dock_split_" ) ) return 0L;
+ if ( qt_tqfind_obj_child( TQT_TQOBJECT(w), "KDockTabGroup", "_dock_tab" ) ) return 0L;
if (dynamic_cast<KDockContainer*>(w)) return 0L;
if (!childDockWidgetList) return 0L;
- if ( childDockWidgetList->find(w) != -1 ) return 0L;
- if ( currentDragWidget->isGroup && ((KDockWidget*)w)->parentDockTabGroup() ) return 0L;
+ if ( childDockWidgetList->tqfind(w) != -1 ) return 0L;
+ if ( currentDragWidget->isGroup && ((KDockWidget*)w)->tqparentDockTabGroup() ) return 0L;
KDockWidget* www = (KDockWidget*)w;
if ( www->sDocking == (int)KDockWidget::DockNone ) return 0L;
@@ -1884,14 +1884,15 @@ KDockWidget* KDockManager::findDockWidgetAt( const TQPoint& pos )
void KDockManager::findChildDockWidget( TQWidget*& ww, const TQWidget* p, const TQPoint& pos )
{
- if ( p->children() ) {
+ TQObjectList clo = p->childrenListObject();
+ if ( !clo.isEmpty() ) {
TQWidget *w;
- TQObjectListIt it( *p->children() );
+ TQObjectListIt it( clo );
it.toLast();
while ( it.current() ) {
if ( it.current()->isWidgetType() ) {
w = (TQWidget*)it.current();
- if ( w->isVisible() && w->geometry().contains(pos) ) {
+ if ( w->isVisible() && w->tqgeometry().tqcontains(pos) ) {
if ( w->inherits("KDockWidget") ) ww = w;
findChildDockWidget( ww, w, w->mapFromParent(pos) );
return;
@@ -1905,9 +1906,10 @@ void KDockManager::findChildDockWidget( TQWidget*& ww, const TQWidget* p, const
void KDockManager::findChildDockWidget( const TQWidget* p, TQWidgetList*& list )
{
- if ( p->children() ) {
+ TQObjectList clo = p->childrenListObject();
+ if ( !clo.isEmpty() ) {
TQWidget *w;
- TQObjectListIt it( *p->children() );
+ TQObjectListIt it( clo );
it.toLast();
while ( it.current() ) {
if ( it.current()->isWidgetType() ) {
@@ -1929,9 +1931,9 @@ void KDockManager::startDrag( KDockWidget* w )
|| ( w->currentDockPos == KDockWidget::DockTop) || ( w->currentDockPos == KDockWidget::DockBottom)) {
w->prevSideDockPosBeforeDrag = w->currentDockPos;
- if ( w->parentWidget()->inherits("KDockSplitter") ){
- KDockSplitter* parentSplitterOfDockWidget = (KDockSplitter*)(w->parentWidget());
- w->d->splitPosInPercent = parentSplitterOfDockWidget->separatorPos();
+ if ( w->tqparentWidget()->inherits("KDockSplitter") ){
+ KDockSplitter* tqparentSplitterOfDockWidget = (KDockSplitter*)(w->tqparentWidget());
+ w->d->splitPosInPercent = tqparentSplitterOfDockWidget->separatorPos();
}
}
@@ -1947,7 +1949,7 @@ void KDockManager::dragMove( KDockWidget* dw, TQPoint pos )
KDockWidget::DockPosition oldPos = curPos;
TQSize r = dw->widget->size();
- if ( dw->parentDockTabGroup() ){
+ if ( dw->tqparentDockTabGroup() ){
curPos = KDockWidget::DockCenter;
if ( oldPos != curPos ) {
d->dragRect.setRect( p.x()+2, p.y()+2, r.width()-4, r.height()-4 );
@@ -2017,7 +2019,7 @@ void KDockManager::drop()
drawDragRectangle(); // only the old rect will be deleted
return;
}
- if ( !currentMoveWidget && !currentDragWidget->parent() ) {
+ if ( !currentMoveWidget && !currentDragWidget->tqparent() ) {
currentDragWidget->move( TQCursor::pos() - d->dragOffset );
}
else {
@@ -2049,7 +2051,7 @@ static TQDomElement createStringEntry(TQDomDocument &doc, const TQString &tagNam
static TQDomElement createBoolEntry(TQDomDocument &doc, const TQString &tagName, bool b)
{
- return createStringEntry(doc, tagName, TQString::fromLatin1(b? "true" : "false"));
+ return createStringEntry(doc, tagName, TQString::tqfromLatin1(b? "true" : "false"));
}
@@ -2088,7 +2090,7 @@ static TQDomElement createListEntry(TQDomDocument &doc, const TQString &tagName,
TQStrListIterator it(list);
for (; it.current(); ++it) {
TQDomElement subel = doc.createElement(subTagName);
- subel.appendChild(doc.createTextNode(TQString::fromLatin1(it.current())));
+ subel.appendChild(doc.createTextNode(TQString::tqfromLatin1(it.current())));
el.appendChild(subel);
}
@@ -2157,8 +2159,8 @@ void KDockManager::writeConfig(TQDomElement &base)
TQObjectListIt it(*childDock);
KDockWidget *obj1;
while ( (obj1=(KDockWidget*)it.current()) ) {
- if ( obj1->parent() == main )
- mainWidgetStr = TQString::fromLatin1(obj1->name());
+ if ( TQT_BASE_OBJECT(obj1->tqparent()) == TQT_BASE_OBJECT(main) )
+ mainWidgetStr = TQString::tqfromLatin1(obj1->name());
nList.append(obj1->name());
++it;
}
@@ -2174,9 +2176,9 @@ void KDockManager::writeConfig(TQDomElement &base)
TQStringList::Iterator nListIt=nList.begin();
while ( nListIt!=nList.end() ) {
KDockWidget *obj = getDockWidgetFromName( *nListIt);
- if ((obj->isGroup && (!obj->d->isContainer)) && (nameList.find( obj->firstName.latin1() ) == -1
- || nameList.find(obj->lastName.latin1()) == -1)) {
- // Skip until children are saved (why?)
+ if ((obj->isGroup && (!obj->d->isContainer)) && (nameList.tqfind( obj->firstName.latin1() ) == -1
+ || nameList.tqfind(obj->lastName.latin1()) == -1)) {
+ // Skip until tqchildren are saved (why?)
++nListIt;
// nList.next();
//falk? if ( !nList.current() ) nList.first();
@@ -2208,7 +2210,7 @@ void KDockManager::writeConfig(TQDomElement &base)
list.append( ((KDockTabGroup*)obj->widget)->page( i )->name() );
groupEl.appendChild(createListEntry(doc, "tabs", "tab", list));
groupEl.appendChild(createNumberEntry(doc, "currentTab", ((KDockTabGroup*)obj->widget)->currentPageIndex()));
- if (!obj->parent()) {
+ if (!obj->tqparent()) {
groupEl.appendChild(createStringEntry(doc, "dockBackTo", obj->formerBrotherDockWidget ? obj->formerBrotherDockWidget->name() : ""));
groupEl.appendChild(createNumberEntry(doc, "dockBackToPos", obj->formerDockPos));
}
@@ -2217,15 +2219,15 @@ void KDockManager::writeConfig(TQDomElement &base)
groupEl = doc.createElement("dock");
groupEl.appendChild(createStringEntry(doc, "tabCaption", obj->tabPageLabel()));
groupEl.appendChild(createStringEntry(doc, "tabToolTip", obj->toolTipString()));
- if (!obj->parent()) {
+ if (!obj->tqparent()) {
groupEl.appendChild(createStringEntry(doc, "dockBackTo", obj->formerBrotherDockWidget ? obj->formerBrotherDockWidget->name() : ""));
groupEl.appendChild(createNumberEntry(doc, "dockBackToPos", obj->formerDockPos));
}
}
- groupEl.appendChild(createStringEntry(doc, "name", TQString::fromLatin1(obj->name())));
- groupEl.appendChild(createBoolEntry(doc, "hasParent", obj->parent()));
- if ( !obj->parent() ) {
+ groupEl.appendChild(createStringEntry(doc, "name", TQString::tqfromLatin1(obj->name())));
+ groupEl.appendChild(createBoolEntry(doc, "hasParent", obj->tqparent()));
+ if ( !obj->tqparent() ) {
groupEl.appendChild(createRectEntry(doc, "geometry", TQRect(main->frameGeometry().topLeft(), main->size())));
groupEl.appendChild(createBoolEntry(doc, "visible", obj->isVisible()));
}
@@ -2274,7 +2276,7 @@ void KDockManager::readConfig(TQDomElement &base)
KDockWidget *obj1;
while ( (obj1=(KDockWidget*)it.current()) ) {
if ( !obj1->isGroup && !obj1->isTabGroup ) {
- if ( obj1->parent() )
+ if ( obj1->tqparent() )
obj1->undock();
else
obj1->hide();
@@ -2345,7 +2347,7 @@ void KDockManager::readConfig(TQDomElement &base)
KDockWidget *second = getDockWidgetFromName(secondName);
if (first && second) {
obj = first->manualDock(second,
- (orientation == (int)Vertical)? KDockWidget::DockLeft : KDockWidget::DockTop,
+ (orientation == (int)Qt::Vertical)? KDockWidget::DockLeft : KDockWidget::DockTop,
separatorPos);
if (obj)
obj->setName(name.latin1());
@@ -2456,7 +2458,7 @@ void KDockManager::removeFromAutoCreateList(KDockWidget* pDockWidget)
{
if (!autoCreateDock) return;
autoCreateDock->setAutoDelete(false);
- autoCreateDock->removeRef(pDockWidget);
+ autoCreateDock->removeRef(TQT_TQOBJECT(pDockWidget));
autoCreateDock->setAutoDelete(true);
}
@@ -2492,11 +2494,11 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
++it;
//debug(" +Add subdock %s", obj->name());
nList.append( obj->name() );
- if ( obj->parent() == main )
+ if ( TQT_BASE_OBJECT(obj->tqparent()) == TQT_BASE_OBJECT(main) )
c->writeEntry( "Main:view", obj->name() );
}
-// kdDebug(282)<<TQString("list size: %1").arg(nList.count())<<endl;
+// kdDebug(282)<<TQString("list size: %1").tqarg(nList.count())<<endl;
for (TQObjectListIt it(d->containerDocks);it.current();++it)
{
KDockContainer* dc = dynamic_cast<KDockContainer*>(((KDockWidget*)it.current())->widget);
@@ -2504,7 +2506,7 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
dc->prepareSave(nList);
}
}
-// kdDebug(282)<<TQString("new list size: %1").arg(nList.count())<<endl;
+// kdDebug(282)<<TQString("new list size: %1").tqarg(nList.count())<<endl;
TQStringList::Iterator nListIt=nList.begin();
while ( nListIt!=nList.end() ){
@@ -2522,15 +2524,15 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
}
/*************************************************************************************************/
if ( obj->isGroup ){
- if ( (findList.find( obj->firstName ) != findList.end()) && (findList.find( obj->lastName ) != findList.end() )){
+ if ( (findList.tqfind( obj->firstName ) != findList.end()) && (findList.tqfind( obj->lastName ) != findList.end() )){
c->writeEntry( cname+":type", "GROUP");
- if ( !obj->parent() ){
- c->writeEntry( cname+":parent", "___null___");
- c->writeEntry( cname+":geometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
+ if ( !obj->tqparent() ){
+ c->writeEntry( cname+":tqparent", "___null___");
+ c->writeEntry( cname+":tqgeometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
c->writeEntry( cname+":visible", obj->isVisible());
} else {
- c->writeEntry( cname+":parent", "yes");
+ c->writeEntry( cname+":tqparent", "yes");
}
c->writeEntry( cname+":first_name", obj->firstName );
c->writeEntry( cname+":last_name", obj->lastName );
@@ -2545,9 +2547,9 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
} else {
/*************************************************************************************************/
//debug(" Skip %s", nList.current());
- //if ( findList.find( obj->firstName ) == -1 )
+ //if ( findList.tqfind( obj->firstName ) == -1 )
// debug(" ? Not found %s", obj->firstName);
- //if ( findList.find( obj->lastName ) == -1 )
+ //if ( findList.tqfind( obj->lastName ) == -1 )
// debug(" ? Not found %s", obj->lastName);
++nListIt;
// if ( !nList.current() ) nList.first();
@@ -2557,14 +2559,14 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
/*************************************************************************************************/
if ( obj->isTabGroup){
c->writeEntry( cname+":type", "TAB_GROUP");
- if ( !obj->parent() ){
- c->writeEntry( cname+":parent", "___null___");
- c->writeEntry( cname+":geometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
+ if ( !obj->tqparent() ){
+ c->writeEntry( cname+":tqparent", "___null___");
+ c->writeEntry( cname+":tqgeometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
c->writeEntry( cname+":visible", obj->isVisible());
c->writeEntry( cname+":dockBackTo", obj->formerBrotherDockWidget ? obj->formerBrotherDockWidget->name() : "");
c->writeEntry( cname+":dockBackToPos", obj->formerDockPos);
} else {
- c->writeEntry( cname+":parent", "yes");
+ c->writeEntry( cname+":tqparent", "yes");
}
TQStrList list;
for ( int i = 0; i < ((KDockTabGroup*)obj->widget)->count(); ++i )
@@ -2581,9 +2583,9 @@ void KDockManager::writeConfig( KConfig* c, TQString group )
/*************************************************************************************************/
c->writeEntry( cname+":tabCaption", obj->tabPageLabel());
c->writeEntry( cname+":tabToolTip", obj->toolTipString());
- if ( !obj->parent() ){
+ if ( !obj->tqparent() ){
c->writeEntry( cname+":type", "NULL_DOCK");
- c->writeEntry( cname+":geometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
+ c->writeEntry( cname+":tqgeometry", TQRect(obj->frameGeometry().topLeft(), obj->size()) );
c->writeEntry( cname+":visible", obj->isVisible());
c->writeEntry( cname+":dockBackTo", obj->formerBrotherDockWidget ? obj->formerBrotherDockWidget->name() : "");
c->writeEntry( cname+":dockBackToPos", obj->formerDockPos);
@@ -2644,7 +2646,7 @@ void KDockManager::readConfig( KConfig* c, TQString group )
++it;
if ( !obj->isGroup && !obj->isTabGroup )
{
- if ( obj->parent() ) obj->undock(); else obj->hide();
+ if ( obj->tqparent() ) obj->undock(); else obj->hide();
}
}
@@ -2657,8 +2659,8 @@ void KDockManager::readConfig( KConfig* c, TQString group )
TQString type = c->readEntry( oname + ":type" );
obj = 0L;
- if ( type == "NULL_DOCK" || c->readEntry( oname + ":parent") == "___null___" ){
- TQRect r = c->readRectEntry( oname + ":geometry" );
+ if ( type == "NULL_DOCK" || c->readEntry( oname + ":tqparent") == "___null___" ){
+ TQRect r = c->readRectEntry( oname + ":tqgeometry" );
obj = getDockWidgetFromName( oname );
obj->applyToWidget( 0L );
obj->setGeometry(r);
@@ -2700,9 +2702,9 @@ void KDockManager::readConfig( KConfig* c, TQString group )
KDockWidget* last = getDockWidgetFromName( c->readEntry( oname + ":last_name" ) );
int sepPos = c->readNumEntry( oname + ":sepPos" );
- Orientation p = (Orientation)c->readNumEntry( oname + ":orientation" );
+ Qt::Orientation p = (Qt::Orientation)c->readNumEntry( oname + ":orientation" );
if ( first && last ){
- obj = first->manualDock( last, ( p == Vertical ) ? KDockWidget::DockLeft : KDockWidget::DockTop, sepPos );
+ obj = first->manualDock( last, ( p ==Qt::Vertical ) ? KDockWidget::DockLeft : KDockWidget::DockTop, sepPos );
if (obj){
obj->setName( oname.latin1() );
}
@@ -2751,7 +2753,7 @@ void KDockManager::readConfig( KConfig* c, TQString group )
TQString type = c->readEntry( oname + ":type" );
obj = 0L;
- if ( type == "NULL_DOCK" || c->readEntry( oname + ":parent") == "___null___" ){
+ if ( type == "NULL_DOCK" || c->readEntry( oname + ":tqparent") == "___null___" ){
obj = getDockWidgetFromName( oname );
c->setGroup( group );
TQString name = c->readEntry( oname + ":dockBackTo" );
@@ -2828,8 +2830,8 @@ KDockWidget* KDockManager::getDockWidgetFromName( const TQString& dockName )
KDockWidget* autoCreate = 0L;
if ( autoCreateDock ){
kdDebug(282)<<"Autocreating dock: "<<dockName<<endl;
- autoCreate = new KDockWidget( this, dockName.latin1(), TQPixmap("") );
- autoCreateDock->append( autoCreate );
+ autoCreate = new KDockWidget( this, dockName.latin1(), TQPixmap(TQString("")) );
+ autoCreateDock->append( TQT_TQOBJECT(autoCreate) );
}
return autoCreate;
}
@@ -2875,13 +2877,13 @@ void KDockManager::slotMenuPopup()
++it;
if ( obj->mayBeHide() )
{
- menu->insertItem( obj->icon() ? *(obj->icon()) : TQPixmap(), i18n("Hide %1").arg(obj->caption()), numerator++ );
+ menu->insertItem( obj->icon() ? *(obj->icon()) : TQPixmap(), i18n("Hide %1").tqarg(obj->caption()), numerator++ );
menuData->append( new MenuDockData( obj, true ) );
}
if ( obj->mayBeShow() )
{
- menu->insertItem( obj->icon() ? *(obj->icon()) : TQPixmap(), i18n("Show %1").arg(obj->caption()), numerator++ );
+ menu->insertItem( obj->icon() ? *(obj->icon()) : TQPixmap(), i18n("Show %1").tqarg(obj->caption()), numerator++ );
menuData->append( new MenuDockData( obj, false ) );
}
}
@@ -2933,14 +2935,14 @@ void KDockManager::drawDragRectangle()
KDockMainWindow* pMain = 0L;
KDockWidget* pTLDockWdg = 0L;
TQWidget* topWdg;
- if (pDockWdgAtRect->topLevelWidget() == main) {
+ if (pDockWdgAtRect->tqtopLevelWidget() == main) {
isOverMainWdg = true;
topWdg = pMain = (KDockMainWindow*) main;
unclipped = pMain->testWFlags( WPaintUnclipped );
pMain->setWFlags( WPaintUnclipped );
}
else {
- topWdg = pTLDockWdg = (KDockWidget*) pDockWdgAtRect->topLevelWidget();
+ topWdg = pTLDockWdg = (KDockWidget*) pDockWdgAtRect->tqtopLevelWidget();
unclipped = pTLDockWdg->testWFlags( WPaintUnclipped );
pTLDockWdg->setWFlags( WPaintUnclipped );
}
@@ -2955,7 +2957,7 @@ void KDockManager::drawDragRectangle()
pTLDockWdg->clearWFlags(WPaintUnclipped);
}
// draw the rectangle
- p.setRasterOp(Qt::NotXorROP);
+ p.setRasterOp(TQt::NotXorROP);
TQRect r = oldAndNewDragRect[i];
r.moveTopLeft( r.topLeft() - topWdg->mapToGlobal(TQPoint(0,0)) );
p.drawRect(r.x(), r.y(), r.width(), r.height());
@@ -2984,8 +2986,8 @@ void KDockManager::setSpecialBottomDockContainer(KDockWidget* container) {
}
-KDockArea::KDockArea( TQWidget* parent, const char *name)
-:TQWidget( parent, name)
+KDockArea::KDockArea( TQWidget* tqparent, const char *name)
+:TQWidget( tqparent, name)
{
TQString new_name = TQString(name) + TQString("_DockManager");
dockManager = new KDockManager( this, new_name.latin1() );
@@ -2997,9 +2999,9 @@ KDockArea::~KDockArea()
delete dockManager;
}
-KDockWidget* KDockArea::createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* parent, const TQString& strCaption, const TQString& strTabPageLabel)
+KDockWidget* KDockArea::createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* tqparent, const TQString& strCaption, const TQString& strTabPageLabel)
{
- return new KDockWidget( dockManager, name.latin1(), pixmap, parent, strCaption, strTabPageLabel );
+ return new KDockWidget( dockManager, name.latin1(), pixmap, tqparent, strCaption, strTabPageLabel );
}
void KDockArea::makeDockVisible( KDockWidget* dock )
@@ -3040,7 +3042,7 @@ void KDockArea::slotDockWidgetUndocked()
void KDockArea::resizeEvent(TQResizeEvent *rsize)
{
TQWidget::resizeEvent(rsize);
- if (children()){
+ if (!childrenListObject().isEmpty()){
#ifndef NO_KDE2
// kdDebug(282)<<"KDockArea::resize"<<endl;
#endif
@@ -3057,11 +3059,11 @@ void KDockArea::resizeEvent(TQResizeEvent *rsize)
delete list;
#if 0
KDockSplitter *split;
-// for (unsigned int i=0;i<children()->count();i++)
+// for (unsigned int i=0;i<tqchildren()->count();i++)
{
-// TQPtrList<TQObject> list(children());
-// TQObject *obj=((TQPtrList<TQObject*>)children())->at(i);
- TQObject *obj=children()->getFirst();
+// TQPtrList<TQObject> list(tqchildren());
+// TQObject *obj=((TQPtrList<TQObject*>)tqchildren())->at(i);
+ TQObject *obj=tqchildren()->getFirst();
if (split = dynamic_cast<KDockSplitter*>(obj))
{
split->setGeometry( TQRect(TQPoint(0,0), size() ));
@@ -3094,12 +3096,12 @@ void KDockArea::setMainDockWidget( KDockWidget* mdw )
// KDOCKCONTAINER - AN ABSTRACTION OF THE KDOCKTABWIDGET
-KDockContainer::KDockContainer(){m_overlapMode=false; m_childrenListBegin=0; m_childrenListEnd=0;}
+KDockContainer::KDockContainer(){m_overlapMode=false; m_tqchildrenListBegin=0; m_tqchildrenListEnd=0;}
KDockContainer::~KDockContainer(){
- if (m_childrenListBegin)
+ if (m_tqchildrenListBegin)
{
- struct ListItem *tmp=m_childrenListBegin;
+ struct ListItem *tmp=m_tqchildrenListBegin;
while (tmp)
{
struct ListItem *tmp2=tmp->next;
@@ -3107,8 +3109,8 @@ KDockContainer::~KDockContainer(){
delete tmp;
tmp=tmp2;
}
- m_childrenListBegin=0;
- m_childrenListEnd=0;
+ m_tqchildrenListBegin=0;
+ m_tqchildrenListEnd=0;
}
}
@@ -3116,11 +3118,11 @@ KDockContainer::~KDockContainer(){
void KDockContainer::activateOverlapMode(int nonOverlapSize) {
m_nonOverlapSize=nonOverlapSize;
m_overlapMode=true;
- if (parentDockWidget()) {
- if (parentDockWidget()->parent()) {
+ if (tqparentDockWidget()) {
+ if (tqparentDockWidget()->tqparent()) {
kdDebug(282)<<"KDockContainer::activateOverlapMode: recalculating sizes"<<endl;
- KDockSplitter *sp= static_cast<KDockSplitter*>(parentDockWidget()->
- parent()->qt_cast("KDockSplitter"));
+ KDockSplitter *sp= static_cast<KDockSplitter*>(tqparentDockWidget()->
+ tqparent()->qt_cast("KDockSplitter"));
if (sp) sp->resizeEvent(0);
}
}
@@ -3129,11 +3131,11 @@ void KDockContainer::activateOverlapMode(int nonOverlapSize) {
void KDockContainer::deactivateOverlapMode() {
if (!m_overlapMode) return;
m_overlapMode=false;
- if (parentDockWidget()) {
- if (parentDockWidget()->parent()) {
+ if (tqparentDockWidget()) {
+ if (tqparentDockWidget()->tqparent()) {
kdDebug(282)<<"KDockContainer::deactivateOverlapMode: recalculating sizes"<<endl;
- KDockSplitter *sp= static_cast<KDockSplitter*>(parentDockWidget()->
- parent()->qt_cast("KDockSplitter"));
+ KDockSplitter *sp= static_cast<KDockSplitter*>(tqparentDockWidget()->
+ tqparent()->qt_cast("KDockSplitter"));
if (sp) sp->resizeEvent(0);
}
}
@@ -3150,11 +3152,11 @@ bool KDockContainer::dockDragMove(KDockWidget*, TQMouseEvent *) { return false;}
bool KDockContainer::dockDragLeave(KDockWidget*, TQMouseEvent *) { return false;}
-KDockWidget *KDockContainer::parentDockWidget(){return 0;}
+KDockWidget *KDockContainer::tqparentDockWidget(){return 0;}
TQStringList KDockContainer::containedWidgets() const {
TQStringList tmp;
- for (struct ListItem *it=m_childrenListBegin;it;it=it->next) {
+ for (struct ListItem *it=m_tqchildrenListBegin;it;it=it->next) {
tmp<<TQString(it->data);
}
@@ -3170,36 +3172,36 @@ void KDockContainer::insertWidget (KDockWidget *dw, TQPixmap, const TQString &,
it->data=strdup(dw->name());
it->next=0;
- if (m_childrenListEnd)
+ if (m_tqchildrenListEnd)
{
- m_childrenListEnd->next=it;
- it->prev=m_childrenListEnd;
- m_childrenListEnd=it;
+ m_tqchildrenListEnd->next=it;
+ it->prev=m_tqchildrenListEnd;
+ m_tqchildrenListEnd=it;
}
else
{
it->prev=0;
- m_childrenListEnd=it;
- m_childrenListBegin=it;
+ m_tqchildrenListEnd=it;
+ m_tqchildrenListBegin=it;
}
}
void KDockContainer::removeWidget (KDockWidget *dw){
- for (struct ListItem *tmp=m_childrenListBegin;tmp;tmp=tmp->next)
+ for (struct ListItem *tmp=m_tqchildrenListBegin;tmp;tmp=tmp->next)
{
if (!strcmp(tmp->data,dw->name()))
{
free(tmp->data);
if (tmp->next) tmp->next->prev=tmp->prev;
if (tmp->prev) tmp->prev->next=tmp->next;
- if (tmp==m_childrenListBegin) m_childrenListBegin=tmp->next;
- if (tmp==m_childrenListEnd) m_childrenListEnd=tmp->prev;
+ if (tmp==m_tqchildrenListBegin) m_tqchildrenListBegin=tmp->next;
+ if (tmp==m_tqchildrenListEnd) m_tqchildrenListEnd=tmp->prev;
delete tmp;
break;
}
}
}
-//m_children.remove(dw->name());}
+//m_tqchildren.remove(dw->name());}
void KDockContainer::undockWidget (KDockWidget *){;}
void KDockContainer::setToolTip(KDockWidget *, TQString &){;}
void KDockContainer::setPixmap(KDockWidget*,const TQPixmap&){;}
@@ -3210,11 +3212,11 @@ void KDockContainer::save (TQDomElement&){;}
void KDockContainer::prepareSave(TQStringList &names)
{
- for (struct ListItem *tmp=m_childrenListBegin;tmp; tmp=tmp->next)
+ for (struct ListItem *tmp=m_tqchildrenListBegin;tmp; tmp=tmp->next)
names.remove(tmp->data);
-// for (uint i=0;i<m_children.count();i++)
+// for (uint i=0;i<m_tqchildren.count();i++)
// {
-// names.remove(m_children.at(i));
+// names.remove(m_tqchildren.at(i));
// }
}
@@ -3268,6 +3270,6 @@ void KDockArea::virtual_hook( int, void* )
{ /*KMainWindow::virtual_hook( id, data );*/ }
-#ifndef NO_INCLUDE_MOCFILES // for Qt-only projects, because tmake doesn't take this name
+#ifndef NO_INCLUDE_TQMOCFILES // for TQt-only projects, because tmake doesn't take this name
#include "kdockwidget.moc"
#endif
diff --git a/lib/compatibility/kmdi/qextmdi/kdockwidget.h b/lib/compatibility/kmdi/qextmdi/kdockwidget.h
index 9c738d3c..8fffb002 100644
--- a/lib/compatibility/kmdi/qextmdi/kdockwidget.h
+++ b/lib/compatibility/kmdi/qextmdi/kdockwidget.h
@@ -37,9 +37,9 @@
- KDockWidget - IMPORTANT CLASS: the one and only dockwidget class
- KDockManager - helper class
- KDockMainWindow - IMPORTANT CLASS: a special KMainWindow that can have dockwidgets
- - KDockArea - like KDockMainWindow but inherits just QWidget
+ - KDockArea - like KDockMainWindow but inherits just TQWidget
- IMPORTANT Note: This file compiles also in Qt-only mode by using the NO_KDE2 precompiler definition!
+ IMPORTANT Note: This file compiles also in TQt-only mode by using the NO_KDE2 precompiler definition!
*/
@@ -102,18 +102,19 @@ namespace KMDI
*
* @author Max Judin (documentation: Falk Brettschneider).
*/
-class KDockWidgetAbstractHeader : public QFrame
+class KDockWidgetAbstractHeader : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs this.
*
- * @param parent the parent widget (usually a dockwidget)
+ * @param tqparent the tqparent widget (usually a dockwidget)
* @param name the object instance name
*/
- KDockWidgetAbstractHeader( KDockWidget* parent, const char* name = 0L );
+ KDockWidgetAbstractHeader( KDockWidget* tqparent, const char* name = 0L );
/**
* Destructs this.
@@ -151,19 +152,20 @@ private:
*
* @author Max Judin (documentation: Falk Brettschneider).
*/
-class KDEUI_EXPORT KDockWidgetAbstractHeaderDrag : public QFrame
+class KDEUI_EXPORT KDockWidgetAbstractHeaderDrag : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs this.
*
- * @param parent the parent widget (usually a dockwidget header)
+ * @param tqparent the tqparent widget (usually a dockwidget header)
* @param dock the dockwidget where it belongs to
* @param name the object instance name
*/
- KDockWidgetAbstractHeaderDrag( KDockWidgetAbstractHeader* parent,
+ KDockWidgetAbstractHeaderDrag( KDockWidgetAbstractHeader* tqparent,
KDockWidget* dock, const char* name = 0L );
/**
@@ -199,16 +201,17 @@ private:
class KDEUI_EXPORT KDockWidgetHeaderDrag : public KDockWidgetAbstractHeaderDrag
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs this.
*
- * @param parent the parent widget (usually a dockwidget header)
+ * @param tqparent the tqparent widget (usually a dockwidget header)
* @param dock the dockwidget where it belongs to
* @param name the object instance name
*/
- KDockWidgetHeaderDrag( KDockWidgetAbstractHeader* parent, KDockWidget* dock,
+ KDockWidgetHeaderDrag( KDockWidgetAbstractHeader* tqparent, KDockWidget* dock,
const char* name = 0L );
/**
@@ -240,15 +243,16 @@ private:
class KDEUI_EXPORT KDockWidgetHeader : public KDockWidgetAbstractHeader
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs this.
*
- * @param parent the parent widget (usually a dockwidget)
+ * @param tqparent the tqparent widget (usually a dockwidget)
* @param name the object instance name
*/
- KDockWidgetHeader( KDockWidget* parent, const char* name = 0L );
+ KDockWidgetHeader( KDockWidget* tqparent, const char* name = 0L );
/**
* Destructs this.
@@ -324,9 +328,9 @@ protected slots:
protected:
/**
- * A layout manager for placing the embedded buttons (close and stay)
+ * A tqlayout manager for placing the embedded buttons (close and stay)
*/
- TQHBoxLayout* layout;
+ TQHBoxLayout* tqlayout;
/**
* a little button for closing (undocking and hiding) the dockwidget
@@ -362,15 +366,16 @@ private:
*
* @author Max Judin (documentation: Falk Brettschneider).
*/
-class KDEUI_EXPORT KDockTabGroup : public QTabWidget
+class KDEUI_EXPORT KDockTabGroup : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructs this. It just calls the method of the base class.
*/
- KDockTabGroup( TQWidget *parent = 0, const char *name = 0 )
- :TQTabWidget( parent, name ){};
+ KDockTabGroup( TQWidget *tqparent = 0, const char *name = 0 )
+ :TQTabWidget( tqparent, name ){};
/**
* Destructs a KDockTabGroup.
@@ -391,7 +396,7 @@ private:
* encapsulate the actual widgets (and member of the dockwidget class
* set).
*
- * You just grip the double-lined panel, tear it off its parent
+ * You just grip the double-lined panel, tear it off its tqparent
* widget, drag it somewhere and let it loose. Depending on the
* position where you leave it, the dockwidget becomes a toplevel
* window on the desktop (floating mode) or docks to a new widget
@@ -410,7 +415,7 @@ private:
* KDockMainWindow* mainWidget;
* ...
* KDockWidget* dock = 0L;
- * dock = mainWidget->createDockWidget( "Any window caption", nicePixmap, 0L, i18n("window caption")); // 0L==no parent
+ * dock = mainWidget->createDockWidget( "Any window caption", nicePixmap, 0L, i18n("window caption")); // 0L==no tqparent
* TQWidget* actualWidget = new TQWidget( dock);
* dock->setWidget( actualWidget); // embed it
* dock->setToolTipString(i18n("That's me")); // available when appearing as tab page
@@ -422,9 +427,10 @@ private:
*
* @author Max Judin (documentation: Falk Brettschneider).
*/
-class KDEUI_EXPORT KDockWidget: public QWidget
+class KDEUI_EXPORT KDockWidget: public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
friend class KDockManager;
friend class KDockSplitter;
friend class KDockMainWindow;
@@ -441,14 +447,14 @@ public:
* @param dockManager The responsible manager (dock helper)
* @param name Object instance name
* @param pixmap An icon (for instance shown when docked centered)
- * @param parent Parent widget
+ * @param tqparent Parent widget
* @param strCaption Title of the dockwidget window (shown when toplevel)
* @param strTabPageLabel The title of the tab page (shown when in tab page mode), if it is "", only the icon will be shown, if it is 0L, the label is set to strCaption
- * @param f Qt::WidgetFlags widget flags
+ * @param f TQt::WidgetFlags widget flags
*/
KDockWidget( KDockManager* dockManager, const char* name,
- const TQPixmap &pixmap, TQWidget* parent = 0L, const TQString& strCaption = TQString::null,
- const TQString& strTabPageLabel = TQString::fromLatin1( " " ), WFlags f = 0);
+ const TQPixmap &pixmap, TQWidget* tqparent = 0L, const TQString& strCaption = TQString(),
+ const TQString& strTabPageLabel = TQString::tqfromLatin1( " " ), WFlags f = 0);
/**
* Destructs a dockwidget.
@@ -481,8 +487,8 @@ public:
*
* If the target is null, it will become a toplevel dockwidget at position pos;
* Note: Docking to another dockwidget means exactly:
- * A new parent dockwidget will be created, that replaces the target dockwidget and contains another single helper widget (tab widget or panner)
- * which contains both dockwidgets, this and the target dockwidget. So consider parent<->child relationships change completely during such actions.
+ * A new tqparent dockwidget will be created, that replaces the target dockwidget and contains another single helper widget (tab widget or panner)
+ * which contains both dockwidgets, this and the target dockwidget. So consider tqparent<->child relationships change completely during such actions.
*
* @param target The dockwidget to dock to
* @param dockPos One of the DockPositions this is going to dock to
@@ -490,7 +496,7 @@ public:
* @param pos The dock position, mainly of interest for docking to the desktop (as toplevel dockwidget)
* @param check Only for internal use;
* @param tabIndex The position index of the tab widget (when in tab page mode), -1 (default) means append
- * @return result The group dockwidget that replaces the target dockwidget and will be grandparent of target and @p this.
+ * @return result The group dockwidget that replaces the target dockwidget and will be grandtqparent of target and @p this.
*/
KDockWidget* manualDock( KDockWidget* target, DockPosition dockPos, int spliPos = 50, TQPoint pos = TQPoint(0,0), bool check = false, int tabIndex = -1);
@@ -562,7 +568,7 @@ public:
* There are reasons that it's impossible:
* @li It is a (tab) group.
* @li It is already invisible ;-)
- * @li The parent of this is the KDockMainWindow.
+ * @li The tqparent of this is the KDockMainWindow.
* @li It isn't able to dock to another widget.
*/
bool mayBeHide() const;
@@ -572,7 +578,7 @@ public:
* There are reasons that it's impossible:
* @li It is a (tab) group.
* @li It is already visible ;-)
- * @li The parent of this is the @p KDockMainWindow.
+ * @li The tqparent of this is the @p KDockMainWindow.
*/
bool mayBeShow() const;
@@ -624,12 +630,12 @@ public:
*/
virtual void show();
/**
- * @return the parent widget of this if it inherits class KDockTabGroup
+ * @return the tqparent widget of this if it inherits class KDockTabGroup
*/
- KDockTabGroup* parentDockTabGroup() const;
+ KDockTabGroup* tqparentDockTabGroup() const;
/// @since 3.1
- TQWidget *parentDockContainer() const;
+ TQWidget *tqparentDockContainer() const;
#ifndef NO_KDE2
@@ -642,7 +648,7 @@ public:
#endif
- void setDockWindowTransient (TQWidget *parent, bool transientEnabled);
+ void setDockWindowTransient (TQWidget *tqparent, bool transientEnabled);
/**
* Returns the widget this dockwidget is set transient to, otherwise 0
@@ -732,7 +738,7 @@ protected:
/**
* Checks some conditions and shows or hides the dockwidget header (drag panel).
* The header is hidden if:
- * @li the parent widget is the KDockMainWindow
+ * @li the tqparent widget is the KDockMainWindow
* @li this is a (tab) group dockwidget
* @li it is not able to dock to another dockwidget
*/
@@ -831,7 +837,7 @@ private:
void setDockTabName( KDockTabGroup* g);
/**
- * Reparent to s or set this to the KDockMainWindow's view if s is that dockmainwindow.
+ * Retqparent to s or set this to the KDockMainWindow's view if s is that dockmainwindow.
* If s is O, simply move the widget.
*
* @param s the target widget to reparent to
@@ -850,9 +856,9 @@ private:
TQWidget* widget;
/**
- * the layout manager that takes care about proper resizing and moving the embedded widget and the header
+ * the tqlayout manager that takes care about proper resizing and moving the embedded widget and the header
*/
- TQVBoxLayout* layout;
+ TQVBoxLayout* tqlayout;
/**
* the responsible dockmanager
@@ -882,7 +888,7 @@ private:
// GROUP data
TQString firstName;
TQString lastName;
- Orientation splitterOrientation;
+ Qt::Orientation splitterOrientation;
bool isGroup;
bool isTabGroup;
protected:
@@ -903,9 +909,10 @@ private:
*
* @author Max Judin (documentation: Falk Brettschneider).
*/
-class KDEUI_EXPORT KDockManager: public QObject
+class KDEUI_EXPORT KDockManager: public TQObject
{
Q_OBJECT
+ TQ_OBJECT
friend class KDockWidget;
friend class KDockMainWindow;
@@ -925,7 +932,7 @@ public:
* @li Some state variables are set
*
* @param mainWindow the main window controlled by this
- * @param name the internal QOject name
+ * @param name the internal TQOject name
*/
KDockManager( TQWidget* mainWindow, const char* name = 0L );
@@ -939,14 +946,14 @@ public:
#ifndef NO_KDE2
/**
* Saves the current state of the dockmanager and of all controlled widgets.
- * State means here to save the geometry, visibility, parents, internal object names, orientation,
+ * State means here to save the tqgeometry, visibility, tqparents, internal object names, orientation,
* separator positions, dockwidget-group information, tab widget states (if it is a tab group) and
* last but not least some necessary things for recovering the dockmainwindow state.
*
* @param c the KDE configuration saver
* @param group the name of the section in KConfig
*/
- void writeConfig( KConfig* c = 0L, TQString group = TQString::null );
+ void writeConfig( KConfig* c = 0L, TQString group = TQString() );
/**
* Like writeConfig but reads the whole stuff in.
@@ -956,7 +963,7 @@ public:
* (TQObject::name) in the childDock variable of
* KDockManager. This list in turn contains all
* KDockWidgets (according to the KDockWidget constructor).
- * So in principle, in order to restore a window layout,
+ * So in principle, in order to restore a window tqlayout,
* one must first construct all widgets, put each of them in a
* KDockWidget and then call readConfig(). And for all that
* to work, each widget must have a unique name.
@@ -964,24 +971,24 @@ public:
* @param c the KDE configuration saver
* @param group the name of the section in KConfig
*/
- void readConfig ( KConfig* c = 0L, TQString group = TQString::null );
+ void readConfig ( KConfig* c = 0L, TQString group = TQString() );
#endif
/// @since 3.1
void setMainDockWidget2(KDockWidget *);
/**
- * Saves the current dock window layout into a DOM tree below the given element.
+ * Saves the current dock window tqlayout into a DOM tree below the given element.
*/
void writeConfig(TQDomElement &base);
/**
- * Reads the current dock window layout from a DOM tree below the given element.
+ * Reads the current dock window tqlayout from a DOM tree below the given element.
*/
void readConfig(TQDomElement &base);
/**
* Shows all encapsulated widgets of all controlled dockwidgets and shows all dockwidgets which are
- * parent of a dockwidget tab group.
+ * tqparent of a dockwidget tab group.
*/
void activate();
@@ -1083,7 +1090,7 @@ signals:
void replaceDock( KDockWidget* oldDock, KDockWidget* newDock );
/**
- * Signals a dockwidget without parent (toplevel) is shown.
+ * Signals a dockwidget without tqparent (toplevel) is shown.
*/
void setDockDefaultPos( KDockWidget* );
@@ -1137,7 +1144,7 @@ private:
* Finds the TQWidget recursively at the position given as parameter
*
* @param w a variable where the method puts the TQWidget at that position (instead of a return value)
- * @param p the parent widget where the recursive search should start from
+ * @param p the tqparent widget where the recursive search should start from
* @param pos global (desktop) position of the wanted dockwidget
*/
void findChildDockWidget( TQWidget*& w, const TQWidget* p, const TQPoint& pos );
@@ -1145,7 +1152,7 @@ private:
/**
* Finds all dockwidgets which are child, grandchild and so on of p.
*
- * @param p the parent widget where the recursive search starts from
+ * @param p the tqparent widget where the recursive search starts from
* @param l the widget list that contains the search result after the return of this method
*/
void findChildDockWidget( const TQWidget* p, TQWidgetList*& l);
@@ -1202,7 +1209,7 @@ private:
KDockWidget::DockPosition curPos;
/**
- * A QList of all objects that are important for docking.
+ * A TQList of all objects that are important for docking.
* Some serve as group widgets of dockwidgets, others encapsulate normal widgets.
*/
TQObjectList* childDock;
@@ -1302,6 +1309,7 @@ private:
class KDEUI_EXPORT KDockMainWindow : public KMainWindow
{
Q_OBJECT
+ TQ_OBJECT
friend class KDockManager;
@@ -1310,16 +1318,16 @@ public:
/**
* Constructs a dockmainwindow. It calls its base class constructor and does additional things concerning
* to the dock stuff:
- * @li information about the dock state of this' children gets initialized
+ * @li information about the dock state of this' tqchildren gets initialized
* @li a dockmanager is created...
* @li ...and gets initialized
* @li the main dockwidget is set to 0
*
- * @param parent Parent widget for the dock main widget
+ * @param tqparent Parent widget for the dock main widget
* @param name internal object name
- * @param f Qt::WidgetFlags widget flags
+ * @param f TQt::WidgetFlags widget flags
*/
- KDockMainWindow( TQWidget* parent = 0L, const char *name = 0L, WFlags f = WType_TopLevel | WDestructiveClose );
+ KDockMainWindow( TQWidget* tqparent = 0L, const char *name = 0L, WFlags f = WType_TopLevel | WDestructiveClose );
/**
* Destructs a dockmainwindow.
@@ -1354,20 +1362,20 @@ public:
*
* @param name TQObject name (default dockwidget caption)
* @param pixmap window icon (for instance shown when docked as tabwidget entry)
- * @param parent parent widget for the new dockwidget
+ * @param tqparent tqparent widget for the new dockwidget
* @param strCaption window title (shown when toplevel)
* @param strTabPageLabel title of the tab page (visible when in tab page mode), if it is "", only the icon will be shown; if it is 0L, the label is set to strCaption
* @return a pointer to the new created dockwidget
*/
- KDockWidget* createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* parent = 0L,
- const TQString& strCaption = TQString::null, const TQString& strTabPageLabel = TQString::fromLatin1( " " ) );
+ KDockWidget* createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* tqparent = 0L,
+ const TQString& strCaption = TQString(), const TQString& strTabPageLabel = TQString::tqfromLatin1( " " ) );
/**
- * Saves the current dock window layout into a DOM tree below the given element.
+ * Saves the current dock window tqlayout into a DOM tree below the given element.
*/
void writeDockConfig(TQDomElement &base);
/**
- * Reads the current dock window layout from a DOM tree below the given element.
+ * Reads the current dock window tqlayout from a DOM tree below the given element.
*/
void readDockConfig(TQDomElement &base);
@@ -1378,7 +1386,7 @@ public:
* @param c KDE class for saving configurations
* @param group name of section to write to
*/
- void writeDockConfig( KConfig* c = 0L, TQString group = TQString::null );
+ void writeDockConfig( KConfig* c = 0L, TQString group = TQString() );
/**
* It reads the current dock state from the given section of KConfig.
@@ -1386,7 +1394,7 @@ public:
* @param c KDE class for saving configurations
* @param group name of section to read from
*/
- void readDockConfig ( KConfig* c = 0L, TQString group = TQString::null );
+ void readDockConfig ( KConfig* c = 0L, TQString group = TQString() );
#endif
/**
@@ -1465,16 +1473,17 @@ private:
KDockMainWindowPrivate *d;
};
-class KDEUI_EXPORT KDockArea : public QWidget
+class KDEUI_EXPORT KDockArea : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
friend class KDockManager;
public:
- KDockArea( TQWidget* parent = 0L, const char *name = 0L);
+ KDockArea( TQWidget* tqparent = 0L, const char *name = 0L);
virtual ~KDockArea();
@@ -1484,15 +1493,15 @@ public:
void setMainDockWidget( KDockWidget* );
KDockWidget* getMainDockWidget(){ return mainDockWidget; }
- KDockWidget* createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* parent = 0L,
- const TQString& strCaption = TQString::null, const TQString& strTabPageLabel = TQString::fromLatin1( " " ) );
+ KDockWidget* createDockWidget( const TQString& name, const TQPixmap &pixmap, TQWidget* tqparent = 0L,
+ const TQString& strCaption = TQString(), const TQString& strTabPageLabel = TQString::tqfromLatin1( " " ) );
void writeDockConfig(TQDomElement &base);
void readDockConfig(TQDomElement &base);
#ifndef NO_KDE2
- void writeDockConfig( KConfig* c = 0L, TQString group = TQString::null );
- void readDockConfig ( KConfig* c = 0L, TQString group = TQString::null );
+ void writeDockConfig( KConfig* c = 0L, TQString group = TQString() );
+ void readDockConfig ( KConfig* c = 0L, TQString group = TQString() );
#endif
diff --git a/lib/compatibility/kmdi/qextmdi/kdockwidget_p.h b/lib/compatibility/kmdi/qextmdi/kdockwidget_p.h
index 98af140f..39c9ffe1 100644
--- a/lib/compatibility/kmdi/qextmdi/kdockwidget_p.h
+++ b/lib/compatibility/kmdi/qextmdi/kdockwidget_p.h
@@ -45,7 +45,7 @@ class KDEUI_EXPORT KDockContainer
public:
KDockContainer();
virtual ~KDockContainer();
- virtual KDockWidget *parentDockWidget();
+ virtual KDockWidget *tqparentDockWidget();
virtual void insertWidget (KDockWidget *, TQPixmap, const TQString &, int &);
virtual void showWidget(KDockWidget *);
virtual void removeWidget(KDockWidget*);
@@ -77,8 +77,8 @@ private:
- struct ListItem *m_childrenListBegin;
- struct ListItem *m_childrenListEnd;
+ struct ListItem *m_tqchildrenListBegin;
+ struct ListItem *m_tqchildrenListEnd;
class KDockContainerPrivate;
KDockContainerPrivate *d;
diff --git a/lib/compatibility/kmdi/qextmdi/kdockwidget_private.cpp b/lib/compatibility/kmdi/qextmdi/kdockwidget_private.cpp
index 4106d101..f428783a 100644
--- a/lib/compatibility/kmdi/qextmdi/kdockwidget_private.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kdockwidget_private.cpp
@@ -26,8 +26,8 @@
#include <tqtimer.h>
#include <tqapplication.h>
-KDockSplitter::KDockSplitter(TQWidget *parent, const char *name, Orientation orient, int pos, bool highResolution)
-: TQWidget(parent, name)
+KDockSplitter::KDockSplitter(TQWidget *tqparent, const char *name, Qt::Orientation orient, int pos, bool highResolution)
+: TQWidget(tqparent, name)
{
m_dontRecalc=false;
divider = 0L;
@@ -59,7 +59,7 @@ void KDockSplitter::activate(TQWidget *c0, TQWidget *c1)
divider->setLineWidth(1);
divider->raise();
- if (m_orientation == Horizontal)
+ if (m_orientation ==Qt::Horizontal)
divider->setCursor(TQCursor(sizeVerCursor));
else
divider->setCursor(TQCursor(sizeHorCursor));
@@ -179,21 +179,21 @@ void KDockSplitter::setupMinMaxSize()
{
// Set the minimum and maximum sizes
int minx, maxx, miny, maxy;
- if (m_orientation == Horizontal) {
- miny = child0->minimumSize().height() + child1->minimumSize().height()+4;
- maxy = child0->maximumSize().height() + child1->maximumSize().height()+4;
- minx = (child0->minimumSize().width() > child1->minimumSize().width()) ? child0->minimumSize().width() : child1->minimumSize().width();
- maxx = (child0->maximumSize().width() > child1->maximumSize().width()) ? child0->maximumSize().width() : child1->maximumSize().width();
+ if (m_orientation ==Qt::Horizontal) {
+ miny = child0->tqminimumSize().height() + child1->tqminimumSize().height()+4;
+ maxy = child0->tqmaximumSize().height() + child1->tqmaximumSize().height()+4;
+ minx = (child0->tqminimumSize().width() > child1->tqminimumSize().width()) ? child0->tqminimumSize().width() : child1->tqminimumSize().width();
+ maxx = (child0->tqmaximumSize().width() > child1->tqmaximumSize().width()) ? child0->tqmaximumSize().width() : child1->tqmaximumSize().width();
miny = (miny > 4) ? miny : 4;
maxy = (maxy < 32000) ? maxy : 32000;
minx = (minx > 2) ? minx : 2;
maxx = (maxx < 32000) ? maxx : 32000;
} else {
- minx = child0->minimumSize().width() + child1->minimumSize().width()+4;
- maxx = child0->maximumSize().width() + child1->maximumSize().width()+4;
- miny = (child0->minimumSize().height() > child1->minimumSize().height()) ? child0->minimumSize().height() : child1->minimumSize().height();
- maxy = (child0->maximumSize().height() > child1->maximumSize().height()) ? child0->maximumSize().height() : child1->maximumSize().height();
+ minx = child0->tqminimumSize().width() + child1->tqminimumSize().width()+4;
+ maxx = child0->tqmaximumSize().width() + child1->tqmaximumSize().width()+4;
+ miny = (child0->tqminimumSize().height() > child1->tqminimumSize().height()) ? child0->tqminimumSize().height() : child1->tqminimumSize().height();
+ maxy = (child0->tqmaximumSize().height() > child1->tqmaximumSize().height()) ? child0->tqmaximumSize().height() : child1->tqmaximumSize().height();
minx = (minx > 4) ? minx : 4;
maxx = (maxx < 32000) ? maxx : 32000;
@@ -238,32 +238,32 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
double factor = (mHighResolution)? 10000.0:100.0;
// real resize event, recalculate xpos
if (ev && mKeepSize && isVisible()) {
-// kdDebug(282)<<"mKeepSize : "<< ((m_orientation == Horizontal) ? "Horizontal":"Vertical") <<endl;
+// kdDebug(282)<<"mKeepSize : "<< ((m_orientation ==Qt::Horizontal) ? "Horizontal":"Vertical") <<endl;
if (ev->oldSize().width() != ev->size().width())
{
- if (m_orientation == Horizontal) {
- xpos = qRound(factor * checkValue( child0->height()+1 ) / height());
+ if (m_orientation ==Qt::Horizontal) {
+ xpos = tqRound(factor * checkValue( child0->height()+1 ) / height());
} else {
- xpos = qRound(factor * checkValue( child0->width()+1 ) / width());
+ xpos = tqRound(factor * checkValue( child0->width()+1 ) / width());
}
}
}
else
{
-// kdDebug(282)<<"!mKeepSize : "<< ((m_orientation == Horizontal) ? "Horizontal":"Vertical") <<endl;
+// kdDebug(282)<<"!mKeepSize : "<< ((m_orientation ==Qt::Horizontal) ? "Horizontal":"Vertical") <<endl;
if (/*ev &&*/ isVisible()) {
- if (m_orientation == Horizontal) {
+ if (m_orientation ==Qt::Horizontal) {
/* if (ev->oldSize().height() != ev->size().height())*/
{
if (fixedHeight0!=-1)
// xpos=floor(fixedHeight0*factor/height());
- xpos=qRound(fixedHeight0*factor/height());
+ xpos=tqRound(fixedHeight0*factor/height());
else
if (fixedHeight1!=-1)
// xpos=ceil((height()-fixedHeight1)*factor/height());
- xpos=qRound((height()-fixedHeight1)*factor/height());
+ xpos=tqRound((height()-fixedHeight1)*factor/height());
}
}
else
@@ -272,11 +272,11 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
{
if (fixedWidth0!=-1)
// xpos=floor(fixedWidth0*factor/width());
- xpos=qRound(fixedWidth0*factor/width());
+ xpos=tqRound(fixedWidth0*factor/width());
else
if (fixedWidth1!=-1)
// xpos=ceil((width()-fixedWidth1)*factor/width());
- xpos=qRound((width()-fixedWidth1)*factor/width());
+ xpos=tqRound((width()-fixedWidth1)*factor/width());
}
}
}
@@ -287,15 +287,15 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
KDockWidget *c0=(KDockWidget*)child0;
KDockWidget *c1=(KDockWidget*)child1;
bool stdHandling=false;
- if ( ( (m_orientation==Vertical) &&((fixedWidth0==-1) && (fixedWidth1==-1)) ) ||
- ( (m_orientation==Horizontal) &&((fixedHeight0==-1) && (fixedHeight1==-1)) ) ) {
+ if ( ( (m_orientation==Qt::Vertical) &&((fixedWidth0==-1) && (fixedWidth1==-1)) ) ||
+ ( (m_orientation==Qt::Horizontal) &&((fixedHeight0==-1) && (fixedHeight1==-1)) ) ) {
if ((c0->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c0->getWidget()))
&& (dc->m_overlapMode)) {
- int position= qRound((m_orientation == Vertical ? width() : height()) * xpos/factor);
+ int position= tqRound((m_orientation ==Qt::Vertical ? width() : height()) * xpos/factor);
position=checkValueOverlapped(position,child0);
child0->raise();
divider->raise();
- if (m_orientation == Horizontal){
+ if (m_orientation ==Qt::Horizontal){
child0->setGeometry(0, 0, width(), position);
child1->setGeometry(0, dc->m_nonOverlapSize+4, width(),
height()-dc->m_nonOverlapSize-4);
@@ -309,11 +309,11 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
} else {
if ((c1->getWidget()) && (dc=dynamic_cast<KDockContainer*>(c1->getWidget()))
&& (dc->m_overlapMode)) {
- int position= qRound((m_orientation == Vertical ? width() : height()) * xpos/factor);
+ int position= tqRound((m_orientation ==Qt::Vertical ? width() : height()) * xpos/factor);
position=checkValueOverlapped(position,child1);
child1->raise();
divider->raise();
- if (m_orientation == Horizontal){
+ if (m_orientation ==Qt::Horizontal){
child0->setGeometry(0, 0, width(), height()-dc->m_nonOverlapSize-4);
child1->setGeometry(0, position+4, width(),
height()-position-4);
@@ -331,8 +331,8 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
else stdHandling=true;
if (stdHandling) {
- int position = checkValue( qRound((m_orientation == Vertical ? width() : height()) * xpos/factor) );
- if (m_orientation == Horizontal){
+ int position = checkValue( tqRound((m_orientation ==Qt::Vertical ? width() : height()) * xpos/factor) );
+ if (m_orientation ==Qt::Horizontal){
child0->setGeometry(0, 0, width(), position);
child1->setGeometry(0, position+4, width(), height()-position-4);
divider->setGeometry(0, position, width(), 4);
@@ -349,22 +349,22 @@ void KDockSplitter::resizeEvent(TQResizeEvent *ev)
int KDockSplitter::checkValueOverlapped(int position, TQWidget *overlappingWidget) const {
if (initialised) {
- if (m_orientation == Vertical) {
+ if (m_orientation ==Qt::Vertical) {
if (child0==overlappingWidget) {
- if (position<(child0->minimumSize().width()))
- position=child0->minimumSize().width();
+ if (position<(child0->tqminimumSize().width()))
+ position=child0->tqminimumSize().width();
if (position>width()) position=width()-4;
- } else if (position>(width()-(child1->minimumSize().width())-4)){
- position=width()-(child1->minimumSize().width())-4;
+ } else if (position>(width()-(child1->tqminimumSize().width())-4)){
+ position=width()-(child1->tqminimumSize().width())-4;
if (position<0) position=0;
}
- } else {// orientation == Horizontal
+ } else {// orientation ==Qt::Horizontal
if (child0==overlappingWidget) {
- if (position<(child0->minimumSize().height()))
- position=child0->minimumSize().height();
+ if (position<(child0->tqminimumSize().height()))
+ position=child0->tqminimumSize().height();
if (position>height()) position=height()-4;
- } else if (position>(height()-(child1->minimumSize().height())-4)){
- position=height()-(child1->minimumSize().height())-4;
+ } else if (position>(height()-(child1->tqminimumSize().height())-4)){
+ position=height()-(child1->tqminimumSize().height())-4;
if (position<0) position=0;
}
@@ -377,24 +377,24 @@ int KDockSplitter::checkValueOverlapped(int position, TQWidget *overlappingWidge
int KDockSplitter::checkValue( int position ) const
{
if (initialised){
- if (m_orientation == Vertical){
- if (position < (child0->minimumSize().width()))
- position = child0->minimumSize().width();
- if ((width()-4-position) < (child1->minimumSize().width()))
- position = width() - (child1->minimumSize().width()) -4;
+ if (m_orientation ==Qt::Vertical){
+ if (position < (child0->tqminimumSize().width()))
+ position = child0->tqminimumSize().width();
+ if ((width()-4-position) < (child1->tqminimumSize().width()))
+ position = width() - (child1->tqminimumSize().width()) -4;
} else {
- if (position < (child0->minimumSize().height()))
- position = (child0->minimumSize().height());
- if ((height()-4-position) < (child1->minimumSize().height()))
- position = height() - (child1->minimumSize().height()) -4;
+ if (position < (child0->tqminimumSize().height()))
+ position = (child0->tqminimumSize().height());
+ if ((height()-4-position) < (child1->tqminimumSize().height()))
+ position = height() - (child1->tqminimumSize().height()) -4;
}
}
if (position < 0) position = 0;
- if ((m_orientation == Vertical) && (position > width()))
+ if ((m_orientation ==Qt::Vertical) && (position > width()))
position = width();
- if ((m_orientation == Horizontal) && (position > height()))
+ if ((m_orientation ==Qt::Horizontal) && (position > height()))
position = height();
return position;
@@ -411,7 +411,7 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
mev= (TQMouseEvent*)e;
child0->setUpdatesEnabled(mOpaqueResize);
child1->setUpdatesEnabled(mOpaqueResize);
- if (m_orientation == Horizontal) {
+ if (m_orientation ==Qt::Horizontal) {
if ((fixedHeight0!=-1) || (fixedHeight1!=-1))
{
handled=true; break;
@@ -423,7 +423,7 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
} else {
xpos = factor * checkValue( mapFromGlobal(mev->globalPos()).y() ) / height();
resizeEvent(0);
- divider->repaint(true);
+ divider->tqrepaint(true);
}
} else {
if ((fixedWidth0!=-1) || (fixedWidth1!=-1))
@@ -436,7 +436,7 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
} else {
xpos = factor * checkValue( mapFromGlobal( mev->globalPos()).x() ) / width();
resizeEvent(0);
- divider->repaint(true);
+ divider->tqrepaint(true);
}
}
handled= true;
@@ -445,14 +445,14 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
child0->setUpdatesEnabled(true);
child1->setUpdatesEnabled(true);
mev= (TQMouseEvent*)e;
- if (m_orientation == Horizontal){
+ if (m_orientation ==Qt::Horizontal){
if ((fixedHeight0!=-1) || (fixedHeight1!=-1))
{
handled=true; break;
}
xpos = factor* checkValue( mapFromGlobal(mev->globalPos()).y() ) / height();
resizeEvent(0);
- divider->repaint(true);
+ divider->tqrepaint(true);
} else {
if ((fixedWidth0!=-1) || (fixedWidth1!=-1))
{
@@ -460,7 +460,7 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
}
xpos = factor* checkValue( mapFromGlobal(mev->globalPos()).x() ) / width();
resizeEvent(0);
- divider->repaint(true);
+ divider->tqrepaint(true);
}
handled= true;
break;
@@ -473,7 +473,7 @@ bool KDockSplitter::eventFilter(TQObject *o, TQEvent *e)
bool KDockSplitter::event( TQEvent* e )
{
if ( e->type() == TQEvent::LayoutHint ){
- // change children min/max size
+ // change tqchildren min/max size
setupMinMaxSize();
setSeparatorPos(xpos);
}
@@ -490,15 +490,15 @@ void KDockSplitter::updateName()
if ( !initialised ) return;
TQString new_name = TQString( child0->name() ) + "," + child1->name();
- parentWidget()->setName( new_name.latin1() );
- parentWidget()->setCaption( child0->caption() + "," + child1->caption() );
- parentWidget()->repaint( false );
+ tqparentWidget()->setName( new_name.latin1() );
+ tqparentWidget()->setCaption( child0->caption() + "," + child1->caption() );
+ tqparentWidget()->tqrepaint( false );
- ((KDockWidget*)parentWidget())->firstName = child0->name();
- ((KDockWidget*)parentWidget())->lastName = child1->name();
- ((KDockWidget*)parentWidget())->splitterOrientation = m_orientation;
+ ((KDockWidget*)tqparentWidget())->firstName = child0->name();
+ ((KDockWidget*)tqparentWidget())->lastName = child1->name();
+ ((KDockWidget*)tqparentWidget())->splitterOrientation = m_orientation;
- TQWidget* p = parentWidget()->parentWidget();
+ TQWidget* p = tqparentWidget()->tqparentWidget();
if ( p && p->inherits("KDockSplitter" ) )
((KDockSplitter*)p)->updateName();
}
@@ -540,11 +540,11 @@ bool KDockSplitter::highResolution() const
/*************************************************************************/
-KDockButton_Private::KDockButton_Private( TQWidget *parent, const char * name )
-:TQPushButton( parent, name )
+KDockButton_Private::KDockButton_Private( TQWidget *tqparent, const char * name )
+:TQPushButton( tqparent, name )
{
moveMouse = false;
- setFocusPolicy( NoFocus );
+ setFocusPolicy( TQ_NoFocus );
}
KDockButton_Private::~KDockButton_Private()
@@ -553,7 +553,7 @@ KDockButton_Private::~KDockButton_Private()
void KDockButton_Private::drawButton( TQPainter* p )
{
- p->fillRect( 0,0, width(), height(), TQBrush(colorGroup().brush(TQColorGroup::Background)) );
+ p->fillRect( 0,0, width(), height(), TQBrush(tqcolorGroup().brush(TQColorGroup::Background)) );
p->drawPixmap( (width() - pixmap()->width()) / 2, (height() - pixmap()->height()) / 2, *pixmap() );
if ( moveMouse && !isDown() ){
p->setPen( white );
@@ -561,12 +561,12 @@ void KDockButton_Private::drawButton( TQPainter* p )
p->lineTo( 0, 0 );
p->lineTo( width() - 1, 0 );
- p->setPen( colorGroup().dark() );
+ p->setPen( tqcolorGroup().dark() );
p->lineTo( width() - 1, height() - 1 );
p->lineTo( 0, height() - 1 );
}
if ( isOn() || isDown() ){
- p->setPen( colorGroup().dark() );
+ p->setPen( tqcolorGroup().dark() );
p->moveTo( 0, height() - 1 );
p->lineTo( 0, 0 );
p->lineTo( width() - 1, 0 );
@@ -580,13 +580,13 @@ void KDockButton_Private::drawButton( TQPainter* p )
void KDockButton_Private::enterEvent( TQEvent * )
{
moveMouse = true;
- repaint();
+ tqrepaint();
}
void KDockButton_Private::leaveEvent( TQEvent * )
{
moveMouse = false;
- repaint();
+ tqrepaint();
}
/*************************************************************************/
@@ -620,12 +620,12 @@ void KDockWidgetPrivate::slotFocusEmbeddedWidget(TQWidget* w)
{
if (w) {
TQWidget* embeddedWdg = ((KDockWidget*)w)->getWidget();
- if (embeddedWdg && ((embeddedWdg->focusPolicy() == TQWidget::ClickFocus) || (embeddedWdg->focusPolicy() == TQWidget::StrongFocus))) {
+ if (embeddedWdg && ((embeddedWdg->focusPolicy() == TQ_ClickFocus) || (embeddedWdg->focusPolicy() == TQ_StrongFocus))) {
embeddedWdg->setFocus();
}
}
}
-#ifndef NO_INCLUDE_MOCFILES // for Qt-only projects, because tmake doesn't take this name
+#ifndef NO_INCLUDE_TQMOCFILES // for TQt-only projects, because tmake doesn't take this name
#include "kdockwidget_private.moc"
#endif
diff --git a/lib/compatibility/kmdi/qextmdi/kdockwidget_private.h b/lib/compatibility/kmdi/qextmdi/kdockwidget_private.h
index 327471ed..4f9c119f 100644
--- a/lib/compatibility/kmdi/qextmdi/kdockwidget_private.h
+++ b/lib/compatibility/kmdi/qextmdi/kdockwidget_private.h
@@ -17,7 +17,7 @@
*/
/*
- IMPORTANT Note: This file compiles also in Qt-only mode by using the NO_KDE2 precompiler definition
+ IMPORTANT Note: This file compiles also in TQt-only mode by using the NO_KDE2 precompiler definition
*/
#ifndef KDOCKWIDGET_PRIVATE_H
@@ -40,11 +40,12 @@ class KDockContainer;
*
* @author Max Judin.
*/
-class KDEUI_EXPORT KDockSplitter : public QWidget
+class KDEUI_EXPORT KDockSplitter : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- KDockSplitter(TQWidget *parent= 0, const char *name= 0, Orientation orient= Vertical, int pos= 50, bool highResolution=false);
+ KDockSplitter(TQWidget *tqparent= 0, const char *name= 0, Qt::Orientation orient=Qt::Vertical, int pos= 50, bool highResolution=false);
virtual ~KDockSplitter(){};
void activate(TQWidget *c0, TQWidget *c1 = 0L);
@@ -84,7 +85,7 @@ public:
void setForcedFixedHeight(KDockWidget *dw,int h);
void restoreFromForcedFixedSize(KDockWidget *dw);
- Orientation orientation(){return m_orientation;}
+ Qt::Orientation orientation(){return m_orientation;}
protected:
friend class KDockContainer;
@@ -98,7 +99,7 @@ protected slots:
private:
void setupMinMaxSize();
TQWidget *child0, *child1;
- Orientation m_orientation;
+ Qt::Orientation m_orientation;
bool initialised;
TQFrame* divider;
int xpos, savedXPos;
@@ -114,11 +115,12 @@ private:
*
* @author Max Judin.
*/
-class KDEUI_EXPORT KDockButton_Private : public QPushButton
+class KDEUI_EXPORT KDockButton_Private : public TQPushButton
{
Q_OBJECT
+ TQ_OBJECT
public:
- KDockButton_Private( TQWidget *parent=0, const char *name=0 );
+ KDockButton_Private( TQWidget *tqparent=0, const char *name=0 );
~KDockButton_Private();
protected:
@@ -139,9 +141,10 @@ private:
/**
* additional KDockWidget stuff (private)
*/
-class KDEUI_EXPORT KDockWidgetPrivate : public QObject
+class KDEUI_EXPORT KDockWidgetPrivate : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
KDockWidgetPrivate();
~KDockWidgetPrivate();
@@ -180,11 +183,11 @@ public:
};
class KDEUI_EXPORT KDockWidgetHeaderPrivate
- : public QObject
+ : public TQObject
{
public:
- KDockWidgetHeaderPrivate( TQObject* parent )
- : TQObject( parent )
+ KDockWidgetHeaderPrivate( TQObject* tqparent )
+ : TQObject( tqparent )
{
forceCloseButtonHidden=false;
toDesktopButton = 0;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildarea.cpp b/lib/compatibility/kmdi/qextmdi/kmdichildarea.cpp
index 923b5537..da7ede0d 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildarea.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildarea.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Szymon Stefanek (stefanek@tin.it)
@@ -45,8 +45,8 @@
//============ KMdiChildArea ============//
-KMdiChildArea::KMdiChildArea( TQWidget *parent )
- : TQFrame( parent, "kmdi_childarea" )
+KMdiChildArea::KMdiChildArea( TQWidget *tqparent )
+ : TQFrame( tqparent, "kmdi_childarea" )
{
setFrameStyle( TQFrame::Panel | TQFrame::Sunken );
m_captionFont = TQFont();
@@ -58,7 +58,7 @@ KMdiChildArea::KMdiChildArea( TQWidget *parent )
m_captionInactiveForeColor = KGlobalSettings::inactiveTextColor();
m_pZ = new TQPtrList<KMdiChildFrm>;
m_pZ->setAutoDelete( true );
- setFocusPolicy( ClickFocus );
+ setFocusPolicy( TQ_ClickFocus );
m_defaultChildFrmSize = TQSize( 400, 300 );
}
@@ -75,11 +75,11 @@ void KMdiChildArea::manageChild( KMdiChildFrm* child, bool show, bool cascade )
KMdiChildFrm* top = topChild();
//remove old references. There can be more than one so we remove them all
- if ( m_pZ->findRef( child ) != -1 )
+ if ( m_pZ->tqfindRef( child ) != -1 )
{
- //TQPtrList::find* moves current() to the found item
+ //TQPtrList::tqfind* moves current() to the found item
m_pZ->take();
- while ( m_pZ->findNextRef( child ) != -1 )
+ while ( m_pZ->tqfindNextRef( child ) != -1 )
m_pZ->take();
}
@@ -112,7 +112,7 @@ void KMdiChildArea::destroyChild( KMdiChildFrm *child, bool focusTop )
bool wasMaximized = ( child->state() == KMdiChildFrm::Maximized );
// destroy the old one
- TQObject::disconnect( child );
+ TQT_BASE_OBJECT_NAME::disconnect( child );
child->blockSignals( true );
m_pZ->setAutoDelete( false );
m_pZ->removeRef( child );
@@ -144,7 +144,7 @@ void KMdiChildArea::destroyChildButNotItsView( KMdiChildFrm* child, bool focusTo
bool wasMaximized = ( child->state() == KMdiChildFrm::Maximized );
// destroy the old one
- TQObject::disconnect( child );
+ TQT_BASE_OBJECT_NAME::disconnect( child );
child->unsetClient();
m_pZ->setAutoDelete( false );
m_pZ->removeRef( child );
@@ -181,7 +181,7 @@ void KMdiChildArea::setTopChild( KMdiChildFrm* child, bool /* bSetFocus */ )
m_pZ->removeRef( child );
m_pZ->setAutoDelete( true );
- //disable the labels of all the other children
+ //disable the labels of all the other tqchildren
TQPtrListIterator<KMdiChildFrm> it( *m_pZ );
for ( ; ( *it ); ++it )
( *it )->m_pCaption->setActive( false );
@@ -194,7 +194,7 @@ void KMdiChildArea::setTopChild( KMdiChildFrm* child, bool /* bSetFocus */ )
m_pZ->append( child );
int nChildAreaMinW = 0, nChildAreaMinH = 0;
- int nChildAreaMaxW = QWIDGETSIZE_MAX, nChildAreaMaxH = QWIDGETSIZE_MAX;
+ int nChildAreaMaxW = TQWIDGETSIZE_MAX, nChildAreaMaxH = TQWIDGETSIZE_MAX;
if ( topChildMaximized && child->m_pClient )
{
//the former top child is maximized, so maximize the new one
@@ -218,15 +218,19 @@ void KMdiChildArea::setTopChild( KMdiChildFrm* child, bool /* bSetFocus */ )
else
child->raise();
+#ifdef USE_QT4
+ child->m_pClient->setFocus();
+#else // USE_QT4
TQFocusEvent::setReason( TQFocusEvent::Other );
child->m_pClient->setFocus();
+#endif // USE_QT4
}
}
void KMdiChildArea::resizeEvent( TQResizeEvent* e )
{
- //If we have a maximized children at the top , adjust its size
+ //If we have a maximized tqchildren at the top , adjust its size
KMdiChildFrm* child = topChild();
if ( child && child->state() == KMdiChildFrm::Maximized )
{
@@ -240,7 +244,7 @@ void KMdiChildArea::resizeEvent( TQResizeEvent* e )
height() + child->m_pCaption->heightHint() + KMDI_CHILDFRM_SEPARATOR + KMDI_CHILDFRM_DOUBLE_BORDER );
}
- layoutMinimizedChildren();
+ tqlayoutMinimizedChildren();
TQWidget::resizeEvent( e );
}
@@ -249,7 +253,7 @@ void KMdiChildArea::resizeEvent( TQResizeEvent* e )
void KMdiChildArea::mousePressEvent( TQMouseEvent *e )
{
//Popup the window menu
- if ( e->button() & RightButton )
+ if ( e->button() & Qt::RightButton )
emit popupWindowMenu( mapToGlobal( e->pos() ) );
}
@@ -319,7 +323,7 @@ TQPoint KMdiChildArea::getCascadePoint( int indexOfWindow )
void KMdiChildArea::childMinimized( KMdiChildFrm *minimizedChild, bool wasMaximized )
{
//can't find the child in our list, so we don't care.
- if ( m_pZ->findRef( minimizedChild ) == -1 )
+ if ( m_pZ->tqfindRef( minimizedChild ) == -1 )
{
kdDebug( 760 ) << k_funcinfo << "child was minimized but wasn't in our list!" << endl;
return;
@@ -364,7 +368,7 @@ void KMdiChildArea::focusTopChild()
if ( !lastChild->m_pClient->hasFocus() )
{
- //disable the labels of all the other children
+ //disable the labels of all the other tqchildren
TQPtrListIterator<KMdiChildFrm> it ( *m_pZ );
for ( ; ( *it ); ++it )
{
@@ -420,10 +424,10 @@ void KMdiChildArea::cascadeMaximized()
childFrm->move( pnt );
TQSize curSize( width() - pnt.x(), height() - pnt.y() );
- if ( ( childFrm->minimumSize().width() > curSize.width() ) ||
- ( childFrm->minimumSize().height() > curSize.height() ) )
+ if ( ( childFrm->tqminimumSize().width() > curSize.width() ) ||
+ ( childFrm->tqminimumSize().height() > curSize.height() ) )
{
- childFrm->resize( childFrm->minimumSize() );
+ childFrm->resize( childFrm->tqminimumSize() );
}
else
childFrm->resize( curSize );
@@ -607,7 +611,7 @@ void KMdiChildArea::tileAnodine()
return ;
int numCols = int( sqrt( ( double ) numVisible ) ); // set columns to square root of visible count
- // create an array to form grid layout
+ // create an array to form grid tqlayout
int *numRows = new int[ numCols ];
int numCurCol = 0;
@@ -720,7 +724,7 @@ void KMdiChildArea::tileVertically()
}
-void KMdiChildArea::layoutMinimizedChildren()
+void KMdiChildArea::tqlayoutMinimizedChildren()
{
int posX = 0;
int posY = height();
@@ -738,7 +742,7 @@ void KMdiChildArea::layoutMinimizedChildren()
}
child->move( posX, posY - child->height() );
- posX = child->geometry().right();
+ posX = child->tqgeometry().right();
}
}
}
@@ -786,4 +790,4 @@ void KMdiChildArea::getCaptionColors( const TQPalette& /*pal*/, TQColor& activeB
inactiveFG = KGlobalSettings::inactiveTextColor();
}
-// kate: space-indent off; replace-tabs off; tab-width 4; indent-mode csands;
+// kate: space-indent off; tqreplace-tabs off; tab-width 4; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildarea.h b/lib/compatibility/kmdi/qextmdi/kmdichildarea.h
index 4a074889..ef1495e7 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildarea.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildarea.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Falk Brettschneider
@@ -49,12 +49,13 @@ class KMdiChildAreaPrivate;
* and manages the frame widgets of attached MDI views.
* All actions and stuff concerning only to childframes are handled here.
*/
-class KMDI_EXPORT KMdiChildArea : public QFrame
+class KMDI_EXPORT KMdiChildArea : public TQFrame
{
friend class KMdiChildFrmCaption;
friend class KMdiChildFrm;
Q_OBJECT
+ TQ_OBJECT
// attributes
public:
@@ -101,7 +102,7 @@ public:
/**
* Consruction. Note: This class needn't to know about KMdiMainFrm .
*/
- KMdiChildArea( TQWidget *parent );
+ KMdiChildArea( TQWidget *tqparent );
/**
* Destructor : THERE should be no child windows anymore...
@@ -137,13 +138,13 @@ public:
void setTopChild( KMdiChildFrm* child, bool setFocus = false );
/**
- * Returns the topmost child (the active one) or 0 if there are no children.
+ * Returns the topmost child (the active one) or 0 if there are no tqchildren.
* Note that the topmost child may be also hidded , if ALL the windows are minimized.
*/
inline KMdiChildFrm * topChild() const { return m_pZ->last(); }
/**
- * Returns the number of visible children
+ * Returns the number of visible tqchildren
*/
int getVisibleChildCount() const;
@@ -156,31 +157,31 @@ public:
/**
* Sets the MDI childframe window caption font
- * A relayout does not occur when using this function
+ * A retqlayout does not occur when using this function
*/
void setMdiCaptionFont( const TQFont &fnt );
/**
* Sets the foreground color of the active MDI childframe window caption
- * A relayout does not occur when using this function
+ * A retqlayout does not occur when using this function
*/
void setMdiCaptionActiveForeColor( const TQColor &clr );
/**
* Sets the background color of the active MDI childframe window captions
- * A relayout does not occur when using this function
+ * A retqlayout does not occur when using this function
*/
void setMdiCaptionActiveBackColor( const TQColor &clr );
/**
* Sets the foreground color of inactive MDI childframe window captions
- * A relayout does not occur when using this function
+ * A retqlayout does not occur when using this function
*/
void setMdiCaptionInactiveForeColor( const TQColor &clr );
/**
* Sets the background color of inactive MDI childframe window captions
- * A relayout does not occur when using this function
+ * A retqlayout does not occur when using this function
*/
void setMdiCaptionInactiveBackColor( const TQColor &clr );
@@ -239,9 +240,9 @@ public slots:
void tileVertically();
/**
- * Position and layout the minimized child frames
+ * Position and tqlayout the minimized child frames
*/
- void layoutMinimizedChildren();
+ void tqlayoutMinimizedChildren();
protected:
@@ -251,7 +252,7 @@ protected:
void tileAllInternal( int maxWnds );
/**
- * Automatically resizes a maximized MDI view and layouts the positions of minimized MDI views.
+ * Automatically resizes a maximized MDI view and tqlayouts the positions of minimized MDI views.
*/
virtual void resizeEvent( TQResizeEvent * );
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildfrm.cpp b/lib/compatibility/kmdi/qextmdi/kmdichildfrm.cpp
index 49378c18..d4926546 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildfrm.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildfrm.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// : 01/2003 by Jens Zurheide to allow switching
// between views based on timestamps
// 2000-2003 maintained by the KDevelop project
@@ -85,8 +85,8 @@
#include "kde2laptop_undockbutton.xpm"
-KMdiWin32IconButton::KMdiWin32IconButton( TQWidget* parent, const char* name )
- : TQLabel( parent, name )
+KMdiWin32IconButton::KMdiWin32IconButton( TQWidget* tqparent, const char* name )
+ : TQLabel( tqparent, name )
{}
//============ mousePressEvent ============//
@@ -98,8 +98,8 @@ void KMdiWin32IconButton::mousePressEvent( TQMouseEvent* )
//============ KMdiChildFrm ============//
-KMdiChildFrm::KMdiChildFrm( KMdiChildArea *parent )
- : TQFrame( parent, "kmdi_childfrm" )
+KMdiChildFrm::KMdiChildFrm( KMdiChildArea *tqparent )
+ : TQFrame( tqparent, "kmdi_childfrm" )
, m_pClient( 0L )
, m_pManager( 0L )
, m_pCaption( 0L )
@@ -129,7 +129,7 @@ KMdiChildFrm::KMdiChildFrm( KMdiChildArea *parent )
{
m_pCaption = new KMdiChildFrmCaption( this );
- m_pManager = parent;
+ m_pManager = tqparent;
m_pWinIcon = new KMdiWin32IconButton( m_pCaption, "kmdi_iconbutton_icon" );
m_pUnixIcon = new TQToolButton( m_pCaption, "kmdi_toolbutton_icon" );
@@ -149,15 +149,15 @@ KMdiChildFrm::KMdiChildFrm( KMdiChildArea *parent )
redecorateButtons();
- m_pWinIcon->setFocusPolicy( NoFocus );
- m_pUnixIcon->setFocusPolicy( NoFocus );
- m_pClose->setFocusPolicy( NoFocus );
- m_pMinimize->setFocusPolicy( NoFocus );
- m_pMaximize->setFocusPolicy( NoFocus );
- m_pUndock->setFocusPolicy( NoFocus );
+ m_pWinIcon->setFocusPolicy( TQ_NoFocus );
+ m_pUnixIcon->setFocusPolicy( TQ_NoFocus );
+ m_pClose->setFocusPolicy( TQ_NoFocus );
+ m_pMinimize->setFocusPolicy( TQ_NoFocus );
+ m_pMaximize->setFocusPolicy( TQ_NoFocus );
+ m_pUndock->setFocusPolicy( TQ_NoFocus );
setFrameStyle( TQFrame::WinPanel | TQFrame::Raised );
- setFocusPolicy( NoFocus );
+ setFocusPolicy( TQ_NoFocus );
setMouseTracking( true );
@@ -238,19 +238,19 @@ void KMdiChildFrm::setResizeCursor( int resizeCorner )
break;
case KMDI_RESIZE_LEFT:
case KMDI_RESIZE_RIGHT:
- TQApplication::setOverrideCursor( Qt::sizeHorCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeHorCursor, true );
break;
case KMDI_RESIZE_TOP:
case KMDI_RESIZE_BOTTOM:
- TQApplication::setOverrideCursor( Qt::sizeVerCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeVerCursor, true );
break;
case KMDI_RESIZE_TOPLEFT:
case KMDI_RESIZE_BOTTOMRIGHT:
- TQApplication::setOverrideCursor( Qt::sizeFDiagCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeFDiagCursor, true );
break;
case KMDI_RESIZE_BOTTOMLEFT:
case KMDI_RESIZE_TOPRIGHT:
- TQApplication::setOverrideCursor( Qt::sizeBDiagCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeBDiagCursor, true );
break;
}
}
@@ -278,15 +278,15 @@ void KMdiChildFrm::mouseMoveEvent( TQMouseEvent *e )
if ( !m_pClient )
return;
- if ( m_pClient->minimumSize() == m_pClient->maximumSize() )
+ if ( m_pClient->tqminimumSize() == m_pClient->tqmaximumSize() )
return;
if ( m_bResizing )
{
- if ( !( e->state() & RightButton ) && !( e->state() & MidButton ) )
+ if ( !( e->state() & Qt::RightButton ) && !( e->state() & Qt::MidButton ) )
{
// same as: if no button or left button pressed
- TQPoint p = parentWidget()->mapFromGlobal( e->globalPos() );
+ TQPoint p = tqparentWidget()->mapFromGlobal( e->globalPos() );
resizeWindow( m_iResizeCorner, p.x(), p.y() );
}
else
@@ -323,17 +323,17 @@ void KMdiChildFrm::resizeWindow( int resizeCorner, int xPos, int yPos )
// Calculate the minimum width & height
int minWidth = 0;
int minHeight = 0;
- int maxWidth = QWIDGETSIZE_MAX;
- int maxHeight = QWIDGETSIZE_MAX;
+ int maxWidth = TQWIDGETSIZE_MAX;
+ int maxHeight = TQWIDGETSIZE_MAX;
// it could be the client forces the childframe to enlarge its minimum size
if ( m_pClient )
{
- minWidth = m_pClient->minimumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER;
- minHeight = m_pClient->minimumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
+ minWidth = m_pClient->tqminimumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER;
+ minHeight = m_pClient->tqminimumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
m_pCaption->heightHint() + KMDI_CHILDFRM_SEPARATOR;
- maxWidth = m_pClient->maximumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER;
- maxHeight = m_pClient->maximumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
+ maxWidth = m_pClient->tqmaximumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER;
+ maxHeight = m_pClient->tqmaximumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
m_pCaption->heightHint() + KMDI_CHILDFRM_SEPARATOR;
}
@@ -521,22 +521,22 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
case Maximized:
m_pClient->m_stateChanged = true;
m_state = state;
- // client min / max size / layout behavior don't change
+ // client min / max size / tqlayout behavior don't change
// set frame max size indirectly by setting the clients max size to
// it's current value (calls setMaxSize() of frame)
- m_pClient->setMaximumSize( m_pClient->maximumSize().width(), m_pClient->maximumSize().height() );
+ m_pClient->setMaximumSize( m_pClient->tqmaximumSize().width(), m_pClient->tqmaximumSize().height() );
m_pMaximize->setPixmap( *m_pMaxButtonPixmap );
setGeometry( m_restoredRect );
break;
case Minimized:
m_pClient->m_stateChanged = true;
m_state = state;
- // restore client min / max size / layout behavior
+ // restore client min / max size / tqlayout behavior
m_pClient->setMinimumSize( m_oldClientMinSize.width(), m_oldClientMinSize.height() );
m_pClient->setMaximumSize( m_oldClientMaxSize.width(), m_oldClientMaxSize.height() );
- if ( m_pClient->layout() != 0L )
+ if ( m_pClient->tqlayout() != 0L )
{
- m_pClient->layout() ->setResizeMode( m_oldLayoutResizeMode );
+ m_pClient->tqlayout() ->setResizeMode( m_oldLayoutResizeMode );
}
m_pMinimize->setPixmap( *m_pMinButtonPixmap );
m_pMaximize->setPixmap( *m_pMaxButtonPixmap );
@@ -555,14 +555,14 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
{
m_pClient->m_stateChanged = true;
m_state = state;
- // restore client min / max size / layout behavior
+ // restore client min / max size / tqlayout behavior
m_pClient->setMinimumSize( m_oldClientMinSize.width(), m_oldClientMinSize.height() );
m_pClient->setMaximumSize( m_oldClientMaxSize.width(), m_oldClientMaxSize.height() );
- if ( m_pClient->layout() != 0L )
+ if ( m_pClient->tqlayout() != 0L )
{
- m_pClient->layout() ->setResizeMode( m_oldLayoutResizeMode );
+ m_pClient->tqlayout() ->setResizeMode( m_oldLayoutResizeMode );
}
- setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX );
+ setMaximumSize( TQWIDGETSIZE_MAX, TQWIDGETSIZE_MAX );
// reset to maximize-captionbar
m_pMaximize->setPixmap( *m_pRestoreButtonPixmap );
m_pMinimize->setPixmap( *m_pMinButtonPixmap );
@@ -581,8 +581,8 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
{
m_pClient->m_stateChanged = true;
m_state = state;
- // client min / max size / layout behavior don't change
- setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX );
+ // client min / max size / tqlayout behavior don't change
+ setMaximumSize( TQWIDGETSIZE_MAX, TQWIDGETSIZE_MAX );
m_pMaximize->setPixmap( *m_pRestoreButtonPixmap );
int nFrameWidth = KMDI_CHILDFRM_DOUBLE_BORDER;
int nFrameHeight = KMDI_CHILDFRM_DOUBLE_BORDER + KMDI_CHILDFRM_SEPARATOR +
@@ -590,7 +590,7 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
TQRect maximizedFrmRect( -m_pClient->x(), -m_pClient->y(),
m_pManager->width() + nFrameWidth,
m_pManager->height() + nFrameHeight );
- if ( geometry() != maximizedFrmRect )
+ if ( tqgeometry() != maximizedFrmRect )
{
setGeometry( maximizedFrmRect );
}
@@ -607,18 +607,18 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
case Maximized:
m_pClient->m_stateChanged = true;
m_state = state;
- // save client min / max size / layout behavior
- m_oldClientMinSize = m_pClient->minimumSize();
- m_oldClientMaxSize = m_pClient->maximumSize();
- if ( m_pClient->layout() != 0L )
+ // save client min / max size / tqlayout behavior
+ m_oldClientMinSize = m_pClient->tqminimumSize();
+ m_oldClientMaxSize = m_pClient->tqmaximumSize();
+ if ( m_pClient->tqlayout() != 0L )
{
- m_oldLayoutResizeMode = m_pClient->layout() ->resizeMode();
+ m_oldLayoutResizeMode = m_pClient->tqlayout() ->tqresizeMode();
}
m_pClient->setMinimumSize( 0, 0 );
m_pClient->setMaximumSize( 0, 0 );
- if ( m_pClient->layout() != 0L )
+ if ( m_pClient->tqlayout() != 0L )
{
- m_pClient->layout() ->setResizeMode( TQLayout::FreeResize );
+ m_pClient->tqlayout() ->setResizeMode( TQLayout::FreeResize );
}
switchToMinimizeLayout();
m_pManager->childMinimized( this, true );
@@ -626,19 +626,19 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
case Normal:
m_pClient->m_stateChanged = true;
m_state = state;
- // save client min / max size / layout behavior
- m_oldClientMinSize = m_pClient->minimumSize();
- m_oldClientMaxSize = m_pClient->maximumSize();
- if ( m_pClient->layout() != 0L )
+ // save client min / max size / tqlayout behavior
+ m_oldClientMinSize = m_pClient->tqminimumSize();
+ m_oldClientMaxSize = m_pClient->tqmaximumSize();
+ if ( m_pClient->tqlayout() != 0L )
{
- m_oldLayoutResizeMode = m_pClient->layout() ->resizeMode();
+ m_oldLayoutResizeMode = m_pClient->tqlayout() ->tqresizeMode();
}
- m_restoredRect = geometry();
+ m_restoredRect = tqgeometry();
m_pClient->setMinimumSize( 0, 0 );
m_pClient->setMaximumSize( 0, 0 );
- if ( m_pClient->layout() != 0L )
+ if ( m_pClient->tqlayout() != 0L )
{
- m_pClient->layout() ->setResizeMode( TQLayout::FreeResize );
+ m_pClient->tqlayout() ->setResizeMode( TQLayout::FreeResize );
}
switchToMinimizeLayout();
m_pManager->childMinimized( this, false );
@@ -664,7 +664,7 @@ void KMdiChildFrm::setState( MdiWindowState state, bool /*bAnimate*/ )
else
{
m_pManager->setMinimumSize( 0, 0 );
- m_pManager->setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX );
+ m_pManager->setMaximumSize( TQWIDGETSIZE_MAX, TQWIDGETSIZE_MAX );
}
}
@@ -694,7 +694,7 @@ void KMdiChildFrm::setCaption( const TQString& text )
void KMdiChildFrm::enableClose( bool bEnable )
{
m_pClose->setEnabled( bEnable );
- m_pClose->repaint( false );
+ m_pClose->tqrepaint( false );
}
//============ setIcon ==================//
@@ -705,7 +705,7 @@ void KMdiChildFrm::setIcon( const TQPixmap& pxm )
if ( p.width() != 18 || p.height() != 18 )
{
TQImage img = p.convertToImage();
- p = img.smoothScale( 18, 18, TQImage::ScaleMin );
+ p = img.smoothScale( 18, 18, TQ_ScaleMin );
}
const bool do_resize = m_pIconButtonPixmap->size() != p.size();
*m_pIconButtonPixmap = p;
@@ -750,7 +750,7 @@ void KMdiChildFrm::setClient( KMdiChildView *w, bool bAutomaticResize )
}
// memorize the focuses in a dictionary because they will get lost during reparenting
- TQDict<FocusPolicy>* pFocPolDict = new TQDict<FocusPolicy>;
+ TQDict<TQ_FocusPolicy>* pFocPolDict = new TQDict<TQ_FocusPolicy>;
pFocPolDict->setAutoDelete( true );
TQObjectList *list = m_pClient->queryList( TQWIDGET_OBJECT_NAME_STRING );
TQObjectListIt it( *list ); // iterate over the buttons
@@ -768,21 +768,21 @@ void KMdiChildFrm::setClient( KMdiChildView *w, bool bAutomaticResize )
widg->setName( tmpStr.latin1() );
i++;
}
- FocusPolicy* pFocPol = new FocusPolicy;
+ TQ_FocusPolicy* pFocPol = new TQ_FocusPolicy;
*pFocPol = widg->focusPolicy();
pFocPolDict->insert( widg->name(), pFocPol );
}
delete list; // delete the list, not the objects
- //Reparent if needed
- if ( w->parent() != this )
+ //Retqparent if needed
+ if ( TQT_BASE_OBJECT(w->tqparent()) != TQT_BASE_OBJECT(this) )
{
//reparent to this widget , no flags , point , show it
TQPoint pnt2( KMDI_CHILDFRM_BORDER, clientYPos );
- TQSize mincs = w->minimumSize();
- TQSize maxcs = w->maximumSize();
+ TQSize mincs = w->tqminimumSize();
+ TQSize maxcs = w->tqmaximumSize();
w->setMinimumSize( 0, 0 );
- w->setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX );
+ w->setMaximumSize( TQWIDGETSIZE_MAX, TQWIDGETSIZE_MAX );
// min/max sizes, flags, DND get lost. :-(
w->reparent( this, 0, pnt2, w->isVisible() );
@@ -798,11 +798,11 @@ void KMdiChildFrm::setClient( KMdiChildView *w, bool bAutomaticResize )
TQObject::connect( m_pClient, TQT_SIGNAL( mdiParentNowMaximized( bool ) ), m_pManager, TQT_SIGNAL( nowMaximized( bool ) ) );
if ( m_pClient->minimumWidth() > m_pManager->m_defaultChildFrmSize.width() )
- setMinimumWidth( m_pClient->minimumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER );
+ setMinimumWidth( m_pClient->tqminimumSize().width() + KMDI_CHILDFRM_DOUBLE_BORDER );
if ( m_pClient->minimumHeight() > m_pManager->m_defaultChildFrmSize.height() )
{
- setMinimumHeight( m_pClient->minimumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
+ setMinimumHeight( m_pClient->tqminimumSize().height() + KMDI_CHILDFRM_DOUBLE_BORDER +
m_pCaption->heightHint() + KMDI_CHILDFRM_SEPARATOR );
}
}
@@ -817,7 +817,7 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
TQObject::disconnect( m_pClient, TQT_SIGNAL( mdiParentNowMaximized( bool ) ), m_pManager, TQT_SIGNAL( nowMaximized( bool ) ) );
//reparent to desktop widget , no flags , point , show it
- TQDict<FocusPolicy>* pFocPolDict;
+ TQDict<TQ_FocusPolicy>* pFocPolDict;
pFocPolDict = unlinkChildren();
// get name of focused child widget
@@ -826,8 +826,8 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
if ( focusedChildWidget != 0 )
nameOfFocusedWidget = focusedChildWidget->name();
- TQSize mins = m_pClient->minimumSize();
- TQSize maxs = m_pClient->maximumSize();
+ TQSize mins = m_pClient->tqminimumSize();
+ TQSize maxs = m_pClient->tqmaximumSize();
m_pClient->reparent( 0, 0, mapToGlobal( pos() ) - pos() + positionOffset, isVisible() );
m_pClient->setMinimumSize( mins.width(), mins.height() );
m_pClient->setMaximumSize( maxs.width(), maxs.height() );
@@ -842,7 +842,7 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
{ // for each found object...
TQWidget * widg = ( TQWidget* ) obj;
++it;
- FocusPolicy* pFocPol = pFocPolDict->find( widg->name() ); // remember the focus policy from before the reparent
+ TQ_FocusPolicy* pFocPol = pFocPolDict->tqfind( widg->name() ); // remember the focus policy from before the reparent
if ( pFocPol )
widg->setFocusPolicy( *pFocPol );
@@ -851,7 +851,7 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
widg->setFocus();
// get first and last focusable widget
- if ( ( widg->focusPolicy() == TQWidget::StrongFocus ) || ( widg->focusPolicy() == TQWidget::TabFocus ) )
+ if ( ( widg->focusPolicy() == TQ_StrongFocus ) || ( widg->focusPolicy() == TQ_TabFocus ) )
{
if ( firstFocusableChildWidget == 0 )
firstFocusableChildWidget = widg; // first widget
@@ -860,7 +860,7 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
}
else
{
- if ( widg->focusPolicy() == TQWidget::WheelFocus )
+ if ( widg->focusPolicy() == TQ_WheelFocus )
{
if ( firstFocusableChildWidget == 0 )
firstFocusableChildWidget = widg; // first widget
@@ -877,14 +877,14 @@ void KMdiChildFrm::unsetClient( TQPoint positionOffset )
m_pClient->setLastFocusableChildWidget( lastFocusableChildWidget );
// reset the focus policy of the view
- m_pClient->setFocusPolicy( TQWidget::ClickFocus );
+ m_pClient->setFocusPolicy( TQ_ClickFocus );
// lose information about the view (because it's undocked now)
m_pClient = 0;
}
//============== linkChildren =============//
-void KMdiChildFrm::linkChildren( TQDict<FocusPolicy>* pFocPolDict )
+void KMdiChildFrm::linkChildren( TQDict<TQ_FocusPolicy>* pFocPolDict )
{
// reset the focus policies for all widgets in the view (take them from the dictionary)
TQObjectList* list = m_pClient->queryList( TQWIDGET_OBJECT_NAME_STRING );
@@ -894,7 +894,7 @@ void KMdiChildFrm::linkChildren( TQDict<FocusPolicy>* pFocPolDict )
{ // for each found object...
TQWidget* widg = ( TQWidget* ) obj;
++it;
- FocusPolicy* pFocPol = pFocPolDict->find( widg->name() ); // remember the focus policy from before the reparent
+ TQ_FocusPolicy* pFocPol = pFocPolDict->tqfind( widg->name() ); // remember the focus policy from before the reparent
if ( pFocPol != 0 )
widg->setFocusPolicy( *pFocPol );
@@ -907,14 +907,14 @@ void KMdiChildFrm::linkChildren( TQDict<FocusPolicy>* pFocPolDict )
delete pFocPolDict;
// reset the focus policies for the rest
- m_pWinIcon->setFocusPolicy( TQWidget::NoFocus );
- m_pUnixIcon->setFocusPolicy( TQWidget::NoFocus );
- m_pClient->setFocusPolicy( TQWidget::ClickFocus );
- m_pCaption->setFocusPolicy( TQWidget::NoFocus );
- m_pUndock->setFocusPolicy( TQWidget::NoFocus );
- m_pMinimize->setFocusPolicy( TQWidget::NoFocus );
- m_pMaximize->setFocusPolicy( TQWidget::NoFocus );
- m_pClose->setFocusPolicy( TQWidget::NoFocus );
+ m_pWinIcon->setFocusPolicy( TQ_NoFocus );
+ m_pUnixIcon->setFocusPolicy( TQ_NoFocus );
+ m_pClient->setFocusPolicy( TQ_ClickFocus );
+ m_pCaption->setFocusPolicy( TQ_NoFocus );
+ m_pUndock->setFocusPolicy( TQ_NoFocus );
+ m_pMinimize->setFocusPolicy( TQ_NoFocus );
+ m_pMaximize->setFocusPolicy( TQ_NoFocus );
+ m_pClose->setFocusPolicy( TQ_NoFocus );
// install the event filter (catch mouse clicks) for the rest
m_pWinIcon->installEventFilter( this );
@@ -930,10 +930,10 @@ void KMdiChildFrm::linkChildren( TQDict<FocusPolicy>* pFocPolDict )
//============== unlinkChildren =============//
-TQDict<TQWidget::FocusPolicy>* KMdiChildFrm::unlinkChildren()
+TQDict<TQ_FocusPolicy>* KMdiChildFrm::unlinkChildren()
{
// memorize the focuses in a dictionary because they will get lost during reparenting
- TQDict<FocusPolicy>* pFocPolDict = new TQDict<FocusPolicy>;
+ TQDict<TQ_FocusPolicy>* pFocPolDict = new TQDict<TQ_FocusPolicy>;
pFocPolDict->setAutoDelete( true );
TQObjectList *list = m_pClient->queryList( TQWIDGET_OBJECT_NAME_STRING );
@@ -953,7 +953,7 @@ TQDict<TQWidget::FocusPolicy>* KMdiChildFrm::unlinkChildren()
w->setName( tmpStr.latin1() );
i++;
}
- FocusPolicy* pFocPol = new FocusPolicy;
+ TQ_FocusPolicy* pFocPol = new TQ_FocusPolicy;
*pFocPol = w->focusPolicy();
// memorize focus policy
pFocPolDict->insert( w->name(), pFocPol );
@@ -1005,7 +1005,7 @@ void KMdiChildFrm::doResize( bool captionOnly )
TQWidget* pIconWidget = m_pWinIcon;
m_pCaption->setGeometry( KMDI_CHILDFRM_BORDER, KMDI_CHILDFRM_BORDER, captionWidth, captionHeight );
- //The buttons are caption children
+ //The buttons are caption tqchildren
if ( KMdiMainFrm::frameDecorOfAttachedViews() == KMdi::Win95Look )
{
rightOffset2 += 2;
@@ -1068,7 +1068,7 @@ void KMdiChildFrm::doResize( bool captionOnly )
static bool hasParent( TQObject* par, TQObject* o )
{
while ( o && o != par )
- o = o->parent();
+ o = o->tqparent();
return o == par;
}
@@ -1085,8 +1085,8 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
TQObject* pObj = obj;
while ( ( pObj != 0L ) && !bIsChild )
{
- bIsChild = ( pObj == this );
- pObj = pObj->parent();
+ bIsChild = ( TQT_BASE_OBJECT(pObj) == TQT_BASE_OBJECT(this) );
+ pObj = pObj->tqparent();
}
// unset the resize cursor if the cursor moved from the frame into a inner widget
if ( bIsChild )
@@ -1095,33 +1095,33 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
break;
case TQEvent::MouseButtonPress:
{
- if ( !hasParent( m_pClient, obj ) )
+ if ( !hasParent( TQT_TQOBJECT(m_pClient), TQT_TQOBJECT(obj) ) )
{
bool bIsSecondClick = false;
if ( m_timeMeasure.elapsed() <= TQApplication::doubleClickInterval() )
bIsSecondClick = true; // of a possible double click
- if ( !( ( ( obj == m_pWinIcon ) || ( obj == m_pUnixIcon ) ) && bIsSecondClick ) )
+ if ( !( ( ( TQT_BASE_OBJECT(obj) == m_pWinIcon ) || ( TQT_BASE_OBJECT(obj) == m_pUnixIcon ) ) && bIsSecondClick ) )
{
// in case we didn't click on the icon button
TQFocusEvent* pFE = new TQFocusEvent( TQFocusEvent::FocusIn );
- TQApplication::sendEvent( qApp->mainWidget(), pFE );
+ TQApplication::sendEvent( tqApp->mainWidget(), pFE );
if ( m_pClient )
{
m_pClient->updateTimeStamp();
m_pClient->activate();
}
- if ( ( obj->parent() != m_pCaption ) && ( obj != m_pCaption ) )
+ if ( ( TQT_BASE_OBJECT(obj->tqparent()) != TQT_BASE_OBJECT(m_pCaption) ) && ( TQT_BASE_OBJECT(obj) != TQT_BASE_OBJECT(m_pCaption) ) )
{
TQWidget* w = ( TQWidget* ) obj;
- if ( ( w->focusPolicy() == TQWidget::ClickFocus ) || ( w->focusPolicy() == TQWidget::StrongFocus ) )
+ if ( ( w->focusPolicy() == TQ_ClickFocus ) || ( w->focusPolicy() == TQ_StrongFocus ) )
{
w->setFocus();
}
}
}
- if ( ( obj == m_pWinIcon ) || ( obj == m_pUnixIcon ) )
+ if ( ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(m_pWinIcon) ) || ( TQT_TQOBJECT(obj) == TQT_BASE_OBJECT(m_pUnixIcon) ) )
{
// in case we clicked on the icon button
if ( m_timeMeasure.elapsed() > TQApplication::doubleClickInterval() )
@@ -1139,7 +1139,7 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
break;
case TQEvent::Resize:
{
- if ( ( ( TQWidget* ) obj == m_pClient ) && ( m_state == Normal ) )
+ if ( ( ( TQWidget* ) TQT_TQOBJECT(obj) == m_pClient ) && ( m_state == Normal ) )
{
TQResizeEvent* re = ( TQResizeEvent* ) e;
int captionHeight = m_pCaption->heightHint();
@@ -1153,8 +1153,8 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
case TQEvent::ChildRemoved:
{
// if we lost a child we uninstall ourself as event filter for the lost
- // child and its children
- TQObject* pLostChild = ( ( TQChildEvent* ) e )->child();
+ // child and its tqchildren
+ TQObject* pLostChild = TQT_TQOBJECT(( ( TQChildEvent* ) e )->child());
if ( ( pLostChild != 0L ) /*&& (pLostChild->inherits(TQWIDGET_OBJECT_NAME_STRING))*/ )
{
TQObjectList* list = pLostChild->queryList();
@@ -1174,12 +1174,12 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
case TQEvent::ChildInserted:
{
// if we got a new child we install ourself as event filter for the new
- // child and its children (as we did when we got our client).
+ // child and its tqchildren (as we did when we got our client).
// XXX see linkChildren() and focus policy stuff
- TQObject* pNewChild = ( ( TQChildEvent* ) e ) ->child();
- if ( ( pNewChild != 0L ) && ::qt_cast<TQWidget*>( pNewChild ) )
+ TQObject* pNewChild = TQT_TQOBJECT(( ( TQChildEvent* ) e ) ->child());
+ if ( ( pNewChild != 0L ) && ::tqqt_cast<TQWidget*>( pNewChild ) )
{
- TQWidget * pNewWidget = static_cast<TQWidget*>( pNewChild );
+ TQWidget * pNewWidget = TQT_TQWIDGET( pNewChild );
TQObjectList *list = pNewWidget->queryList( TQWIDGET_OBJECT_NAME_STRING );
list->insert( 0, pNewChild ); // add the new child to the list too, just to save code
TQObjectListIt it( *list ); // iterate over all new child widgets
@@ -1188,7 +1188,7 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
{ // for each found object...
TQWidget * widg = ( TQWidget* ) obj;
++it;
- if ( !::qt_cast<TQPopupMenu*>( widg ) )
+ if ( !::tqqt_cast<TQPopupMenu*>( widg ) )
{
widg->installEventFilter( this );
}
@@ -1201,7 +1201,7 @@ bool KMdiChildFrm::eventFilter( TQObject *obj, TQEvent *e )
break;
}
- return false; // standard event processing (see Qt documentation)
+ return false; // standard event processing (see TQt documentation)
}
//============= raiseAndActivate ===============//
@@ -1284,9 +1284,9 @@ void KMdiChildFrm::showSystemMenu()
TQRect iconGeom;
if ( KMdiMainFrm::frameDecorOfAttachedViews() == KMdi::Win95Look )
- iconGeom = m_pWinIcon->geometry();
+ iconGeom = m_pWinIcon->tqgeometry();
else
- iconGeom = m_pUnixIcon->geometry();
+ iconGeom = m_pUnixIcon->tqgeometry();
popupmenuPosition = TQPoint( iconGeom.x(), iconGeom.y() + captionHeight() + KMDI_CHILDFRM_BORDER );
systemMenu() ->popup( mapToGlobal( popupmenuPosition ) );
@@ -1308,7 +1308,7 @@ void KMdiChildFrm::switchToMinimizeLayout()
resize( 300, minimumHeight() );
// positioning
- m_pManager->layoutMinimizedChildren();
+ m_pManager->tqlayoutMinimizedChildren();
}
void KMdiChildFrm::slot_resizeViaSystemMenu()
@@ -1394,7 +1394,7 @@ void KMdiChildFrm::redecorateButtons()
TQRect KMdiChildFrm::mdiAreaContentsRect() const
{
- TQFrame * p = ( TQFrame* ) parentWidget();
+ TQFrame * p = ( TQFrame* ) tqparentWidget();
if ( p )
{
return p->contentsRect();
@@ -1406,4 +1406,4 @@ TQRect KMdiChildFrm::mdiAreaContentsRect() const
}
}
-// kate: indent-mode csands; tab-width 4; space-indent off; replace-tabs off;
+// kate: indent-mode csands; tab-width 4; space-indent off; tqreplace-tabs off;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildfrm.h b/lib/compatibility/kmdi/qextmdi/kmdichildfrm.h
index 23435479..535804e8 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildfrm.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildfrm.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
// patches : */2000 Lars Beikirch (Lars.Beikirch@gmx.net)
//
@@ -49,11 +49,12 @@ class TQToolButton;
* @short Internal class, only used on Win32.
* This class provides a label widget that can process mouse click events.
*/
-class KMDI_EXPORT KMdiWin32IconButton : public QLabel
+class KMDI_EXPORT KMdiWin32IconButton : public TQLabel
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMdiWin32IconButton( TQWidget* parent, const char* name = 0 );
+ KMdiWin32IconButton( TQWidget* tqparent, const char* name = 0 );
virtual void mousePressEvent( TQMouseEvent* );
signals:
@@ -68,7 +69,7 @@ signals:
* @short a TQCustomEvent for move
* This special event will be useful, to inform view about child frame event.
*/
-class KMDI_EXPORT KMdiChildFrmMoveEvent : public QCustomEvent
+class KMDI_EXPORT KMdiChildFrmMoveEvent : public TQCustomEvent
{
public:
KMdiChildFrmMoveEvent( TQMoveEvent *e ) : TQCustomEvent( TQEvent::Type( TQEvent::User + int( KMdi::EV_Move ) ), e ) {}
@@ -80,7 +81,7 @@ public:
* @short a TQCustomEvent for begin of dragging
* This special event will be useful, to inform view about child frame event.
*/
-class KMDI_EXPORT KMdiChildFrmDragBeginEvent : public QCustomEvent
+class KMDI_EXPORT KMdiChildFrmDragBeginEvent : public TQCustomEvent
{
public:
KMdiChildFrmDragBeginEvent( TQMouseEvent *e ) : TQCustomEvent( TQEvent::Type( TQEvent::User + int( KMdi::EV_DragBegin ) ), e ) {}
@@ -91,7 +92,7 @@ public:
* @short a TQCustomEvent for end of dragging
* This special event will be useful, to inform view about child frame event.
*/
-class KMDI_EXPORT KMdiChildFrmDragEndEvent : public QCustomEvent
+class KMDI_EXPORT KMdiChildFrmDragEndEvent : public TQCustomEvent
{
public:
KMdiChildFrmDragEndEvent( TQMouseEvent *e ) : TQCustomEvent( TQEvent::Type( TQEvent::User + int( KMdi::EV_DragEnd ) ), e ) {}
@@ -102,7 +103,7 @@ public:
* @short a TQCustomEvent for begin of resizing
* This special event will be useful, to inform view about child frame event.
*/
-class KMDI_EXPORT KMdiChildFrmResizeBeginEvent : public QCustomEvent
+class KMDI_EXPORT KMdiChildFrmResizeBeginEvent : public TQCustomEvent
{
public:
KMdiChildFrmResizeBeginEvent( TQMouseEvent *e ) : TQCustomEvent( TQEvent::Type( TQEvent::User + int( KMdi::EV_ResizeBegin ) ), e ) {}
@@ -113,7 +114,7 @@ public:
* @short a TQCustomEvent for end of resizing
* This special event will be useful, to inform view about child frame event.
*/
-class KMDI_EXPORT KMdiChildFrmResizeEndEvent : public QCustomEvent
+class KMDI_EXPORT KMdiChildFrmResizeEndEvent : public TQCustomEvent
{
public:
KMdiChildFrmResizeEndEvent( TQMouseEvent *e ) : TQCustomEvent( TQEvent::Type( TQEvent::User + int( KMdi::EV_ResizeEnd ) ), e ) {}
@@ -127,12 +128,13 @@ class KMdiChildFrmPrivate;
* It's an MDI child frame widget. It contains a view widget and a frame caption. Usually you derive from its view.
*/
//------------------------------------------------------------------------------
-class KMDI_EXPORT KMdiChildFrm : public QFrame
+class KMDI_EXPORT KMdiChildFrm : public TQFrame
{
friend class KMdiChildArea;
friend class KMdiChildFrmCaption;
Q_OBJECT
+ TQ_OBJECT
// attributes
public:
@@ -183,7 +185,7 @@ public:
/**
* Creates a new KMdiChildFrm class.
*/
- KMdiChildFrm( KMdiChildArea *parent );
+ KMdiChildFrm( KMdiChildArea *tqparent );
/**
* Destroys this KMdiChildFrm
@@ -192,14 +194,14 @@ public:
~KMdiChildFrm();
/**
- * Reparents the widget w to this KMdiChildFrm (if this is not already done)
+ * Retqparents the widget w to this KMdiChildFrm (if this is not already done)
* Installs an event filter to catch focus events.
* Resizes this mdi child in a way that the child fits perfectly in.
*/
void setClient( KMdiChildView *w, bool bAutomaticResize = false );
/**
- * Reparents the client widget to 0 (desktop), moves with an offset from the original position
+ * Retqparents the client widget to 0 (desktop), moves with an offset from the original position
* Removes the event filter.
*/
void unsetClient( TQPoint positionOffset = TQPoint( 0, 0 ) );
@@ -240,17 +242,17 @@ public:
inline MdiWindowState state() const { return m_state; }
/**
- * Returns the inner client area of the parent of this (which is KMdiChildArea).
+ * Returns the inner client area of the tqparent of this (which is KMdiChildArea).
*/
TQRect mdiAreaContentsRect() const;
/**
- * Returns the geometry that will be restored by calling restore().
+ * Returns the tqgeometry that will be restored by calling restore().
*/
TQRect restoreGeometry() const;
/**
- * Sets the geometry that will be restored by calling restore().
+ * Sets the tqgeometry that will be restored by calling restore().
*/
void setRestoreGeometry( const TQRect& newRestGeo );
@@ -306,7 +308,7 @@ protected:
/**
* Reimplemented from the base class.
- * Resizes the captionbar, relayouts the position of the system buttons,
+ * Resizes the captionbar, retqlayouts the position of the system buttons,
* and calls resize for its embedded KMdiChildView with the proper size
*/
virtual void resizeEvent( TQResizeEvent * );
@@ -352,7 +354,7 @@ protected:
virtual bool eventFilter( TQObject*, TQEvent* );
/**
- * Calculates the new geometry from the new mouse position given as parameters
+ * Calculates the new tqgeometry from the new mouse position given as parameters
* and calls KMdiChildFrm::setGeometry
*/
void resizeWindow( int resizeCorner, int x, int y );
@@ -422,13 +424,13 @@ protected:
* Restore the focus policies for _all_ widgets in the view using the list given as parameter.
* Install the event filter for all direct child widgets of this. (See KMdiChildFrm::eventFilter)
*/
- void linkChildren( TQDict<FocusPolicy>* pFocPolDict );
+ void linkChildren( TQDict<TQ_FocusPolicy>* pFocPolDict );
/**
* Backups all focus policies of _all_ child widgets in the MDI childview since they get lost during a reparent.
* Remove all event filters for all direct child widgets of this. (See KMdiChildFrm::eventFilter)
*/
- TQDict<TQWidget::FocusPolicy>* unlinkChildren();
+ TQDict<TQ_FocusPolicy>* unlinkChildren();
/**
* Calculates the corner id for the resize cursor. The return value can be tested for:
@@ -443,4 +445,4 @@ private:
#endif //_KMDICHILDFRM_H_
-// kate: space-indent off; replace-tabs off; tab-width 4; indent-mode csands;
+// kate: space-indent off; tqreplace-tabs off; tab-width 4; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.cpp b/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.cpp
index 65d348f3..add999e9 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Szymon Stefanek (stefanek@tin.it)
@@ -41,7 +41,7 @@
#include <klocale.h>
#include <iostream>
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
//TODO: one day gradient can be added for win98/winnt5+
// ask system properties on windows
#ifndef SPI_GETGRADIENTCAPTIONS
@@ -65,14 +65,14 @@
//============== KMdiChildFrmCaption =============//
-KMdiChildFrmCaption::KMdiChildFrmCaption( KMdiChildFrm *parent )
- : TQWidget( parent, "kmdi_childfrmcaption" )
+KMdiChildFrmCaption::KMdiChildFrmCaption( KMdiChildFrm *tqparent )
+ : TQWidget( tqparent, "kmdi_childfrmcaption" )
{
m_szCaption = i18n( "Unnamed" );
m_bActive = false;
- m_pParent = parent;
+ m_pParent = tqparent;
setBackgroundMode( NoBackground );
- setFocusPolicy( NoFocus );
+ setFocusPolicy( TQ_NoFocus );
m_bChildInDrag = false;
}
@@ -85,17 +85,17 @@ KMdiChildFrmCaption::~KMdiChildFrmCaption()
void KMdiChildFrmCaption::mousePressEvent( TQMouseEvent *e )
{
- if ( e->button() == LeftButton )
+ if ( e->button() == Qt::LeftButton )
{
setMouseTracking( false );
if ( KMdiMainFrm::frameDecorOfAttachedViews() != KMdi::Win95Look )
{
- TQApplication::setOverrideCursor( Qt::sizeAllCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeAllCursor, true );
}
m_pParent->m_bDragging = true;
m_offset = mapToParent( e->pos() );
}
- else if ( e->button() == RightButton )
+ else if ( e->button() == Qt::RightButton )
{
m_pParent->systemMenu()->popup( mapToGlobal( e->pos() ) );
}
@@ -105,7 +105,7 @@ void KMdiChildFrmCaption::mousePressEvent( TQMouseEvent *e )
void KMdiChildFrmCaption::mouseReleaseEvent( TQMouseEvent *e )
{
- if ( e->button() == LeftButton )
+ if ( e->button() == Qt::LeftButton )
{
if ( KMdiMainFrm::frameDecorOfAttachedViews() != KMdi::Win95Look )
TQApplication::restoreOverrideCursor();
@@ -146,7 +146,7 @@ void KMdiChildFrmCaption::mouseMoveEvent( TQMouseEvent *e )
TQPoint relMousePosInChildArea = m_pParent->m_pManager->mapFromGlobal( e->globalPos() );
// mouse out of child area? stop child frame dragging
- if ( !m_pParent->m_pManager->rect().contains( relMousePosInChildArea ) )
+ if ( !TQT_TQRECT_OBJECT(m_pParent->m_pManager->rect()).tqcontains( relMousePosInChildArea ) )
{
if ( relMousePosInChildArea.x() < 0 )
relMousePosInChildArea.rx() = 0;
@@ -163,7 +163,7 @@ void KMdiChildFrmCaption::mouseMoveEvent( TQMouseEvent *e )
TQPoint mousePosInChildArea = relMousePosInChildArea - m_offset;
// set new child frame position
- parentWidget() ->move( mousePosInChildArea );
+ tqparentWidget() ->move( mousePosInChildArea );
}
//=============== setActive ===============//
@@ -182,7 +182,7 @@ void KMdiChildFrmCaption::setActive( bool bActive )
m_pParent->m_pManager->m_captionInactiveBackColor );
m_bActive = bActive;
- repaint( false );
+ tqrepaint( false );
}
//=============== setCaption ===============//
@@ -190,7 +190,7 @@ void KMdiChildFrmCaption::setActive( bool bActive )
void KMdiChildFrmCaption::setCaption( const TQString& text )
{
m_szCaption = text;
- repaint( false );
+ tqrepaint( false );
}
//============== heightHint ===============//
@@ -313,10 +313,10 @@ void KMdiChildFrmCaption::slot_moveViaSystemMenu()
grabMouse();
if ( KMdiMainFrm::frameDecorOfAttachedViews() != KMdi::Win95Look )
- TQApplication::setOverrideCursor( Qt::sizeAllCursor, true );
+ TQApplication::setOverrideCursor( TQt::sizeAllCursor, true );
m_pParent->m_bDragging = true;
m_offset = mapFromGlobal( TQCursor::pos() );
}
-// kate: space-indent off; replace-tabs off; indent-mode csands; tab-width 4;
+// kate: space-indent off; tqreplace-tabs off; indent-mode csands; tab-width 4;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.h b/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.h
index 4151f0c0..b3c8d88a 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildfrmcaption.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Falk Brettschneider
@@ -41,14 +41,15 @@ class KMdiChildFrmCaptionPrivate;
*
* It's the caption bar of a child frame widget.
*/
-class KMDI_EXPORT KMdiChildFrmCaption : public QWidget
+class KMDI_EXPORT KMdiChildFrmCaption : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructor
*/
- KMdiChildFrmCaption( KMdiChildFrm *parent );
+ KMdiChildFrmCaption( KMdiChildFrm *tqparent );
/**
* Destructor
@@ -88,7 +89,7 @@ protected:
virtual void mousePressEvent( TQMouseEvent * );
/**
- * Calls maximizePressed of the parent widget ( KMdiChildFrm )
+ * Calls maximizePressed of the tqparent widget ( KMdiChildFrm )
*/
virtual void mouseDoubleClickEvent( TQMouseEvent * );
@@ -117,7 +118,7 @@ public:
protected: // Protected attributes
/**
- * parent widget
+ * tqparent widget
*/
KMdiChildFrm *m_pParent;
@@ -127,7 +128,7 @@ protected: // Protected attributes
bool m_bActive;
/**
- * the position offset related to its parent widget (internally used for translating mouse move positions
+ * the position offset related to its tqparent widget (internally used for translating mouse move positions
*/
TQPoint m_offset;
@@ -142,4 +143,4 @@ private:
#endif //_KMDICAPTION_H_
-// kate: space-indent off; replace-tabs off; indent-mode csands; tab-width 4;
+// kate: space-indent off; tqreplace-tabs off; indent-mode csands; tab-width 4;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildview.cpp b/lib/compatibility/kmdi/qextmdi/kmdichildview.cpp
index 57c0bea4..ba80552a 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildview.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildview.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create a
-// -06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// -06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
// patches : 02/2000 by Massimo Morin (mmorin@schedsys.com)
// */2000 by Lars Beikirch (Lars.Beikirch@gmx.net)
@@ -44,8 +44,8 @@
//============ KMdiChildView ============//
-KMdiChildView::KMdiChildView( const TQString& caption, TQWidget* parentWidget, const char* name, WFlags f )
- : TQWidget( parentWidget, name, f )
+KMdiChildView::KMdiChildView( const TQString& caption, TQWidget* tqparentWidget, const char* name, WFlags f )
+ : TQWidget( tqparentWidget, name, f )
, m_focusedChildWidget( 0L )
, m_firstFocusableChildWidget( 0L )
, m_lastFocusableChildWidget( 0L )
@@ -63,7 +63,7 @@ KMdiChildView::KMdiChildView( const TQString& caption, TQWidget* parentWidget, c
m_szCaption = i18n( "Unnamed" );
m_sTabCaption = m_szCaption;
- setFocusPolicy( ClickFocus );
+ setFocusPolicy( TQ_ClickFocus );
installEventFilter( this );
// store the current time
@@ -73,8 +73,8 @@ KMdiChildView::KMdiChildView( const TQString& caption, TQWidget* parentWidget, c
//============ KMdiChildView ============//
-KMdiChildView::KMdiChildView( TQWidget* parentWidget, const char* name, WFlags f )
- : TQWidget( parentWidget, name, f )
+KMdiChildView::KMdiChildView( TQWidget* tqparentWidget, const char* name, WFlags f )
+ : TQWidget( tqparentWidget, name, f )
, m_focusedChildWidget( 0L )
, m_firstFocusableChildWidget( 0L )
, m_lastFocusableChildWidget( 0L )
@@ -87,7 +87,7 @@ KMdiChildView::KMdiChildView( TQWidget* parentWidget, const char* name, WFlags f
setGeometry( 0, 0, 0, 0 ); // reset
m_szCaption = i18n( "Unnamed" );
m_sTabCaption = m_szCaption;
- setFocusPolicy( ClickFocus );
+ setFocusPolicy( TQ_ClickFocus );
installEventFilter( this );
// store the current time
@@ -107,15 +107,15 @@ void KMdiChildView::trackIconAndCaptionChanges( TQWidget *view )
}
-//============== internal geometry ==============//
+//============== internal tqgeometry ==============//
TQRect KMdiChildView::internalGeometry() const
{
if ( mdiParent() )
{ // is attached
// get the client area coordinates inside the MDI child frame
- TQRect posInFrame = geometry();
- // map these values to the parent of the MDI child frame
+ TQRect posInFrame = tqgeometry();
+ // map these values to the tqparent of the MDI child frame
// (this usually is the MDI child area) and return
TQPoint ptTopLeft = mdiParent() ->mapToParent( posInFrame.topLeft() );
TQSize sz = size();
@@ -123,14 +123,14 @@ TQRect KMdiChildView::internalGeometry() const
}
else
{
- TQRect geo = geometry();
+ TQRect geo = tqgeometry();
TQRect frameGeo = externalGeometry();
return TQRect( frameGeo.x(), frameGeo.y(), geo.width(), geo.height() );
- // return geometry();
+ // return tqgeometry();
}
}
-//============== set internal geometry ==============//
+//============== set internal tqgeometry ==============//
void KMdiChildView::setInternalGeometry( const TQRect& newGeometry )
{
@@ -142,18 +142,18 @@ void KMdiChildView::setInternalGeometry( const TQRect& newGeometry )
int nFrameSizeTop = geo.y() - frameGeo.y();
int nFrameSizeLeft = geo.x() - frameGeo.x();
- // create the new geometry that is accepted by the TQWidget::setGeometry() method
- TQRect newGeoQt;
- newGeoQt.setX( newGeometry.x() - nFrameSizeLeft );
- newGeoQt.setY( newGeometry.y() - nFrameSizeTop );
+ // create the new tqgeometry that is accepted by the TQWidget::setGeometry() method
+ TQRect newGeoTQt;
+ newGeoTQt.setX( newGeometry.x() - nFrameSizeLeft );
+ newGeoTQt.setY( newGeometry.y() - nFrameSizeTop );
- newGeoQt.setWidth( newGeometry.width() + nFrameSizeLeft + KMDI_CHILDFRM_DOUBLE_BORDER / 2 );
- newGeoQt.setHeight( newGeometry.height() + nFrameSizeTop + KMDI_CHILDFRM_DOUBLE_BORDER / 2 );
- // newGeoQt.setWidth(newGeometry.width()+KMDI_MDI_CHILDFRM_DOUBLE_BORDER);
- // newGeoQt.setHeight(newGeometry.height()+mdiParent()->captionHeight()+KMDI_MDI_CHILDFRM_DOUBLE_BORDER);
+ newGeoTQt.setWidth( newGeometry.width() + nFrameSizeLeft + KMDI_CHILDFRM_DOUBLE_BORDER / 2 );
+ newGeoTQt.setHeight( newGeometry.height() + nFrameSizeTop + KMDI_CHILDFRM_DOUBLE_BORDER / 2 );
+ // newGeoTQt.setWidth(newGeometry.width()+KMDI_MDI_CHILDFRM_DOUBLE_BORDER);
+ // newGeoTQt.setHeight(newGeometry.height()+mdiParent()->captionHeight()+KMDI_MDI_CHILDFRM_DOUBLE_BORDER);
- // set the geometry
- mdiParent()->setGeometry( newGeoQt );
+ // set the tqgeometry
+ mdiParent()->setGeometry( newGeoTQt );
}
else
{
@@ -163,28 +163,28 @@ void KMdiChildView::setInternalGeometry( const TQRect& newGeometry )
int nFrameSizeTop = geo.y() - frameGeo.y();
int nFrameSizeLeft = geo.x() - frameGeo.x();
- // create the new geometry that is accepted by the TQWidget::setGeometry() method
- TQRect newGeoQt;
+ // create the new tqgeometry that is accepted by the TQWidget::setGeometry() method
+ TQRect newGeoTQt;
- newGeoQt.setX( newGeometry.x() - nFrameSizeLeft );
- newGeoQt.setY( newGeometry.y() - nFrameSizeTop );
+ newGeoTQt.setX( newGeometry.x() - nFrameSizeLeft );
+ newGeoTQt.setY( newGeometry.y() - nFrameSizeTop );
- newGeoQt.setWidth( newGeometry.width() );
- newGeoQt.setHeight( newGeometry.height() );
+ newGeoTQt.setWidth( newGeometry.width() );
+ newGeoTQt.setHeight( newGeometry.height() );
- // set the geometry
- setGeometry( newGeoQt );
+ // set the tqgeometry
+ setGeometry( newGeoTQt );
}
}
-//============== external geometry ==============//
+//============== external tqgeometry ==============//
TQRect KMdiChildView::externalGeometry() const
{
return mdiParent() ? mdiParent()->frameGeometry() : frameGeometry();
}
-//============== set external geometry ==============//
+//============== set external tqgeometry ==============//
void KMdiChildView::setExternalGeometry( const TQRect& newGeometry )
{
@@ -202,16 +202,16 @@ void KMdiChildView::setExternalGeometry( const TQRect& newGeometry )
int nFrameSizeTop = geo.y() - frameGeo.y();
int nFrameSizeLeft = geo.x() - frameGeo.x();
- // create the new geometry that is accepted by the TQWidget::setGeometry() method
+ // create the new tqgeometry that is accepted by the TQWidget::setGeometry() method
// not attached => the window system makes the frame
- TQRect newGeoQt;
- newGeoQt.setX( newGeometry.x() + nFrameSizeLeft );
- newGeoQt.setY( newGeometry.y() + nFrameSizeTop );
- newGeoQt.setWidth( newGeometry.width() - nTotalFrameWidth );
- newGeoQt.setHeight( newGeometry.height() - nTotalFrameHeight );
-
- // set the geometry
- setGeometry( newGeoQt );
+ TQRect newGeoTQt;
+ newGeoTQt.setX( newGeometry.x() + nFrameSizeLeft );
+ newGeoTQt.setY( newGeometry.y() + nFrameSizeTop );
+ newGeoTQt.setWidth( newGeometry.width() - nTotalFrameWidth );
+ newGeoTQt.setHeight( newGeometry.height() - nTotalFrameHeight );
+
+ // set the tqgeometry
+ setGeometry( newGeoTQt );
}
}
@@ -277,7 +277,7 @@ TQRect KMdiChildView::restoreGeometry()
if ( mdiParent() )
return mdiParent() ->restoreGeometry();
else //FIXME not really supported, may be we must use Windows or X11 funtions
- return geometry();
+ return tqgeometry();
}
//============== setRestoreGeometry ================//
@@ -362,7 +362,7 @@ void KMdiChildView::youAreDetached()
if ( myIconPtr() )
setIcon( *( myIconPtr() ) );
- setFocusPolicy( TQWidget::StrongFocus );
+ setFocusPolicy( TQ_StrongFocus );
emit isDetachedNow();
}
@@ -375,7 +375,7 @@ void KMdiChildView::setCaption( const TQString& szCaption )
m_szCaption = szCaption;
if ( mdiParent() )
mdiParent() ->setCaption( m_szCaption );
- else //have to call the parent one
+ else //have to call the tqparent one
TQWidget::setCaption( m_szCaption );
emit windowCaptionChanged( m_szCaption );
@@ -491,8 +491,8 @@ void KMdiChildView::slot_childDestroyed()
// do what we do if a child is removed
// if we lost a child we uninstall ourself as event filter for the lost
- // child and its children
- const TQObject * pLostChild = TQObject::sender();
+ // child and its tqchildren
+ const TQObject * pLostChild = TQT_TQOBJECT(TQT_BASE_OBJECT_NAME::sender());
if ( pLostChild && ( pLostChild->isWidgetType() ) )
{
TQObjectList* list = ( ( TQObject* ) ( pLostChild ) ) ->queryList( TQWIDGET_OBJECT_NAME_STRING );
@@ -523,11 +523,11 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
if ( e->type() == TQEvent::KeyPress && isAttached() )
{
TQKeyEvent* ke = ( TQKeyEvent* ) e;
- if ( ke->key() == Qt::Key_Tab )
+ if ( ke->key() == TQt::Key_Tab )
{
TQWidget* w = ( TQWidget* ) obj;
- FocusPolicy wfp = w->focusPolicy();
- if ( wfp == TQWidget::StrongFocus || wfp == TQWidget::TabFocus || w->focusPolicy() == TQWidget::WheelFocus )
+ TQ_FocusPolicy wfp = w->focusPolicy();
+ if ( wfp == TQ_StrongFocus || wfp == TQ_TabFocus || w->focusPolicy() == TQ_WheelFocus )
{
if ( m_lastFocusableChildWidget != 0 )
{
@@ -545,7 +545,7 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
if ( obj->isWidgetType() )
{
TQObjectList * list = queryList( TQWIDGET_OBJECT_NAME_STRING );
- if ( list->find( obj ) != -1 )
+ if ( list->tqfind( obj ) != -1 )
m_focusedChildWidget = ( TQWidget* ) obj;
delete list; // delete the list, not the objects
@@ -564,8 +564,8 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
else if ( e->type() == TQEvent::ChildRemoved )
{
// if we lost a child we uninstall ourself as event filter for the lost
- // child and its children
- TQObject * pLostChild = ( ( TQChildEvent* ) e ) ->child();
+ // child and its tqchildren
+ TQObject * pLostChild = TQT_TQOBJECT(( ( TQChildEvent* ) e ) ->child());
if ( ( pLostChild != 0L ) && ( pLostChild->isWidgetType() ) )
{
TQObjectList * list = pLostChild->queryList( TQWIDGET_OBJECT_NAME_STRING );
@@ -577,8 +577,8 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
TQWidget * widg = ( TQWidget* ) o;
++it;
widg->removeEventFilter( this );
- FocusPolicy wfp = widg->focusPolicy();
- if ( wfp == TQWidget::StrongFocus || wfp == TQWidget::TabFocus || widg->focusPolicy() == TQWidget::WheelFocus )
+ TQ_FocusPolicy wfp = widg->focusPolicy();
+ if ( wfp == TQ_StrongFocus || wfp == TQ_TabFocus || widg->focusPolicy() == TQ_WheelFocus )
{
if ( m_firstFocusableChildWidget == widg )
m_firstFocusableChildWidget = 0L; // reset first widget
@@ -593,13 +593,13 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
else if ( e->type() == TQEvent::ChildInserted )
{
// if we got a new child and we are attached to the MDI system we
- // install ourself as event filter for the new child and its children
+ // install ourself as event filter for the new child and its tqchildren
// (as we did when we were added to the MDI system).
- TQObject * pNewChild = ( ( TQChildEvent* ) e ) ->child();
+ TQObject * pNewChild = TQT_TQOBJECT(( ( TQChildEvent* ) e ) ->child());
if ( ( pNewChild != 0L ) && ( pNewChild->isWidgetType() ) )
{
TQWidget * pNewWidget = ( TQWidget* ) pNewChild;
- if ( pNewWidget->testWFlags( Qt::WType_Dialog | Qt::WShowModal ) )
+ if ( pNewWidget->testWFlags( TQt::WType_Dialog | TQt::WShowModal ) )
return false;
TQObjectList *list = pNewWidget->queryList( TQWIDGET_OBJECT_NAME_STRING );
list->insert( 0, pNewChild ); // add the new child to the list too, just to save code
@@ -611,8 +611,8 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
++it;
widg->installEventFilter( this );
connect( widg, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( slot_childDestroyed() ) );
- FocusPolicy wfp = widg->focusPolicy();
- if ( wfp == TQWidget::StrongFocus || wfp == TQWidget::TabFocus || widg->focusPolicy() == TQWidget::WheelFocus )
+ TQ_FocusPolicy wfp = widg->focusPolicy();
+ if ( wfp == TQ_StrongFocus || wfp == TQ_TabFocus || widg->focusPolicy() == TQ_WheelFocus )
{
if ( m_firstFocusableChildWidget == 0 )
m_firstFocusableChildWidget = widg; // first widge
@@ -628,14 +628,14 @@ bool KMdiChildView::eventFilter( TQObject *obj, TQEvent *e )
if ( e->type() == TQEvent::IconChange )
{
// qDebug("KMDiChildView:: TQEvent:IconChange intercepted\n");
- if ( obj == this )
+ if ( TQT_BASE_OBJECT(obj) == this )
iconUpdated( this, icon() ? ( *icon() ) : TQPixmap() );
- else if ( obj == m_trackChanges )
+ else if ( TQT_BASE_OBJECT(obj) == m_trackChanges )
setIcon( m_trackChanges->icon() ? ( *( m_trackChanges->icon() ) ) : TQPixmap() );
}
if ( e->type() == TQEvent::CaptionChange )
{
- if ( obj == this )
+ if ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(this) )
captionUpdated( this, caption() );
}
}
@@ -728,12 +728,12 @@ void KMdiChildView::setMaximumSize( int maxw, int maxh )
if ( mdiParent() && mdiParent()->state() == KMdiChildFrm::Normal )
{
int w = maxw + KMDI_CHILDFRM_DOUBLE_BORDER;
- if ( w > QWIDGETSIZE_MAX )
- w = QWIDGETSIZE_MAX;
+ if ( w > TQWIDGETSIZE_MAX )
+ w = TQWIDGETSIZE_MAX;
int h = maxh + KMDI_CHILDFRM_DOUBLE_BORDER + KMDI_CHILDFRM_SEPARATOR + mdiParent() ->captionHeight();
- if ( h > QWIDGETSIZE_MAX )
- h = QWIDGETSIZE_MAX;
+ if ( h > TQWIDGETSIZE_MAX )
+ h = TQWIDGETSIZE_MAX;
mdiParent()->setMaximumSize( w, h );
}
@@ -770,4 +770,4 @@ void KMdiChildView::raise()
TQWidget::raise();
}
-// kate: space-indent off; replace-tabs off; indent-mode csands; tab-width 4;
+// kate: space-indent off; tqreplace-tabs off; indent-mode csands; tab-width 4;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdichildview.h b/lib/compatibility/kmdi/qextmdi/kmdichildview.h
index 656c17fd..298b2198 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdichildview.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdichildview.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
// patches : 02/2000 by Massimo Morin (mmorin@schedsys.com)
// */2000 by Lars Beikirch (Lars.Beikirch@gmx.net)
@@ -49,7 +49,7 @@ class KMdiChildViewPrivate;
*
* All such windows 'lives' attached to a KMdiChildFrm widget
* managed by KMdiChildArea, or detached (managed by the window manager.)
- * So remember that the KMdiChildView::parent pointer may change, and may be 0L, too.
+ * So remember that the KMdiChildView::tqparent pointer may change, and may be 0L, too.
*
* There are 2 possibilities for you to put your widgets under MDI control:
*
@@ -71,14 +71,14 @@ class KMdiChildViewPrivate;
* KMdiChildView* pMDICover = new KMdiChildView( pNewView->caption());
* pMDICover->setIcon(icon);
* m_MDICoverList.append( pMDICover);
- * TQBoxLayout* pLayout = new TQHBoxLayout( pMDICover, 0, -1, "layout");
+ * TQBoxLayout* pLayout = new TQHBoxLayout( pMDICover, 0, -1, "tqlayout");
* pNewView->reparent( pMDICover, TQPoint(0,0));
* pLayout->addWidget( pNewView);
* pMDICover->setName( pNewView->name());
* // captions
* TQString shortName = pNewView->caption();
* int length = shortName.length();
- * shortName = shortName.right(length - (shortName.findRev('/') +1));
+ * shortName = shortName.right(length - (shortName.tqfindRev('/') +1));
* pMDICover->setTabCaption( shortName);
* pMDICover->setCaption(pNewView->caption());
*
@@ -105,11 +105,12 @@ class KMdiChildViewPrivate;
*
*/
-class KMDI_EXPORT KMdiChildView : public QWidget
+class KMDI_EXPORT KMdiChildView : public TQWidget
{
friend class KMdiMainFrm;
friend class KMdiChildFrm;
Q_OBJECT
+ TQ_OBJECT
// attributes
protected:
@@ -182,13 +183,13 @@ public:
/**
* Constructor
*/
- KMdiChildView( const TQString& caption, TQWidget* parentWidget = 0L, const char* name = 0L, WFlags f = 0 );
+ KMdiChildView( const TQString& caption, TQWidget* tqparentWidget = 0L, const char* name = 0L, WFlags f = 0 );
/**
* Constructor
* sets "Unnamed" as default caption
*/
- KMdiChildView( TQWidget* parentWidget = 0L, const char* name = 0L, WFlags f = 0 );
+ KMdiChildView( TQWidget* tqparentWidget = 0L, const char* name = 0L, WFlags f = 0 );
/**
* Destructor
@@ -253,7 +254,7 @@ public:
virtual void setMDICaption( const TQString &caption );
/**
- * Returns the KMdiChildFrm parent widget (or 0 if the window is not attached)
+ * Returns the KMdiChildFrm tqparent widget (or 0 if the window is not attached)
*/
KMdiChildFrm *mdiParent() const;
@@ -270,28 +271,28 @@ public:
bool isMaximized() const;
/**
- * Returns the geometry of this MDI child window as TQWidget::geometry() does.
+ * Returns the tqgeometry of this MDI child window as TQWidget::tqgeometry() does.
*/
TQRect internalGeometry() const;
/**
- * Sets the geometry of the client area of this MDI child window. The
+ * Sets the tqgeometry of the client area of this MDI child window. The
* top left position of the argument is the position of the top left point
- * of the client area in its parent coordinates and the arguments width
+ * of the client area in its tqparent coordinates and the arguments width
* and height is the width and height of the client area. Please note: This
* differs from the behavior of TQWidget::setGeometry()!
*/
void setInternalGeometry( const TQRect& newGeomety );
/**
- * Returns the frame geometry of this window or of the parent if there is any...
+ * Returns the frame tqgeometry of this window or of the tqparent if there is any...
*/
TQRect externalGeometry() const;
/**
- * Sets the geometry of the frame of this MDI child window. The top left
+ * Sets the tqgeometry of the frame of this MDI child window. The top left
* position of the argument is the position of the top left point of the
- * frame in its parent coordinates and the arguments width and height is
+ * frame in its tqparent coordinates and the arguments width and height is
* the width and height of the widget frame. Please note: This differs
* from the behavior of TQWidget::setGeometry()!
*/
@@ -315,12 +316,12 @@ public:
virtual void maximize( bool bAnimate );
/**
- * Returns the geometry that will be restored by calling restore().
+ * Returns the tqgeometry that will be restored by calling restore().
*/
TQRect restoreGeometry();
/**
- * Sets the geometry that will be restored by calling restore().
+ * Sets the tqgeometry that will be restored by calling restore().
*/
void setRestoreGeometry( const TQRect& newRestGeo );
@@ -358,7 +359,7 @@ public:
*/
inline void updateTimeStamp()
{
- m_time.setDate( TQDate::currentDate() );
+ m_time.setDate( TQDate::tqcurrentDate() );
m_time.setTime( TQTime::currentTime() );
}
@@ -424,17 +425,17 @@ public slots:
virtual void slot_clickedInDockMenu();
/**
- * Calls TQWidget::show but also for it's parent widget if attached
+ * Calls TQWidget::show but also for it's tqparent widget if attached
*/
virtual void show();
/**
- * Calls TQWidget::hide() or it's parent widget hide() if attached
+ * Calls TQWidget::hide() or it's tqparent widget hide() if attached
*/
virtual void hide();
/**
- * Calls TQWidget::raise() or it's parent widget raise() if attached
+ * Calls TQWidget::raise() or it's tqparent widget raise() if attached
*/
virtual void raise();
@@ -465,7 +466,7 @@ protected:
virtual void closeEvent( TQCloseEvent *e );
/**
- * It only catches TQEvent::KeyPress events there. If a Qt::Key_Tab is pressed, the internal MDI focus
+ * It only catches TQEvent::KeyPress events there. If a TQt::Key_Tab is pressed, the internal MDI focus
* handling is called. That means if the last focusable child widget of this is called, it will jump to the
* first focusable child widget of this.
* See KMdiChildView::setFirstFocusableChildWidget and KMdiChildView::lastFirstFocusableChildWidget
@@ -603,7 +604,7 @@ private:
inline KMdiChildFrm *KMdiChildView::mdiParent() const
{
- TQWidget * pw = parentWidget();
+ TQWidget * pw = tqparentWidget();
if ( pw != 0L )
if ( pw->inherits( "KMdiChildFrm" ) )
return ( KMdiChildFrm * ) pw;
@@ -612,4 +613,4 @@ inline KMdiChildFrm *KMdiChildView::mdiParent() const
#endif //_KMDICHILDVIEW_H_
-// kate: space-indent off; replace-tabs off; indent-mode csands; tab-width 4;
+// kate: space-indent off; tqreplace-tabs off; indent-mode csands; tab-width 4;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdidefines.h b/lib/compatibility/kmdi/qextmdi/kmdidefines.h
index 16be290a..ea4861ba 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdidefines.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdidefines.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// stand-alone Qt extension set of
-// classes and a Qt-based library
+// stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Falk Brettschneider
@@ -40,7 +40,7 @@
*/
namespace KMdi
{
- /** extent Qt events
+ /** extent TQt events
@see TQCustomEvent, TQEvent::User
\code
bool B_MyWidget::event( TQEvent* e) {
@@ -66,7 +66,7 @@ namespace KMdi
/**
* standard is: show normal, attached, visible, document view (not toolview). Maximize, Minimize, Hide adds
* appropriately. Detach adds a view that appears toplevel, ToolWindow adds the view as tool view.
- * That means it is stay-on-top and toplevel. UseKMdiSizeHint should use the restore geometry of the
+ * That means it is stay-on-top and toplevel. UseKMdiSizeHint should use the restore tqgeometry of the
* latest current top childframe but is not supported yet.
*/
StandardAdd = 0,
diff --git a/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.cpp b/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.cpp
index f541a824..ff24a983 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.cpp
@@ -49,8 +49,8 @@ static const char* const kmdi_not_close_xpm[] =
"#####"
};
-KMdiDockContainer::KMdiDockContainer( TQWidget *parent, TQWidget *win, int position, int flags )
- : TQWidget( parent ), KDockContainer()
+KMdiDockContainer::KMdiDockContainer( TQWidget *tqparent, TQWidget *win, int position, int flags )
+ : TQWidget( tqparent ), KDockContainer()
{
m_tabSwitching = false;
m_block = false;
@@ -70,9 +70,9 @@ KMdiDockContainer::KMdiDockContainer( TQWidget *parent, TQWidget *win, int posit
if ( m_horizontal )
- l = new TQVBoxLayout( this ); //vertical layout for top and bottom docks
+ l = new TQVBoxLayout( this ); //vertical tqlayout for top and bottom docks
else
- l = new TQHBoxLayout( this ); //horizontal layout for left and right docks
+ l = new TQHBoxLayout( this ); //horizontal tqlayout for left and right docks
l->setAutoAdd( false );
@@ -104,9 +104,9 @@ KMdiDockContainer::KMdiDockContainer( TQWidget *parent, TQWidget *win, int posit
m_ws = new TQWidgetStack( this );
- m_ws->setSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ) );
+ m_ws->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ) );
- //layout the tabbar
+ //tqlayout the tabbar
if ( position == KDockWidget::DockLeft || position == KDockWidget::DockTop )
{
//add the tabbar then the widget stack
@@ -138,7 +138,7 @@ KMdiDockContainer::~KMdiDockContainer()
{
it = m_map.begin();
KDockWidget *w = it.key();
- if ( m_overlapButtons.contains( w ) )
+ if ( m_overlapButtons.tqcontains( w ) )
{
( static_cast<KDockWidgetHeader*>( w->getHeader()->qt_cast( "KDockWidgetHeader" ) ) )->removeButton( m_overlapButtons[w] );
m_overlapButtons.remove( w );
@@ -156,28 +156,28 @@ void KMdiDockContainer::init()
if ( !m_horizontal )
{
kdDebug( 760 ) << k_funcinfo << "Horizontal tabbar. Setting forced fixed width." << endl;
- parentDockWidget()->setForcedFixedWidth( m_tb->width() );
+ tqparentDockWidget()->setForcedFixedWidth( m_tb->width() );
activateOverlapMode( m_tb->width() );
}
else
{
kdDebug( 760 ) << k_funcinfo << "Vertical tabbar. Setting forced fixed height." << endl;
- parentDockWidget()->setForcedFixedHeight( m_tb->height() );
+ tqparentDockWidget()->setForcedFixedHeight( m_tb->height() );
activateOverlapMode( m_tb->height() );
}
// try to restore splitter size
- if ( parentDockWidget() && parentDockWidget()->parent() )
+ if ( tqparentDockWidget() && tqparentDockWidget()->tqparent() )
{
- KDockSplitter * sp = static_cast<KDockSplitter*>( parentDockWidget()->parent()->qt_cast( "KDockSplitter" ) );
+ KDockSplitter * sp = static_cast<KDockSplitter*>( tqparentDockWidget()->tqparent()->qt_cast( "KDockSplitter" ) );
if ( sp )
sp->setSeparatorPosX( m_separatorPos );
}
}
-KDockWidget* KMdiDockContainer::parentDockWidget()
+KDockWidget* KMdiDockContainer::tqparentDockWidget()
{
- return ( ( KDockWidget* ) parent() );
+ return ( ( KDockWidget* ) tqparent() );
}
void KMdiDockContainer::insertWidget ( KDockWidget *dwdg, TQPixmap pixmap, const TQString &text, int & )
@@ -185,7 +185,7 @@ void KMdiDockContainer::insertWidget ( KDockWidget *dwdg, TQPixmap pixmap, const
kdDebug( 760 ) << k_funcinfo << "Adding a dockwidget to the dock container" << endl;
KDockWidget* w = dwdg;
int tab;
- bool alreadyThere = m_map.contains( w );
+ bool alreadyThere = m_map.tqcontains( w );
if ( alreadyThere )
{
@@ -201,8 +201,8 @@ void KMdiDockContainer::insertWidget ( KDockWidget *dwdg, TQPixmap pixmap, const
m_map.insert( w, tab );
m_revMap.insert( tab, w );
- if ( ( ( KDockWidget* ) parentWidget() ) ->mayBeShow() )
- ( ( KDockWidget* ) parentWidget() ) ->dockBack();
+ if ( ( ( KDockWidget* ) tqparentWidget() ) ->mayBeShow() )
+ ( ( KDockWidget* ) tqparentWidget() ) ->dockBack();
if ( w->getHeader()->qt_cast( "KDockWidgetHeader" ) )
{
@@ -277,7 +277,7 @@ bool KMdiDockContainer::eventFilter( TQObject *obj, TQEvent *event )
}
m_dockManager = w->dockManager();
- m_dragPanel = hdr->dragPanel();
+ m_dragPanel = TQT_TQOBJECT(hdr->dragPanel());
if ( m_dragPanel )
m_movingState = WaitingForMoveStart;
@@ -300,7 +300,7 @@ bool KMdiDockContainer::eventFilter( TQObject *obj, TQEvent *event )
TQPoint p( ( ( TQMouseEvent* ) event )->pos() - m_startEvent->pos() );
if ( p.manhattanLength() > KGlobalSettings::dndEventDelay() )
{
- m_dockManager->eventFilter( m_dragPanel, m_startEvent );
+ m_dockManager->eventFilter( m_dragPanel, TQT_TQEVENT(m_startEvent) );
m_dockManager->eventFilter( m_dragPanel, event );
m_movingState = Moving;
}
@@ -319,7 +319,7 @@ bool KMdiDockContainer::eventFilter( TQObject *obj, TQEvent *event )
void KMdiDockContainer::showWidget( KDockWidget *w )
{
- if ( !m_map.contains( w ) )
+ if ( !m_map.tqcontains( w ) )
return ;
int id = m_map[ w ];
@@ -359,14 +359,14 @@ void KMdiDockContainer::hideIfNeeded()
if ( itemNames.count() == 0 )
{
kdDebug( 760 ) << k_funcinfo << "Hiding the dock container" << endl;
- ( ( KDockWidget* ) parentWidget() )->undock();
+ ( ( KDockWidget* ) tqparentWidget() )->undock();
}
}
void KMdiDockContainer::removeWidget( KDockWidget* dwdg )
{
KDockWidget * w = dwdg;
- if ( !m_map.contains( w ) )
+ if ( !m_map.tqcontains( w ) )
return; //we don't have this widget in our container
kdDebug( 760 ) << k_funcinfo << endl;
@@ -382,7 +382,7 @@ void KMdiDockContainer::removeWidget( KDockWidget* dwdg )
m_ws->removeWidget( w );
m_map.remove( w );
m_revMap.remove( id );
- if ( m_overlapButtons.contains( w ) )
+ if ( m_overlapButtons.tqcontains( w ) )
{
( static_cast<KDockWidgetHeader*>( w->getHeader() ->qt_cast( "KDockWidgetHeader" ) ) )->removeButton( m_overlapButtons[ w ] );
m_overlapButtons.remove( w );
@@ -398,7 +398,7 @@ void KMdiDockContainer::undockWidget( KDockWidget *dwdg )
{
KDockWidget * w = dwdg;
- if ( !m_map.contains( w ) )
+ if ( !m_map.tqcontains( w ) )
return ;
int id = m_map[ w ];
@@ -421,14 +421,14 @@ void KMdiDockContainer::tabClicked( int t )
{
kdDebug( 760 ) << k_funcinfo << "Showing widgetstack for tab just clicked" << endl;
m_ws->show();
- parentDockWidget()->restoreFromForcedFixedSize();
+ tqparentDockWidget()->restoreFromForcedFixedSize();
}
if ( !m_ws->widget( t ) )
{
kdDebug( 760 ) << k_funcinfo << "Widget tab was clicked for is not in our stack" << endl;
kdDebug( 760 ) << k_funcinfo << "Docking it back in" << endl;
- m_revMap[t]->manualDock( parentDockWidget(), KDockWidget::DockCenter, 20 );
+ m_revMap[t]->manualDock( tqparentDockWidget(), KDockWidget::DockCenter, 20 );
if ( call_makeVisible )
m_revMap[t]->makeDockVisible();
m_tabSwitching = false;
@@ -462,9 +462,9 @@ void KMdiDockContainer::tabClicked( int t )
{
kdDebug( 760 ) << k_funcinfo << "Tab " << t << " was just deactiviated" << endl;
// try save splitter position
- if ( parentDockWidget() && parentDockWidget()->parent() )
+ if ( tqparentDockWidget() && tqparentDockWidget()->tqparent() )
{
- KDockSplitter * sp = static_cast<KDockSplitter*>( parentDockWidget()->parent()->qt_cast( "KDockSplitter" ) );
+ KDockSplitter * sp = static_cast<KDockSplitter*>( tqparentDockWidget()->tqparent()->qt_cast( "KDockSplitter" ) );
if ( sp )
m_separatorPos = sp->separatorPos();
}
@@ -484,9 +484,9 @@ void KMdiDockContainer::tabClicked( int t )
kdDebug( 760 ) << k_funcinfo << "Fixed Width:" << m_tb->width() << endl;
if ( !m_horizontal )
- parentDockWidget()->setForcedFixedWidth( m_tb->width() ); // strange why it worked before at all
+ tqparentDockWidget()->setForcedFixedWidth( m_tb->width() ); // strange why it worked before at all
else
- parentDockWidget()->setForcedFixedHeight( m_tb->height() ); // strange why it worked before at all
+ tqparentDockWidget()->setForcedFixedHeight( m_tb->height() ); // strange why it worked before at all
}
m_tabSwitching = false;
}
@@ -514,7 +514,7 @@ void KMdiDockContainer::save( TQDomElement& dockEl )
TQDomDocument doc = dockEl.ownerDocument();
TQDomElement el;
el = doc.createElement( "name" );
- el.appendChild( doc.createTextNode( TQString( "%1" ).arg( parent() ->name() ) ) );
+ el.appendChild( doc.createTextNode( TQString( "%1" ).tqarg( tqparent() ->name() ) ) );
dockEl.appendChild( el );
el = doc.createElement( "overlapMode" );
el.appendChild( doc.createTextNode( isOverlapMode() ? "true" : "false" ) );
@@ -526,7 +526,7 @@ void KMdiDockContainer::save( TQDomElement& dockEl )
for ( ;it.current() != 0;++it, ++it2 )
{
el = doc.createElement( "child" );
- el.setAttribute( "pos", TQString( "%1" ).arg( i ) );
+ el.setAttribute( "pos", TQString( "%1" ).tqarg( i ) );
TQString s = tabCaptions[ *it2 ];
if ( !s.isEmpty() )
{
@@ -569,7 +569,7 @@ void KMdiDockContainer::load( TQDomElement& dockEl )
}
else if ( el.tagName() == "child" )
{
- KDockWidget * dw = ( ( KDockWidget* ) parent() ) ->dockManager() ->getDockWidgetFromName( el.text() );
+ KDockWidget * dw = ( ( KDockWidget* ) tqparent() ) ->dockManager() ->getDockWidgetFromName( el.text() );
if ( dw )
{
if ( el.hasAttribute( "tabCaption" ) )
@@ -580,7 +580,7 @@ void KMdiDockContainer::load( TQDomElement& dockEl )
{
dw->setToolTipString( el.attribute( "tabTooltip" ) );
}
- dw->manualDock( ( KDockWidget* ) parent(), KDockWidget::DockCenter );
+ dw->manualDock( ( KDockWidget* ) tqparent(), KDockWidget::DockCenter );
}
}
}
@@ -589,9 +589,9 @@ void KMdiDockContainer::load( TQDomElement& dockEl )
TQPtrListIterator<KMultiTabBarTab> it1( *tl );
m_ws->hide();
if ( !m_horizontal )
- parentDockWidget()->setForcedFixedWidth( m_tb->width() );
+ tqparentDockWidget()->setForcedFixedWidth( m_tb->width() );
else
- parentDockWidget()->setForcedFixedHeight( m_tb->height() );
+ tqparentDockWidget()->setForcedFixedHeight( m_tb->height() );
for ( ;it1.current() != 0;++it1 )
m_tb->setTab( it1.current() ->id(), false );
@@ -624,8 +624,8 @@ void KMdiDockContainer::load( TQDomElement& dockEl )
void KMdiDockContainer::save( KConfig* cfg, const TQString& group_or_prefix )
{
TQString grp = cfg->group();
- cfg->deleteGroup( group_or_prefix + TQString( "::%1" ).arg( parent() ->name() ) );
- cfg->setGroup( group_or_prefix + TQString( "::%1" ).arg( parent() ->name() ) );
+ cfg->deleteGroup( group_or_prefix + TQString( "::%1" ).tqarg( tqparent() ->name() ) );
+ cfg->setGroup( group_or_prefix + TQString( "::%1" ).tqarg( tqparent() ->name() ) );
if ( isOverlapMode() )
cfg->writeEntry( "overlapMode", "true" );
@@ -633,10 +633,10 @@ void KMdiDockContainer::save( KConfig* cfg, const TQString& group_or_prefix )
cfg->writeEntry( "overlapMode", "false" );
// try to save the splitter position
- if ( parentDockWidget() && parentDockWidget() ->parent() )
+ if ( tqparentDockWidget() && tqparentDockWidget() ->tqparent() )
{
- KDockSplitter * sp = static_cast<KDockSplitter*>( parentDockWidget() ->
- parent() ->qt_cast( "KDockSplitter" ) );
+ KDockSplitter * sp = static_cast<KDockSplitter*>( tqparentDockWidget() ->
+ tqparent() ->qt_cast( "KDockSplitter" ) );
if ( sp )
cfg->writeEntry( "separatorPos", m_separatorPos );
}
@@ -647,17 +647,17 @@ void KMdiDockContainer::save( KConfig* cfg, const TQString& group_or_prefix )
int i = 0;
for ( ;it.current() != 0;++it, ++it2 )
{
- // cfg->writeEntry(TQString("widget%1").arg(i),m_ws->widget(it.current()->id())->name());
- cfg->writeEntry( TQString( "widget%1" ).arg( i ), ( *it2 ) );
+ // cfg->writeEntry(TQString("widget%1").tqarg(i),m_ws->widget(it.current()->id())->name());
+ cfg->writeEntry( TQString( "widget%1" ).tqarg( i ), ( *it2 ) );
TQString s = tabCaptions[ *it2 ];
if ( !s.isEmpty() )
{
- cfg->writeEntry( TQString( "widget%1-tabCaption" ).arg( i ), s );
+ cfg->writeEntry( TQString( "widget%1-tabCaption" ).tqarg( i ), s );
}
s = tabTooltips[ *it2 ];
if ( !s.isEmpty() )
{
- cfg->writeEntry( TQString( "widget%1-tabTooltip" ).arg( i ), s );
+ cfg->writeEntry( TQString( "widget%1-tabTooltip" ).tqarg( i ), s );
}
// kdDebug(760)<<"****************************************Saving: "<<m_ws->widget(it.current()->id())->name()<<endl;
if ( m_tb->isTabRaised( it.current() ->id() ) )
@@ -672,7 +672,7 @@ void KMdiDockContainer::save( KConfig* cfg, const TQString& group_or_prefix )
void KMdiDockContainer::load( KConfig* cfg, const TQString& group_or_prefix )
{
TQString grp = cfg->group();
- cfg->setGroup( group_or_prefix + TQString( "::%1" ).arg( parent() ->name() ) );
+ cfg->setGroup( group_or_prefix + TQString( "::%1" ).tqarg( tqparent() ->name() ) );
if ( cfg->readEntry( "overlapMode" ) != "false" )
activateOverlapMode( m_tb->width() );
@@ -685,24 +685,24 @@ void KMdiDockContainer::load( KConfig* cfg, const TQString& group_or_prefix )
TQString raise;
while ( true )
{
- TQString dwn = cfg->readEntry( TQString( "widget%1" ).arg( i ) );
+ TQString dwn = cfg->readEntry( TQString( "widget%1" ).tqarg( i ) );
if ( dwn.isEmpty() )
break;
kdDebug( 760 ) << k_funcinfo << "configuring dockwidget :" << dwn << endl;
- KDockWidget *dw = ( ( KDockWidget* ) parent() ) ->dockManager() ->getDockWidgetFromName( dwn );
+ KDockWidget *dw = ( ( KDockWidget* ) tqparent() ) ->dockManager() ->getDockWidgetFromName( dwn );
if ( dw )
{
- TQString s = cfg->readEntry( TQString( "widget%1-tabCaption" ).arg( i ) );
+ TQString s = cfg->readEntry( TQString( "widget%1-tabCaption" ).tqarg( i ) );
if ( !s.isEmpty() )
{
dw->setTabPageLabel( s );
}
- s = cfg->readEntry( TQString( "widget%1-tabTooltip" ).arg( i ) );
+ s = cfg->readEntry( TQString( "widget%1-tabTooltip" ).tqarg( i ) );
if ( !s.isEmpty() )
{
dw->setToolTipString( s );
}
- dw->manualDock( ( KDockWidget* ) parent(), KDockWidget::DockCenter );
+ dw->manualDock( ( KDockWidget* ) tqparent(), KDockWidget::DockCenter );
}
if ( cfg->readBoolEntry( dwn, false ) )
raise = dwn;
@@ -714,9 +714,9 @@ void KMdiDockContainer::load( KConfig* cfg, const TQString& group_or_prefix )
TQPtrListIterator<KMultiTabBarTab> it1( *tl );
m_ws->hide();
if ( !m_horizontal )
- parentDockWidget() ->setForcedFixedWidth( m_tb->width() );
+ tqparentDockWidget() ->setForcedFixedWidth( m_tb->width() );
else
- parentDockWidget() ->setForcedFixedHeight( m_tb->height() );
+ tqparentDockWidget() ->setForcedFixedHeight( m_tb->height() );
for ( ;it1.current() != 0;++it1 )
{
m_tb->setTab( it1.current() ->id(), false );
@@ -815,7 +815,7 @@ void KMdiDockContainer::prevToolView()
{
kdDebug( 760 ) << k_funcinfo << endl;
TQPtrList<KMultiTabBarTab>* tabs = m_tb->tabs();
- int pos = tabs->findRef( m_tb->tab( oldtab ) );
+ int pos = tabs->tqfindRef( m_tb->tab( oldtab ) );
if ( pos == -1 )
return ;
@@ -836,7 +836,7 @@ void KMdiDockContainer::nextToolView()
{
kdDebug( 760 ) << k_funcinfo << endl;
TQPtrList<KMultiTabBarTab>* tabs = m_tb->tabs();
- int pos = tabs->findRef( m_tb->tab( oldtab ) );
+ int pos = tabs->tqfindRef( m_tb->tab( oldtab ) );
if ( pos == -1 )
return ;
@@ -853,4 +853,4 @@ void KMdiDockContainer::nextToolView()
tabClicked( tab->id() );
}
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.h b/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.h
index cb0d6e4c..3806194e 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdidockcontainer.h
@@ -37,13 +37,14 @@ class KDockButton_Private;
class KMDI_EXPORT KMdiDockContainer: public TQWidget, public KDockContainer
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMdiDockContainer( TQWidget *parent, TQWidget *win, int position, int flags );
+ KMdiDockContainer( TQWidget *tqparent, TQWidget *win, int position, int flags );
virtual ~KMdiDockContainer();
- /** Get the KDockWidget that is our parent */
- KDockWidget *parentDockWidget();
+ /** Get the KDockWidget that is our tqparent */
+ KDockWidget *tqparentDockWidget();
/**
* Add a widget to this container
@@ -90,28 +91,28 @@ public:
/**
* Save the config using a KConfig object
*
- * The combination of the group_or_prefix variable and the parent
+ * The combination of the group_or_prefix variable and the tqparent
* dockwidget's name will be the group the configuration is saved in
- * \param group_or_prefix the prefix to append to the parent dockwidget's name
+ * \param group_or_prefix the prefix to append to the tqparent dockwidget's name
*/
virtual void save( KConfig *, const TQString& group_or_prefix );
/**
* Load the config using a KConfig object
*
- * The combination of the group_or_prefix variable and the parent
+ * The combination of the group_or_prefix variable and the tqparent
* dockwidget's name will be the group the configuration is loaded from
- * \param group_or_prefix the prefix to append to the parent dockwidget's name
+ * \param group_or_prefix the prefix to append to the tqparent dockwidget's name
*/
virtual void load( KConfig *, const TQString& group_or_prefix );
/**
- * Save the config to a QDomElement
+ * Save the config to a TQDomElement
*/
virtual void save( TQDomElement& );
/**
- * Load the config from a QDomElement
+ * Load the config from a TQDomElement
*/
virtual void load( TQDomElement& );
@@ -164,4 +165,4 @@ signals:
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.cpp b/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.cpp
index b97830af..c595700e 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.cpp
@@ -11,11 +11,11 @@
#include <kpopupmenu.h>
#include "kmdidocumentviewtabwidget.h"
-KMdiDocumentViewTabWidget::KMdiDocumentViewTabWidget( TQWidget* parent, const char* name ) : KTabWidget( parent, name )
+KMdiDocumentViewTabWidget::KMdiDocumentViewTabWidget( TQWidget* tqparent, const char* name ) : KTabWidget( tqparent, name )
{
m_visibility = KMdi::ShowWhenMoreThanOneTab;
tabBar() ->hide();
-#ifndef Q_WS_WIN //todo
+#ifndef TQ_WS_WIN //todo
setHoverCloseButton( true );
#endif
@@ -56,7 +56,7 @@ void KMdiDocumentViewTabWidget::insertTab ( TQWidget * child, const TQString & l
KTabWidget::insertTab( child, label, index );
showPage( child );
maybeShow();
- tabBar() ->repaint();
+ tabBar() ->tqrepaint();
}
void KMdiDocumentViewTabWidget::insertTab ( TQWidget * child, const TQIconSet & iconset, const TQString & label, int index )
@@ -64,7 +64,7 @@ void KMdiDocumentViewTabWidget::insertTab ( TQWidget * child, const TQIconSet &
KTabWidget::insertTab( child, iconset, label, index );
showPage( child );
maybeShow();
- tabBar() ->repaint();
+ tabBar() ->tqrepaint();
}
void KMdiDocumentViewTabWidget::insertTab ( TQWidget * child, TQTab * tab, int index )
@@ -72,7 +72,7 @@ void KMdiDocumentViewTabWidget::insertTab ( TQWidget * child, TQTab * tab, int i
KTabWidget::insertTab( child, tab, index );
showPage( child );
maybeShow();
- tabBar() ->repaint();
+ tabBar() ->tqrepaint();
}
void KMdiDocumentViewTabWidget::removePage ( TQWidget * w )
@@ -144,9 +144,9 @@ KMdi::TabWidgetVisibility KMdiDocumentViewTabWidget::tabWidgetVisibility( )
}
-#ifndef NO_INCLUDE_MOCFILES
+#ifndef NO_INCLUDE_TQMOCFILES
#include "kmdidocumentviewtabwidget.moc"
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.h b/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.h
index f24b7800..f3d3346b 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdidocumentviewtabwidget.h
@@ -23,55 +23,56 @@ class KMDI_EXPORT KMdiDocumentViewTabWidget:
public KTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMdiDocumentViewTabWidget( TQWidget* parent, const char* name = 0 );
+ KMdiDocumentViewTabWidget( TQWidget* tqparent, const char* name = 0 );
~KMdiDocumentViewTabWidget();
/**
* Add a tab into the tabwidget
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void addTab ( TQWidget * child, const TQString & label );
/**
* Add a tab into the tabwidget
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void addTab ( TQWidget * child, const TQIconSet & iconset, const TQString & label );
/**
* Add a tab into the tabwidget
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void addTab ( TQWidget * child, TQTab * tab );
/**
* Insert a tab into the tabwidget with a label
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void insertTab ( TQWidget * child, const TQString & label, int index = -1 );
/**
* Inserts a tab into the tabwidget with an icon and label
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void insertTab ( TQWidget * child, const TQIconSet & iconset, const TQString & label, int index = -1 );
/**
* Inserts a tab into the tabwidget
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void insertTab ( TQWidget * child, TQTab * tab, int index = -1 );
/**
* Removes the tab from the tabwidget
- * \sa QTabWidget
+ * \sa TQTabWidget
* \sa KTabWidget
*/
virtual void removePage ( TQWidget * w );
@@ -119,5 +120,5 @@ signals:
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdifocuslist.cpp b/lib/compatibility/kmdi/qextmdi/kmdifocuslist.cpp
index 2e9b7700..ff9ff0b4 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdifocuslist.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdifocuslist.cpp
@@ -21,7 +21,7 @@
#include <tqobjectlist.h>
#include <kdebug.h>
-KMdiFocusList::KMdiFocusList( TQObject *parent ) : TQObject( parent )
+KMdiFocusList::KMdiFocusList( TQObject *tqparent ) : TQObject( tqparent )
{}
KMdiFocusList::~KMdiFocusList()
@@ -31,7 +31,7 @@ void KMdiFocusList::addWidgetTree( TQWidget* w )
{
//this method should never be called twice on the same hierarchy
m_list.insert( w, w->focusPolicy() );
- w->setFocusPolicy( TQWidget::ClickFocus );
+ w->setFocusPolicy( TQ_ClickFocus );
kdDebug( 760 ) << "KMdiFocusList::addWidgetTree: adding toplevel" << endl;
connect( w, TQT_SIGNAL( destroyed( TQObject * ) ), this, TQT_SLOT( objectHasBeenDestroyed( TQObject* ) ) );
TQObjectList *l = w->queryList( TQWIDGET_OBJECT_NAME_STRING );
@@ -41,7 +41,7 @@ void KMdiFocusList::addWidgetTree( TQWidget* w )
{
TQWidget * wid = ( TQWidget* ) obj;
m_list.insert( wid, wid->focusPolicy() );
- wid->setFocusPolicy( TQWidget::ClickFocus );
+ wid->setFocusPolicy( TQ_ClickFocus );
kdDebug( 760 ) << "KMdiFocusList::addWidgetTree: adding widget" << endl;
connect( wid, TQT_SIGNAL( destroyed( TQObject * ) ), this, TQT_SLOT( objectHasBeenDestroyed( TQObject* ) ) );
++it;
@@ -51,13 +51,8 @@ void KMdiFocusList::addWidgetTree( TQWidget* w )
void KMdiFocusList::restore()
{
-#if (QT_VERSION-0 >= 0x030200)
- for ( TQMap<TQWidget*, TQWidget::FocusPolicy>::const_iterator it = m_list.constBegin();it != m_list.constEnd();++it )
+ for ( TQMap<TQWidget*, TQ_FocusPolicy>::const_iterator it = m_list.constBegin();it != m_list.constEnd();++it )
{
-#else
- for ( TQMap<TQWidget*, TQWidget::FocusPolicy>::iterator it = m_list.begin();it != m_list.end();++it )
- {
-#endif
it.key() ->setFocusPolicy( it.data() );
}
m_list.clear();
@@ -72,4 +67,4 @@ void KMdiFocusList::objectHasBeenDestroyed( TQObject * o )
m_list.remove( w );
}
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdifocuslist.h b/lib/compatibility/kmdi/qextmdi/kmdifocuslist.h
index 71e2f05c..a816fc4f 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdifocuslist.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdifocuslist.h
@@ -23,20 +23,21 @@
#include <tqwidget.h>
#include <kdelibs_export.h>
-class KMDI_EXPORT KMdiFocusList: public QObject
+class KMDI_EXPORT KMdiFocusList: public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMdiFocusList( TQObject *parent );
+ KMdiFocusList( TQObject *tqparent );
~KMdiFocusList();
void addWidgetTree( TQWidget* );
void restore();
protected slots:
void objectHasBeenDestroyed( TQObject* );
private:
- TQMap<TQWidget*, TQWidget::FocusPolicy> m_list;
+ TQMap<TQWidget*, TQ_FocusPolicy> m_list;
};
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdiguiclient.cpp b/lib/compatibility/kmdi/qextmdi/kmdiguiclient.cpp
index 6279253b..8c4c10ca 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdiguiclient.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdiguiclient.cpp
@@ -58,8 +58,8 @@ using namespace KMDIPrivate;
ToggleToolViewAction::ToggleToolViewAction( const TQString& text, const KShortcut& cut, KDockWidget *dw, KMdiMainFrm *mdiMainFrm,
- TQObject* parent, const char* name )
- : KToggleAction( text, cut, parent, name ), m_dw( dw ), m_mdiMainFrm( mdiMainFrm )
+ TQObject* tqparent, const char* name )
+ : KToggleAction( text, cut, tqparent, name ), m_dw( dw ), m_mdiMainFrm( mdiMainFrm )
{
if ( m_dw )
{
@@ -82,9 +82,9 @@ void ToggleToolViewAction::anDWChanged()
setChecked( false );
else if ( ( !isChecked() ) && m_dw->mayBeHide() )
setChecked( true );
- else if ( isChecked() && ( m_dw->parentDockTabGroup() &&
- ( ( static_cast<KDockWidget*>( m_dw->parentDockTabGroup() ->
- parent() ->qt_cast( "KDockWidget" ) ) ) ->mayBeShow() ) ) )
+ else if ( isChecked() && ( m_dw->tqparentDockTabGroup() &&
+ ( ( static_cast<KDockWidget*>( m_dw->tqparentDockTabGroup() ->
+ tqparent() ->qt_cast( "KDockWidget" ) ) ) ->mayBeShow() ) ) )
setChecked( false );
}
@@ -128,8 +128,8 @@ KMDIGUIClient::KMDIGUIClient( KMdiMainFrm* mdiMainFrm, bool showMDIModeAction, c
if ( domDocument().documentElement().isNull() )
{
- TQString completeDescription = TQString::fromLatin1( guiDescription )
- .arg( actionListName );
+ TQString completeDescription = TQString::tqfromLatin1( guiDescription )
+ .tqarg( actionListName );
setXML( completeDescription, false /*merge*/ );
}
@@ -152,18 +152,18 @@ KMDIGUIClient::KMDIGUIClient( KMdiMainFrm* mdiMainFrm, bool showMDIModeAction, c
this, TQT_SLOT( mdiModeHasBeenChangedTo( KMdi::MdiMode ) ) );
m_gotoToolDockMenu = new KActionMenu( i18n( "Tool &Docks" ), actionCollection(), "kmdi_tooldock_menu" );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Top Dock" ), ALT + CTRL + SHIFT + Key_T, this, TQT_SIGNAL( toggleTop() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Top Dock" ), ALT + CTRL + SHIFT + Key_T, TQT_TQOBJECT(this), TQT_SIGNAL( toggleTop() ),
actionCollection(), "kmdi_activate_top" ) );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Left Dock" ), ALT + CTRL + SHIFT + Key_L, this, TQT_SIGNAL( toggleLeft() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Left Dock" ), ALT + CTRL + SHIFT + Key_L, TQT_TQOBJECT(this), TQT_SIGNAL( toggleLeft() ),
actionCollection(), "kmdi_activate_left" ) );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Right Dock" ), ALT + CTRL + SHIFT + Key_R, this, TQT_SIGNAL( toggleRight() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Right Dock" ), ALT + CTRL + SHIFT + Key_R, TQT_TQOBJECT(this), TQT_SIGNAL( toggleRight() ),
actionCollection(), "kmdi_activate_right" ) );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Bottom Dock" ), ALT + CTRL + SHIFT + Key_B, this, TQT_SIGNAL( toggleBottom() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Switch Bottom Dock" ), ALT + CTRL + SHIFT + Key_B, TQT_TQOBJECT(this), TQT_SIGNAL( toggleBottom() ),
actionCollection(), "kmdi_activate_bottom" ) );
m_gotoToolDockMenu->insert( new KActionSeparator( actionCollection(), "kmdi_goto_menu_separator" ) );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Previous Tool View" ), ALT + CTRL + Key_Left, m_mdiMainFrm, TQT_SLOT( prevToolViewInDock() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Previous Tool View" ), ALT + CTRL + Key_Left, TQT_TQOBJECT(m_mdiMainFrm), TQT_SLOT( prevToolViewInDock() ),
actionCollection(), "kmdi_prev_toolview" ) );
- m_gotoToolDockMenu->insert( new KAction( i18n( "Next Tool View" ), ALT + CTRL + Key_Right, m_mdiMainFrm, TQT_SLOT( nextToolViewInDock() ),
+ m_gotoToolDockMenu->insert( new KAction( i18n( "Next Tool View" ), ALT + CTRL + Key_Right, TQT_TQOBJECT(m_mdiMainFrm), TQT_SLOT( nextToolViewInDock() ),
actionCollection(), "kmdi_next_toolview" ) );
actionCollection() ->readShortcutSettings( "Shortcuts", kapp->config() );
@@ -224,7 +224,7 @@ void KMDIGUIClient::setupActions()
// m_toolBars = builder.toolBars();
- // m_toolViewActions.append(new KAction( "TESTKMDIGUICLIENT", TQString::null, 0,
+ // m_toolViewActions.append(new KAction( "TESTKMDIGUICLIENT", TQString(), 0,
// this, TQT_SLOT(blah()),actionCollection(),"nothing"));
TQPtrList<KAction> addList;
@@ -257,12 +257,12 @@ void KMDIGUIClient::addToolView( KMdiToolViewAccessor* mtva )
// if ( cfg->hasKey( aname ) )
sc = KShortcut( cfg->readEntry( aname, "" ) );
cfg->setGroup( _grp );
- KAction *a = new ToggleToolViewAction( i18n( "Show %1" ).arg( mtva->wrappedWidget() ->caption() ),
- /*TQString::null*/sc, dynamic_cast<KDockWidget*>( mtva->wrapperWidget() ),
+ KAction *a = new ToggleToolViewAction( i18n( "Show %1" ).tqarg( mtva->wrappedWidget() ->caption() ),
+ /*TQString()*/sc, dynamic_cast<KDockWidget*>( mtva->wrapperWidget() ),
m_mdiMainFrm, actionCollection(), aname.latin1() );
#if KDE_IS_VERSION(3,2,90)
- ( ( ToggleToolViewAction* ) a ) ->setCheckedState( i18n( "Hide %1" ).arg( mtva->wrappedWidget() ->caption() ) );
+ ( ( ToggleToolViewAction* ) a ) ->setCheckedState( i18n( "Hide %1" ).tqarg( mtva->wrappedWidget() ->caption() ) );
#endif
connect( a, TQT_SIGNAL( destroyed( TQObject* ) ), this, TQT_SLOT( actionDeleted( TQObject* ) ) );
@@ -317,4 +317,4 @@ void KMDIGUIClient::mdiModeHasBeenChangedTo( KMdi::MdiMode mode )
}
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdiguiclient.h b/lib/compatibility/kmdi/qextmdi/kmdiguiclient.h
index 9c963431..13491db3 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdiguiclient.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdiguiclient.h
@@ -42,6 +42,7 @@ class KMDI_EXPORT KMDIGUIClient : public TQObject,
public KXMLGUIClient
{
Q_OBJECT
+ TQ_OBJECT
public:
KMDIGUIClient( KMdiMainFrm *mdiMainFrm, bool showMDIModeAction, const char *name = 0 );
@@ -121,10 +122,11 @@ private:
class KMDI_EXPORT ToggleToolViewAction: public KToggleAction
{
Q_OBJECT
+ TQ_OBJECT
public:
ToggleToolViewAction( const TQString& text, const KShortcut& cut = KShortcut(), KDockWidget *dw = 0, KMdiMainFrm *mdiMainFrm = 0,
- TQObject* parent = 0, const char* name = 0 );
+ TQObject* tqparent = 0, const char* name = 0 );
virtual ~ToggleToolViewAction();
@@ -143,4 +145,4 @@ protected slots:
}
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdiiterator.h b/lib/compatibility/kmdi/qextmdi/kmdiiterator.h
index 6bb6f7ea..52ae39dd 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdiiterator.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdiiterator.h
@@ -5,8 +5,8 @@
//
// begin : 02/2000 by Massimo Morin
// changes : 02/2000 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Massimo Morin (mmorin@schedsys.com)
@@ -47,5 +47,5 @@ protected:
;
#endif // _KMDIITERATOR_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdilistiterator.h b/lib/compatibility/kmdi/qextmdi/kmdilistiterator.h
index 40e4aef2..5236b389 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdilistiterator.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdilistiterator.h
@@ -5,8 +5,8 @@
//
// begin : 02/2000 by Massimo Morin
// changes : 02/2000 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Massimo Morin (mmorin@schedsys.com)
@@ -57,5 +57,5 @@ private:
};
#endif // _KMDILISTITERATOR_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdimainfrm.cpp b/lib/compatibility/kmdi/qextmdi/kmdimainfrm.cpp
index cf4c094c..a9f5e7f7 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdimainfrm.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmdimainfrm.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
// patches : 02/2000 by Massimo Morin (mmorin@schedsys.com)
// */2000 by Lars Beikirch (Lars.Beikirch@gmx.net)
@@ -92,7 +92,7 @@
#include "kde2laptop_closebutton.xpm"
#include "kde2laptop_closebutton_menu.xpm"
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
#ifndef NO_KDE
#include <X11/X.h> // schroder
#include <X11/Xlib.h> // schroder
@@ -107,7 +107,7 @@
/* I hate the defines in the X11 header files. Get rid of one of them */
#undef KeyPress
#endif
-#endif // Q_WS_X11 && ! K_WS_QTONLY
+#endif // TQ_WS_X11 && ! K_WS_TQTONLY
using namespace KParts;
@@ -135,8 +135,8 @@ public:
};
//============ constructor ============//
-KMdiMainFrm::KMdiMainFrm( TQWidget* parentWidget, const char* name, KMdi::MdiMode mdiMode, WFlags flags )
- : KParts::DockMainWindow( parentWidget, name, flags )
+KMdiMainFrm::KMdiMainFrm( TQWidget* tqparentWidget, const char* name, KMdi::MdiMode mdiMode, WFlags flags )
+ : KParts::DockMainWindow( tqparentWidget, name, flags )
, m_mdiMode( KMdi::UndefinedMode )
, m_pMdi( 0L )
, m_pTaskBar( 0L )
@@ -182,8 +182,8 @@ KMdiMainFrm::KMdiMainFrm( TQWidget* parentWidget, const char* name, KMdi::MdiMod
m_pDocumentViews->setAutoDelete( false );
m_pToolViews = new TQMap<TQWidget*, KMdiToolViewAccessor*>;
- // This seems to be needed (re-check it after Qt2.0 comed out)
- setFocusPolicy( ClickFocus );
+ // This seems to be needed (re-check it after TQt2.0 comed out)
+ setFocusPolicy( TQ_ClickFocus );
// create the central widget
createMdiManager();
@@ -217,12 +217,12 @@ KMdiMainFrm::KMdiMainFrm( TQWidget* parentWidget, const char* name, KMdi::MdiMod
m_pPlacingMenu = new TQPopupMenu( this, "placing_menu" );
d->closeWindowAction = new KAction(i18n("&Close"),
-#ifdef Q_WS_WIN
+#ifdef TQ_WS_WIN
CTRL|Key_F4,
#else
0,
#endif
- this, TQT_SLOT(closeActiveView()), actionCollection(), "window_close");
+ TQT_TQOBJECT(this), TQT_SLOT(closeActiveView()), actionCollection(), "window_close");
// the MDI view taskbar
createTaskBar();
@@ -298,16 +298,16 @@ void KMdiMainFrm::setStandardMDIMenuEnabled( bool showModeMenu )
//============ ~KMdiMainFrm ============//
KMdiMainFrm::~KMdiMainFrm()
{
- //save the children first to a list, as removing invalidates our iterator
- TQValueList<KMdiChildView*> children;
+ //save the tqchildren first to a list, as removing tqinvalidates our iterator
+ TQValueList<KMdiChildView*> tqchildren;
for ( KMdiChildView * w = m_pDocumentViews->first();w;w = m_pDocumentViews->next() )
- children.append( w );
+ tqchildren.append( w );
// safely close the windows so properties are saved...
TQValueListIterator<KMdiChildView*> childIt;
- for ( childIt = children.begin(); childIt != children.end(); ++childIt )
+ for ( childIt = tqchildren.begin(); childIt != tqchildren.end(); ++childIt )
{
- closeWindow( *childIt, false ); // without re-layout taskbar!
+ closeWindow( *childIt, false ); // without re-tqlayout taskbar!
}
emit lastChildViewClosed();
@@ -345,7 +345,7 @@ void KMdiMainFrm::applyOptions()
TQWidget* childFrame = 0L;
if ( ( *it )->mdiParent() )
{
- kdDebug(760) << k_funcinfo << "using child view's mdi parent for resize hack" << endl;
+ kdDebug(760) << k_funcinfo << "using child view's mdi tqparent for resize hack" << endl;
childFrame = ( *it )->mdiParent();
}
else
@@ -395,7 +395,7 @@ void KMdiMainFrm::slot_toggleTaskBar()
void KMdiMainFrm::resizeEvent( TQResizeEvent *e )
{
- if ( ( m_mdiMode == KMdi::ToplevelMode ) && !parentWidget() )
+ if ( ( m_mdiMode == KMdi::ToplevelMode ) && !tqparentWidget() )
{
if ( e->oldSize().height() != e->size().height() )
return ;
@@ -410,7 +410,7 @@ void KMdiMainFrm::resizeEvent( TQResizeEvent *e )
void KMdiMainFrm::setMinimumSize( int minw, int minh )
{
- if ( ( m_mdiMode == KMdi::ToplevelMode ) && !parentWidget() )
+ if ( ( m_mdiMode == KMdi::ToplevelMode ) && !tqparentWidget() )
return ;
DockMainWindow::setMinimumSize( minw, minh );
}
@@ -421,9 +421,9 @@ KMdiChildView* KMdiMainFrm::createWrapper( TQWidget *view, const TQString& name,
{
Q_ASSERT( view ); // if this assert fails, then some part didn't return a widget. Fix the part ;)
- KMdiChildView* pMDICover = new KMdiChildView( name /*caption*/, 0L /*parent*/,
+ KMdiChildView* pMDICover = new KMdiChildView( name /*caption*/, 0L /*tqparent*/,
name.latin1() );
- TQBoxLayout* pLayout = new TQHBoxLayout( pMDICover, 0, -1, "layout" );
+ TQBoxLayout* pLayout = new TQHBoxLayout( pMDICover, 0, -1, "tqlayout" );
view->reparent( pMDICover, TQPoint( 0, 0 ) );
pLayout->addWidget( view );
// pMDICover->setName(name);
@@ -557,7 +557,7 @@ KMdiToolViewAccessor *KMdiMainFrm::createToolWindow()
void KMdiMainFrm::deleteToolWindow( TQWidget* pWnd )
{
- if ( m_pToolViews->contains( pWnd ) )
+ if ( m_pToolViews->tqcontains( pWnd ) )
deleteToolWindow( ( *m_pToolViews ) [ pWnd ] );
}
@@ -586,7 +586,7 @@ KMdiToolViewAccessor *KMdiMainFrm::addToolWindow( TQWidget* pWnd, KDockWidget::D
pWnd = pDW;
}
- TQRect r = pWnd->geometry();
+ TQRect r = pWnd->tqgeometry();
KMdiToolViewAccessor *mtva = new KMdiToolViewAccessor( this, pWnd, tabToolTip, ( tabCaption == 0 ) ? pWnd->caption() : tabCaption );
m_pToolViews->insert( tvta, mtva );
@@ -594,7 +594,7 @@ KMdiToolViewAccessor *KMdiMainFrm::addToolWindow( TQWidget* pWnd, KDockWidget::D
if ( pos == KDockWidget::DockNone )
{
mtva->d->widgetContainer->setEnableDocking( KDockWidget::DockNone );
- mtva->d->widgetContainer->reparent( this, Qt::WType_TopLevel | Qt::WType_Dialog, r.topLeft(), true ); //pToolView->isVisible());
+ mtva->d->widgetContainer->reparent( this, TQt::WType_TopLevel | TQt::WType_Dialog, r.topLeft(), true ); //pToolView->isVisible());
}
else //add and dock the toolview as a dockwidget view
mtva->place( pos, pTargetWnd, percent );
@@ -614,7 +614,7 @@ void KMdiMainFrm::attachWindow( KMdiChildView *pWnd, bool bShow, bool bAutomatic
TQRect frameGeo = pWnd->frameGeometry();
TQPoint topLeftScreen = pWnd->mapToGlobal( TQPoint( 0, 0 ) );
TQPoint topLeftMdiChildArea = m_pMdi->mapFromGlobal( topLeftScreen );
- TQRect childAreaGeo = m_pMdi->geometry();
+ TQRect childAreaGeo = m_pMdi->tqgeometry();
if ( topLeftMdiChildArea.x() < 0 || topLeftMdiChildArea.y() < 0 ||
( topLeftMdiChildArea.x() + frameGeo.width() > childAreaGeo.width() ) ||
( topLeftMdiChildArea.y() + frameGeo.height() > childAreaGeo.height() ) )
@@ -631,7 +631,7 @@ void KMdiMainFrm::attachWindow( KMdiChildView *pWnd, bool bShow, bool bAutomatic
lpC->setClient( pWnd, bAutomaticResize );
lpC->setFocus();
pWnd->youAreAttached( lpC );
- if ( ( m_mdiMode == KMdi::ToplevelMode ) && !parentWidget() )
+ if ( ( m_mdiMode == KMdi::ToplevelMode ) && !tqparentWidget() )
{
setMinimumHeight( m_oldMainFrmMinHeight );
setMaximumHeight( m_oldMainFrmMaxHeight );
@@ -643,7 +643,7 @@ void KMdiMainFrm::attachWindow( KMdiChildView *pWnd, bool bShow, bool bAutomatic
m_pMdi->manageChild( lpC, false, bCascade );
if ( m_pMdi->topChild() && m_pMdi->topChild() ->isMaximized() )
{
- TQRect r = lpC->geometry();
+ TQRect r = lpC->tqgeometry();
lpC->setGeometry( -lpC->m_pClient->x(), -lpC->m_pClient->y(),
m_pMdi->width() + KMDI_CHILDFRM_DOUBLE_BORDER,
m_pMdi->height() + lpC->captionHeight() + KMDI_CHILDFRM_SEPARATOR + KMDI_CHILDFRM_DOUBLE_BORDER );
@@ -670,7 +670,7 @@ void KMdiMainFrm::detachWindow( KMdiChildView *pWnd, bool bShow )
pWnd->removeEventFilter( this );
pWnd->youAreDetached();
// this is only if it was attached and you want to detach it
- if ( pWnd->parent() )
+ if ( pWnd->tqparent() )
{
KMdiChildFrm * lpC = pWnd->mdiParent();
if ( lpC )
@@ -702,20 +702,20 @@ void KMdiMainFrm::detachWindow( KMdiChildView *pWnd, bool bShow )
pWnd->setGeometry( TQRect( m_pMdi->getCascadePoint( m_pDocumentViews->count() - 1 ), defaultChildFrmSize() ) );
}
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( mdiMode() == KMdi::ToplevelMode )
{
- XSetTransientForHint( qt_xdisplay(), pWnd->winId(), topLevelWidget() ->winId() );
+ XSetTransientForHint( qt_xdisplay(), pWnd->winId(), tqtopLevelWidget() ->winId() );
}
#endif
return ;
}
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
if ( mdiMode() == KMdi::ToplevelMode )
{
- XSetTransientForHint( qt_xdisplay(), pWnd->winId(), topLevelWidget() ->winId() );
+ XSetTransientForHint( qt_xdisplay(), pWnd->winId(), tqtopLevelWidget() ->winId() );
}
#endif
@@ -776,12 +776,12 @@ void KMdiMainFrm::removeWindowFromMdi( KMdiChildView *pWnd )
m_pDockbaseOfTabPage = m_pDockbaseAreaOfDocumentViews;
m_pClose->hide();
}
- KDockWidget* pDockW = ( KDockWidget* ) pWnd->parentWidget();
+ KDockWidget* pDockW = ( KDockWidget* ) pWnd->tqparentWidget();
pWnd->reparent( 0L, TQPoint( 0, 0 ) );
pDockW->setWidget( 0L );
if ( pDockW == m_pDockbaseOfTabPage )
{
- TQTabWidget * pTab = ( TQTabWidget* ) pDockW->parentWidget() ->parentWidget();
+ TQTabWidget * pTab = ( TQTabWidget* ) pDockW->tqparentWidget() ->tqparentWidget();
int cnt = pTab->count();
m_pDockbaseOfTabPage = ( KDockWidget* ) pTab->page( cnt - 2 );
if ( pDockW == m_pDockbaseOfTabPage )
@@ -829,7 +829,7 @@ void KMdiMainFrm::removeWindowFromMdi( KMdiChildView *pWnd )
}
//============== closeWindow ==============//
-void KMdiMainFrm::closeWindow( KMdiChildView *pWnd, bool layoutTaskBar )
+void KMdiMainFrm::closeWindow( KMdiChildView *pWnd, bool tqlayoutTaskBar )
{
if ( !pWnd )
return ;
@@ -840,7 +840,7 @@ void KMdiMainFrm::closeWindow( KMdiChildView *pWnd, bool layoutTaskBar )
if ( m_pTaskBar )
{
- m_pTaskBar->removeWinButton( pWnd, layoutTaskBar );
+ m_pTaskBar->removeWinButton( pWnd, tqlayoutTaskBar );
}
if ( ( m_mdiMode == KMdi::TabPageMode ) || ( m_mdiMode == KMdi::IDEAlMode ) )
@@ -878,12 +878,12 @@ void KMdiMainFrm::closeWindow( KMdiChildView *pWnd, bool layoutTaskBar )
m_pClose->hide();
}
#if 0
- KDockWidget* pDockW = ( KDockWidget* ) pWnd->parentWidget();
+ KDockWidget* pDockW = ( KDockWidget* ) pWnd->tqparentWidget();
pWnd->reparent( 0L, TQPoint( 0, 0 ) );
pDockW->setWidget( 0L );
if ( pDockW == m_pDockbaseOfTabPage )
{
- TQTabWidget * pTab = ( TQTabWidget* ) pDockW->parentWidget() ->parentWidget();
+ TQTabWidget * pTab = ( TQTabWidget* ) pDockW->tqparentWidget() ->tqparentWidget();
int cnt = pTab->count();
m_pDockbaseOfTabPage = ( KDockWidget* ) pTab->page( cnt - 2 );
if ( pDockW == m_pDockbaseOfTabPage )
@@ -963,13 +963,13 @@ bool KMdiMainFrm::windowExists( KMdiChildView *pWnd, ExistsAs as )
{
if ( ( as == ToolView ) || ( as == AnyView ) )
{
- if ( m_pToolViews->contains( pWnd ) )
+ if ( m_pToolViews->tqcontains( pWnd ) )
return true;
if ( as == ToolView )
return false;
}
- if ( m_pDocumentViews->findRef( pWnd ) != -1 )
+ if ( m_pDocumentViews->tqfindRef( pWnd ) != -1 )
return true;
return false;
@@ -1212,12 +1212,12 @@ bool KMdiMainFrm::eventFilter( TQObject * /*obj*/, TQEvent *e )
/** these are quite some assumptions:
* The key combination uses exactly one modifier key
- * The WIN button in KDE is the meta button in Qt
+ * The WIN button in KDE is the meta button in TQt
**/
if ( state != ( ( TQKeyEvent * ) e ) ->stateAfter() &&
- ( ( modFlags & KKey::CTRL ) > 0 ) == ( ( state & Qt::ControlButton ) > 0 ) &&
- ( ( modFlags & KKey::ALT ) > 0 ) == ( ( state & Qt::AltButton ) > 0 ) &&
- ( ( modFlags & KKey::WIN ) > 0 ) == ( ( state & Qt::MetaButton ) > 0 ) )
+ ( ( modFlags & KKey::CTRL ) > 0 ) == ( ( state & TQt::ControlButton ) > 0 ) &&
+ ( ( modFlags & KKey::ALT ) > 0 ) == ( ( state & TQt::AltButton ) > 0 ) &&
+ ( ( modFlags & KKey::WIN ) > 0 ) == ( ( state & TQt::MetaButton ) > 0 ) )
{
activeWindow() ->updateTimeStamp();
setSwitching( false );
@@ -1238,14 +1238,14 @@ bool KMdiMainFrm::eventFilter( TQObject * /*obj*/, TQEvent *e )
*/
void KMdiMainFrm::closeAllViews()
{
- //save the children first to a list, as removing invalidates our iterator
- TQValueList<KMdiChildView*> children;
+ //save the tqchildren first to a list, as removing tqinvalidates our iterator
+ TQValueList<KMdiChildView*> tqchildren;
for ( KMdiChildView * w = m_pDocumentViews->first();w;w = m_pDocumentViews->next() )
{
- children.append( w );
+ tqchildren.append( w );
}
TQValueListIterator<KMdiChildView *> childIt;
- for ( childIt = children.begin(); childIt != children.end(); ++childIt )
+ for ( childIt = tqchildren.begin(); childIt != tqchildren.end(); ++childIt )
{
( *childIt )->close();
}
@@ -1273,7 +1273,7 @@ void KMdiMainFrm::closeActiveView()
m_pCurrentWindow->close();
}
-/** find the root dockwidgets and store their geometry */
+/** find the root dockwidgets and store their tqgeometry */
void KMdiMainFrm::findRootDockWidgets( TQPtrList<KDockWidget>* rootDockWidgetList, TQValueList<TQRect>* positionList )
{
//nothing is valid
@@ -1289,24 +1289,24 @@ void KMdiMainFrm::findRootDockWidgets( TQPtrList<KDockWidget>* rootDockWidgetLis
pObjList = queryList( "KDockWidget_Compat::KDockWidget" );
TQObjectListIt it( *pObjList );
- // for all dockwidgets (which are children of this mainwindow)
+ // for all dockwidgets (which are tqchildren of this mainwindow)
while ( ( *it ) )
{
KDockWidget* dockWindow = 0L; /* pDockW */
KDockWidget* rootDockWindow = 0L; /* pRootDockWindow */
KDockWidget* undockCandidate = 0L; /* pUndockCandidate */
- TQWidget* pW = static_cast<TQWidget*>( ( *it ) );
+ TQWidget* pW = TQT_TQWIDGET( ( *it ) );
// find the oldest ancestor of the current dockwidget that can be undocked
while ( !pW->isTopLevel() )
{
- if ( ::qt_cast<KDockWidget*>( pW ) || pW->inherits( "KDockWidget_Compat::KDockWidget" ) )
+ if ( ::tqqt_cast<KDockWidget*>( pW ) || pW->inherits( "KDockWidget_Compat::KDockWidget" ) )
{
undockCandidate = static_cast<KDockWidget*>( pW );
if ( undockCandidate->enableDocking() != KDockWidget::DockNone )
rootDockWindow = undockCandidate;
}
- pW = pW->parentWidget();
+ pW = pW->tqparentWidget();
}
if ( rootDockWindow )
@@ -1357,7 +1357,7 @@ void KMdiMainFrm::switchToToplevelMode()
const int frameBorderWidth = 7; // @todo: Can we / do we need to ask the window manager?
setUndockPositioningOffset( TQPoint( 0, ( m_pTaskBar ? m_pTaskBar->height() : 0 ) + frameBorderWidth ) );
- // 1.) select the dockwidgets to be undocked and store their geometry
+ // 1.) select the dockwidgets to be undocked and store their tqgeometry
TQPtrList<KDockWidget> rootDockWidgetList;
TQValueList<TQRect> positionList;
@@ -1399,11 +1399,11 @@ void KMdiMainFrm::switchToToplevelMode()
setMainDockWidget( m_pDockbaseAreaOfDocumentViews );
}
// TQApplication::sendPostedEvents(); //why do we need to empty the event queue?
- if ( !parentWidget() )
+ if ( !tqparentWidget() )
{
- //if we don't have a parent widget ( which i expect we wouldn't )
+ //if we don't have a tqparent widget ( which i expect we wouldn't )
//make sure we take into account the size of the docks provided by
- //QMainWindow
+ //TQMainWindow
int topDockHeight = topDock() ? topDock()->height() : 0;
int bottomDockHeight = bottomDock() ? bottomDock()->height() : 0;
int menuBarHeight = hasMenuBar() ? menuBar()->height() : 0;
@@ -1425,7 +1425,7 @@ void KMdiMainFrm::switchToToplevelMode()
TQPtrListIterator<KMdiChildView> kmdicvit( *m_pDocumentViews );
for ( kmdicvit.toFirst(); ( *kmdicvit ); ++kmdicvit )
{
-#ifdef Q_WS_X11
+#ifdef TQ_WS_X11
XSetTransientForHint( qt_xdisplay(), ( *kmdicvit )->winId(), winId() );
#endif
( *kmdicvit )->show();
@@ -1470,7 +1470,7 @@ void KMdiMainFrm::switchToChildframeMode()
if ( m_mdiMode == KMdi::TabPageMode )
{
kdDebug(760) << k_funcinfo << "finishing tab page mode" << endl;
- // select the dockwidgets to be undocked and store their geometry
+ // select the dockwidgets to be undocked and store their tqgeometry
findRootDockWidgets( &rootDockWidgetList, &positionList );
kdDebug(760) << k_funcinfo << "Found " << rootDockWidgetList.count() << " widgets to undock" << endl;
@@ -1490,7 +1490,7 @@ void KMdiMainFrm::switchToChildframeMode()
kdDebug(760) << k_funcinfo << "finishing ideal mode" << endl;
finishIDEAlMode( false );
- // select the dockwidgets to be undocked and store their geometry
+ // select the dockwidgets to be undocked and store their tqgeometry
findRootDockWidgets( &rootDockWidgetList, &positionList );
kdDebug(760) << k_funcinfo << "Found " << rootDockWidgetList.count() << " widgets to undock" << endl;
@@ -1560,7 +1560,7 @@ void KMdiMainFrm::switchToChildframeMode()
if ( !pView->isToolView() )
pView->show();
}
- if ( ( oldMdiMode == KMdi::ToplevelMode ) && !parentWidget() )
+ if ( ( oldMdiMode == KMdi::ToplevelMode ) && !tqparentWidget() )
{
setMinimumHeight( m_oldMainFrmMinHeight );
setMaximumHeight( m_oldMainFrmMaxHeight );
@@ -1663,10 +1663,10 @@ void KMdiMainFrm::finishTabPageMode()
if ( pView->isToolView() )
continue;
kdDebug(760) << "KMdiMainFrm::finishTabPageMode: in loop" << endl;
- TQSize mins = pView->minimumSize();
- TQSize maxs = pView->maximumSize();
+ TQSize mins = pView->tqminimumSize();
+ TQSize maxs = pView->tqmaximumSize();
TQSize sz = pView->size();
- TQWidget* pParent = pView->parentWidget();
+ TQWidget* pParent = pView->tqparentWidget();
TQPoint p( pParent->mapToGlobal( pParent->pos() ) - pParent->pos() + m_undockPositioningOffset );
m_documentTabWidget->removePage( pView );
pView->reparent( 0, 0, p );
@@ -1692,7 +1692,7 @@ void KMdiMainFrm::finishTabPageMode()
void KMdiMainFrm::setupTabbedDocumentViewSpace()
{
// resize to childframe mode size of the mainwindow if we were in toplevel mode
- if ( ( m_mdiMode == KMdi::ToplevelMode ) && !parentWidget() )
+ if ( ( m_mdiMode == KMdi::ToplevelMode ) && !tqparentWidget() )
{
setMinimumHeight( m_oldMainFrmMinHeight );
setMaximumHeight( m_oldMainFrmMaxHeight );
@@ -1787,7 +1787,7 @@ void KMdiMainFrm::setToolviewStyle( int flag )
switch ( flag )
{
case KMdi::IconOnly:
- dockWidget->setTabPageLabel( TQString::null );
+ dockWidget->setTabPageLabel( TQString() );
dockWidget->setPixmap( *( it.data()->wrappedWidget()->icon() ) );
break;
case KMdi::TextOnly:
@@ -1875,9 +1875,9 @@ void KMdiMainFrm::switchToIDEAlMode()
}
-void KMdiMainFrm::dockToolViewsIntoContainers( TQPtrList<KDockWidget>& widgetsToReparent, KDockWidget *container )
+void KMdiMainFrm::dockToolViewsIntoContainers( TQPtrList<KDockWidget>& widgetsToRetqparent, KDockWidget *container )
{
- TQPtrListIterator<KDockWidget> it( widgetsToReparent );
+ TQPtrListIterator<KDockWidget> it( widgetsToRetqparent );
for ( ; ( *it ); ++it )
{
( *it )->manualDock( container, KDockWidget::DockCenter, 20 );
@@ -1888,9 +1888,9 @@ void KMdiMainFrm::dockToolViewsIntoContainers( TQPtrList<KDockWidget>& widgetsTo
void KMdiMainFrm::findToolViewsDockedToMain( TQPtrList<KDockWidget>* list, KDockWidget::DockPosition dprtmw )
{
KDockWidget* mainDock = getMainDockWidget();
- if ( mainDock->parentDockTabGroup() )
+ if ( mainDock->tqparentDockTabGroup() )
{
- mainDock = dynamic_cast<KDockWidget*>( mainDock->parentDockTabGroup()->parent() );
+ mainDock = dynamic_cast<KDockWidget*>( mainDock->tqparentDockTabGroup()->tqparent() );
// FIXME: will likely crash below due to unchecked cast
}
@@ -1901,9 +1901,9 @@ void KMdiMainFrm::findToolViewsDockedToMain( TQPtrList<KDockWidget>* list, KDock
}
KDockWidget* widget = mainDock->findNearestDockWidget( dprtmw );
- if ( widget && widget->parentDockTabGroup() )
+ if ( widget && widget->tqparentDockTabGroup() )
{
- widget = static_cast<KDockWidget*>( widget->parentDockTabGroup() ->parent() );
+ widget = static_cast<KDockWidget*>( TQT_TQWIDGET(widget->tqparentDockTabGroup() ->tqparent()) );
if ( widget )
{
@@ -1934,21 +1934,21 @@ void KMdiMainFrm::setupToolViewsForIDEALMode()
KDockWidget *mainDock = getMainDockWidget();
KDockWidget *w = mainDock;
- if ( mainDock->parentDockTabGroup() )
- w = static_cast<KDockWidget*>( mainDock->parentDockTabGroup()->parent() );
+ if ( mainDock->tqparentDockTabGroup() )
+ w = static_cast<KDockWidget*>( TQT_TQWIDGET(mainDock->tqparentDockTabGroup()->tqparent()) );
- TQPtrList<KDockWidget> leftReparentWidgets;
- TQPtrList<KDockWidget> rightReparentWidgets;
- TQPtrList<KDockWidget> bottomReparentWidgets;
- TQPtrList<KDockWidget> topReparentWidgets;
+ TQPtrList<KDockWidget> leftRetqparentWidgets;
+ TQPtrList<KDockWidget> rightRetqparentWidgets;
+ TQPtrList<KDockWidget> bottomRetqparentWidgets;
+ TQPtrList<KDockWidget> topRetqparentWidgets;
- if ( mainDock->parentDockTabGroup() )
- mainDock = static_cast<KDockWidget*>( mainDock->parentDockTabGroup() ->parent() );
+ if ( mainDock->tqparentDockTabGroup() )
+ mainDock = static_cast<KDockWidget*>( TQT_TQWIDGET(mainDock->tqparentDockTabGroup() ->tqparent()) );
- findToolViewsDockedToMain( &leftReparentWidgets, KDockWidget::DockLeft );
- findToolViewsDockedToMain( &rightReparentWidgets, KDockWidget::DockRight );
- findToolViewsDockedToMain( &bottomReparentWidgets, KDockWidget::DockBottom );
- findToolViewsDockedToMain( &topReparentWidgets, KDockWidget::DockTop );
+ findToolViewsDockedToMain( &leftRetqparentWidgets, KDockWidget::DockLeft );
+ findToolViewsDockedToMain( &rightRetqparentWidgets, KDockWidget::DockRight );
+ findToolViewsDockedToMain( &bottomRetqparentWidgets, KDockWidget::DockBottom );
+ findToolViewsDockedToMain( &topRetqparentWidgets, KDockWidget::DockTop );
mainDock->setEnableDocking( KDockWidget::DockNone ); //::DockCorner);
mainDock->setDockSite( KDockWidget::DockCorner );
@@ -2000,10 +2000,10 @@ void KMdiMainFrm::setupToolViewsForIDEALMode()
m_topContainer->setDockSite( KDockWidget::DockCenter );
m_bottomContainer->setDockSite( KDockWidget::DockCenter );
- dockToolViewsIntoContainers( leftReparentWidgets, m_leftContainer );
- dockToolViewsIntoContainers( rightReparentWidgets, m_rightContainer );
- dockToolViewsIntoContainers( bottomReparentWidgets, m_bottomContainer );
- dockToolViewsIntoContainers( topReparentWidgets, m_topContainer );
+ dockToolViewsIntoContainers( leftRetqparentWidgets, m_leftContainer );
+ dockToolViewsIntoContainers( rightRetqparentWidgets, m_rightContainer );
+ dockToolViewsIntoContainers( bottomRetqparentWidgets, m_bottomContainer );
+ dockToolViewsIntoContainers( topRetqparentWidgets, m_topContainer );
dockManager->setSpecialLeftDockContainer( m_leftContainer );
@@ -2079,10 +2079,10 @@ void KMdiMainFrm::finishIDEAlMode( bool full )
KMdiChildView* pView = it.current();
if ( pView->isToolView() )
continue;
- TQSize mins = pView->minimumSize();
- TQSize maxs = pView->maximumSize();
+ TQSize mins = pView->tqminimumSize();
+ TQSize maxs = pView->tqmaximumSize();
TQSize sz = pView->size();
- TQWidget* pParent = pView->parentWidget();
+ TQWidget* pParent = pView->tqparentWidget();
TQPoint p( pParent->mapToGlobal( pParent->pos() ) - pParent->pos() + m_undockPositioningOffset );
pView->reparent( 0, 0, p );
pView->reparent( 0, 0, p );
@@ -2105,7 +2105,7 @@ void KMdiMainFrm::finishIDEAlMode( bool full )
}
else
{
- pParent = pParent->parentWidget();
+ pParent = pParent->tqparentWidget();
}
}
while ( pParent && !pDockW );
@@ -2139,9 +2139,9 @@ void KMdiMainFrm::idealToolViewsToStandardTabs( TQStringList widgetNames, KDockW
Q_UNUSED( size )
KDockWidget * mainDock = getMainDockWidget();
- if ( mainDock->parentDockTabGroup() )
+ if ( mainDock->tqparentDockTabGroup() )
{
- mainDock = static_cast<KDockWidget*>( mainDock->parentDockTabGroup() ->parent() );
+ mainDock = static_cast<KDockWidget*>( TQT_TQWIDGET(mainDock->tqparentDockTabGroup() ->tqparent()) );
}
if ( widgetNames.count() > 0 )
@@ -2167,7 +2167,7 @@ void KMdiMainFrm::idealToolViewsToStandardTabs( TQStringList widgetNames, KDockW
}
#if 0
- TQWidget *wid = dwpd->parentDockTabGroup();
+ TQWidget *wid = dwpd->tqparentDockTabGroup();
if ( !wid )
wid = dwpd;
wid->setGeometry( 0, 0, 20, 20 );
@@ -2266,10 +2266,10 @@ void KMdiMainFrm::setSysButtonsAtMenuPosition()
{
if ( m_pMainMenuBar == 0L )
return ;
- if ( m_pMainMenuBar->parentWidget() == 0L )
+ if ( m_pMainMenuBar->tqparentWidget() == 0L )
return ;
- int menuW = m_pMainMenuBar->parentWidget() ->width();
+ int menuW = m_pMainMenuBar->tqparentWidget() ->width();
int h;
int y;
if ( frameDecorOfAttachedViews() == KMdi::Win95Look )
@@ -2361,7 +2361,7 @@ void KMdiMainFrm::activateFirstWin()
return ;
TQDateTime current = activeWindow() ->getTimeStamp();
- TQMap<TQDateTime, KMdiChildView*>::iterator pos( m.find( current ) );
+ TQMap<TQDateTime, KMdiChildView*>::iterator pos( m.tqfind( current ) );
TQMap<TQDateTime, KMdiChildView*>::iterator newPos = pos;
if ( pos != m.end() )
{
@@ -2394,7 +2394,7 @@ void KMdiMainFrm::activateLastWin()
return ;
TQDateTime current = activeWindow() ->getTimeStamp();
- TQMap<TQDateTime, KMdiChildView*>::iterator pos( m.find( current ) );
+ TQMap<TQDateTime, KMdiChildView*>::iterator pos( m.tqfind( current ) );
if ( pos != m.begin() )
{
--pos;
@@ -2938,4 +2938,4 @@ KTabWidget * KMdiMainFrm::tabWidget() const
#include "kmdimainfrm.moc"
// vim: ts=2 sw=2 et
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdimainfrm.h b/lib/compatibility/kmdi/qextmdi/kmdimainfrm.h
index 68322f69..6f94451e 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdimainfrm.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdimainfrm.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// : 02/2000 by Massimo Morin (mmorin@schedsys.com)
// 2000-2003 maintained by the KDevelop project
// patches : */2000 by Lars Beikirch (Lars.Beikirch@gmx.net)
@@ -69,7 +69,7 @@ class KMdiMainFrmPrivate;
*
* This special event is needed because the view has to inform the main frame that it`s being closed.
*/
-class KMDI_EXPORT KMdiViewCloseEvent : public QCustomEvent
+class KMDI_EXPORT KMdiViewCloseEvent : public TQCustomEvent
{
public:
KMdiViewCloseEvent( KMdiChildView* pWnd ) : TQCustomEvent( TQEvent::User, pWnd ) {}
@@ -78,7 +78,7 @@ public:
/**
* \short Base class for all your special main frames.
*
- * It contains the child frame area (QMainWindow's central widget) and a child view taskbar
+ * It contains the child frame area (TQMainWindow's central widget) and a child view taskbar
* for switching the MDI views. Most methods are virtual functions for later overriding.
*
* Basically, this class provides functionality for docking/undocking view windows and
@@ -98,7 +98,7 @@ public:
*
* \code
* MyMainWindow mainframe;
- * qApp->setMainWidget(&mainframe);
+ * tqApp->setMainWidget(&mainframe);
* mainframe->addWindow(view1); // put it under MDI control
* mainframe->addWindow(view2);
* \endcode
@@ -142,7 +142,7 @@ public:
* use fakeSDIApplication() to fake it and isFakingSDIApplication() to query whether or not an SDI
* interface is being faked.
*
- * You can dynamically change the shape of the attached MDI views using setFrameDecorOfAttachedViews().
+ * You can dynamically change the tqshape of the attached MDI views using setFrameDecorOfAttachedViews().
*
* Additionally, here's a hint how to restore the mainframe's settings from config file:
* \code
@@ -241,6 +241,7 @@ class KMDI_EXPORT KMdiMainFrm : public KParts::DockMainWindow
friend class KMdiChildView;
friend class KMdiTaskBar;
Q_OBJECT
+ TQ_OBJECT
friend class KMdiToolViewAccessor;
// attributes
@@ -296,7 +297,7 @@ private:
// methods
public:
- KMdiMainFrm( TQWidget* parentWidget, const char* name = "", KMdi::MdiMode mdiMode = KMdi::ChildframeMode, WFlags flags = WType_TopLevel | WDestructiveClose );
+ KMdiMainFrm( TQWidget* tqparentWidget, const char* name = "", KMdi::MdiMode mdiMode = KMdi::ChildframeMode, WFlags flags = WType_TopLevel | WDestructiveClose );
virtual ~KMdiMainFrm();
/**
@@ -354,7 +355,7 @@ public:
bool windowExists( KMdiChildView *pWnd, ExistsAs as );
/**
- * Catches certain Qt events and processes it here.
+ * Catches certain TQt events and processes it here.
* Currently, here this catches only the KMdiViewCloseEvent (a KMdi user event) which is sent
* from itself in childWindowCloseRequest() right after a KMdiChildView::closeEvent() .
* The reason for this event to itself is simple: It just wants to break the function call stack.
@@ -447,7 +448,7 @@ public:
*/
int childFrameModeHeight() { return m_oldMainFrmHeight; };
/**
- * Tells the MDI system a QMenu where it can insert buttons for
+ * Tells the MDI system a TQMenu where it can insert buttons for
* the system menu, undock, minimize, restore actions.
* If no such menu is given, KMdi simply overlays the buttons
* at the upper right-hand side of the main widget.
@@ -525,7 +526,7 @@ public slots:
/**
* Adds a KMdiChildView to the MDI system. The main frame takes control of it.
- * \param rectNormal Sets the geometry for this child view
+ * \param rectNormal Sets the tqgeometry for this child view
* \param flags the flags for the view such as:
* \li whether the view should be attached or detached.
* \li whether the view should be shown or hidden
@@ -548,7 +549,7 @@ public slots:
/**
* Using this method you have to use the setWidget method of the access object, and it is very recommendet, that you use
- * the widgetContainer() method for the parent of your newly created widget
+ * the widgetContainer() method for the tqparent of your newly created widget
*/
KMdiToolViewAccessor *createToolWindow();
@@ -563,7 +564,7 @@ public slots:
* Removes a KMdiChildView from the MDI system and from the main frame`s control.
* Note: The view will be deleted!
*/
- virtual void closeWindow( KMdiChildView *pWnd, bool layoutTaskBar = true );
+ virtual void closeWindow( KMdiChildView *pWnd, bool tqlayoutTaskBar = true );
/**
* Switches the KMdiTaskBar on and off.
@@ -691,7 +692,7 @@ public slots:
virtual void tileAnodine() { m_pMdi->tileAnodine(); }
/**
- * Tile Vertically
+ * TileQt::Vertically
*/
virtual void tileVertically() { m_pMdi->tileVertically(); }
@@ -757,7 +758,7 @@ protected:
void blockClearingOfWindowMenu( bool bBlocked ) { m_bClearingOfWindowMenuBlocked = bBlocked; }
void findToolViewsDockedToMain( TQPtrList<KDockWidget>* list, KDockWidget::DockPosition dprtmw );
- void dockToolViewsIntoContainers( TQPtrList<KDockWidget>& widgetsToReparent, KDockWidget *container );
+ void dockToolViewsIntoContainers( TQPtrList<KDockWidget>& widgetsToRetqparent, KDockWidget *container );
TQStringList prepareIdealToTabs( KDockWidget* container );
void idealToolViewsToStandardTabs( TQStringList widgetNames, KDockWidget::DockPosition pos, int sizee );
@@ -869,4 +870,4 @@ signals:
#endif //_KMDIMAINFRM_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmdinulliterator.h b/lib/compatibility/kmdi/qextmdi/kmdinulliterator.h
index 3c976caa..3e0e1268 100644
--- a/lib/compatibility/kmdi/qextmdi/kmdinulliterator.h
+++ b/lib/compatibility/kmdi/qextmdi/kmdinulliterator.h
@@ -5,8 +5,8 @@
//
// begin : 02/2000 by Massimo Morin
// changes : 02/2000 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Massimo Morin (mmorin@schedsys.com)
@@ -45,5 +45,5 @@ public:
};
#endif // _KMDINULLITERATOR_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmditaskbar.cpp b/lib/compatibility/kmdi/qextmdi/kmditaskbar.cpp
index 71c3de45..f99f5b76 100644
--- a/lib/compatibility/kmdi/qextmdi/kmditaskbar.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmditaskbar.cpp
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
// patches : 02/2000 by Massimo Morin (mmorin@schedsys.com)
//
@@ -63,7 +63,7 @@ KMdiTaskBarButton::KMdiTaskBarButton( KMdiTaskBar *pTaskBar, KMdiChildView *win_
m_pWindow = win_ptr;
TQToolTip::add
( this, win_ptr->caption() );
- setFocusPolicy( NoFocus );
+ setFocusPolicy( TQ_NoFocus );
}
KMdiTaskBarButton::~KMdiTaskBarButton()
@@ -73,10 +73,10 @@ void KMdiTaskBarButton::mousePressEvent( TQMouseEvent* e )
{
switch ( e->button() )
{
- case TQMouseEvent::LeftButton:
+ case Qt::LeftButton:
emit leftMouseButtonClicked( m_pWindow );
break;
- case TQMouseEvent::RightButton:
+ case Qt::RightButton:
emit rightMouseButtonClicked( m_pWindow );
break;
default:
@@ -102,7 +102,7 @@ void KMdiTaskBarButton::fitText( const TQString& origStr, int newWidth )
{
TQButton::setText( m_actualText );
- int actualWidth = sizeHint().width();
+ int actualWidth = tqsizeHint().width();
int realLetterCount = origStr.length();
int newLetterCount = ( newWidth * realLetterCount ) / actualWidth;
int w = newWidth + 1;
@@ -140,20 +140,20 @@ TQString KMdiTaskBarButton::actualText() const
//
//####################################################################
-KMdiTaskBar::KMdiTaskBar( KMdiMainFrm *parent, TQMainWindow::ToolBarDock dock )
- : KToolBar( parent, "KMdiTaskBar", /*honor_style*/ false, /*readConfig*/ true )
+KMdiTaskBar::KMdiTaskBar( KMdiMainFrm *tqparent, TQMainWindow::ToolBarDock dock )
+ : KToolBar( tqparent, "KMdiTaskBar", /*honor_style*/ false, /*readConfig*/ true )
, m_pCurrentFocusedWindow( 0 )
, m_pStretchSpace( 0 )
, m_layoutIsPending( false )
, m_bSwitchedOn( false )
{
- m_pFrm = parent;
+ m_pFrm = tqparent;
m_pButtonList = new TQPtrList<KMdiTaskBarButton>;
m_pButtonList->setAutoDelete( true );
//QT30 setFontPropagation(TQWidget::SameFont);
setMinimumWidth( 1 );
- setFocusPolicy( NoFocus );
- parent->moveToolBar( this, dock ); //XXX obsolete!
+ setFocusPolicy( TQ_NoFocus );
+ tqparent->moveToolBar( this, dock ); //XXX obsolete!
}
KMdiTaskBar::~KMdiTaskBar()
@@ -175,12 +175,12 @@ KMdiTaskBarButton * KMdiTaskBar::addWinButton( KMdiChildView *win_ptr )
TQObject::connect( b, TQT_SIGNAL( clicked( KMdiChildView* ) ), this, TQT_SLOT( setActiveButton( KMdiChildView* ) ) );
TQObject::connect( b, TQT_SIGNAL( leftMouseButtonClicked( KMdiChildView* ) ), m_pFrm, TQT_SLOT( activateView( KMdiChildView* ) ) );
TQObject::connect( b, TQT_SIGNAL( rightMouseButtonClicked( KMdiChildView* ) ), m_pFrm, TQT_SLOT( taskbarButtonRightClicked( KMdiChildView* ) ) );
- TQObject::connect( b, TQT_SIGNAL( buttonTextChanged( int ) ), this, TQT_SLOT( layoutTaskBar( int ) ) );
+ TQObject::connect( b, TQT_SIGNAL( buttonTextChanged( int ) ), this, TQT_SLOT( tqlayoutTaskBar( int ) ) );
m_pButtonList->append( b );
b->setToggleButton( true );
b->setText( win_ptr->tabCaption() );
- layoutTaskBar();
+ tqlayoutTaskBar();
m_pStretchSpace = new TQLabel( this, "empty" );
m_pStretchSpace->setText( "" );
@@ -202,7 +202,7 @@ void KMdiTaskBar::removeWinButton( KMdiChildView *win_ptr, bool haveToLayoutTask
{
m_pButtonList->removeRef( b );
if ( haveToLayoutTaskBar )
- layoutTaskBar();
+ tqlayoutTaskBar();
}
if ( m_pButtonList->count() == 0 )
{
@@ -303,7 +303,7 @@ void KMdiTaskBar::setActiveButton( KMdiChildView *win_ptr )
}
}
-void KMdiTaskBar::layoutTaskBar( int taskBarWidth )
+void KMdiTaskBar::tqlayoutTaskBar( int taskBarWidth )
{
if ( m_layoutIsPending )
return ;
@@ -337,16 +337,16 @@ void KMdiTaskBar::layoutTaskBar( int taskBarWidth )
// if there's enough space, use actual width
int buttonCount = m_pButtonList->count();
int tbHandlePixel;
- tbHandlePixel = style().pixelMetric( TQStyle::PM_DockWindowHandleExtent, this );
- int buttonAreaWidth = taskBarWidth - tbHandlePixel - style().pixelMetric( TQStyle::PM_DefaultFrameWidth, this ) - 5;
- if ( ( ( allButtonsWidthHint ) <= buttonAreaWidth ) || ( width() < parentWidget() ->width() ) )
+ tbHandlePixel = tqstyle().tqpixelMetric( TQStyle::PM_DockWindowHandleExtent, this );
+ int buttonAreaWidth = taskBarWidth - tbHandlePixel - tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth, this ) - 5;
+ if ( ( ( allButtonsWidthHint ) <= buttonAreaWidth ) || ( width() < tqparentWidget() ->width() ) )
{
for ( b = m_pButtonList->first();b;b = m_pButtonList->next() )
{
b->setText( b->actualText() );
- if ( b->width() != b->sizeHint().width() )
+ if ( b->width() != b->tqsizeHint().width() )
{
- b->setFixedWidth( b->sizeHint().width() );
+ b->setFixedWidth( b->tqsizeHint().width() );
b->show();
}
}
@@ -381,10 +381,10 @@ void KMdiTaskBar::resizeEvent( TQResizeEvent* rse )
{
if ( m_pButtonList->count() != 0 )
{
- layoutTaskBar( rse->size().width() );
+ tqlayoutTaskBar( rse->size().width() );
}
}
KToolBar::resizeEvent( rse );
}
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmditaskbar.h b/lib/compatibility/kmdi/qextmdi/kmditaskbar.h
index c333070a..2de377cb 100644
--- a/lib/compatibility/kmdi/qextmdi/kmditaskbar.h
+++ b/lib/compatibility/kmdi/qextmdi/kmditaskbar.h
@@ -6,8 +6,8 @@
// begin : 07/1999 by Szymon Stefanek as part of kvirc
// (an IRC application)
// changes : 09/1999 by Falk Brettschneider to create an
-// - 06/2000 stand-alone Qt extension set of
-// classes and a Qt-based library
+// - 06/2000 stand-alone TQt extension set of
+// classes and a TQt-based library
// 2000-2003 maintained by the KDevelop project
//
// copyright : (C) 1999-2003 by Falk Brettschneider
@@ -48,9 +48,10 @@ class KMdiTaskBarButtonPrivate;
* It's a special kind of TQPushButton catching mouse clicks.
* And you have the ability to abbreviate the text that it fits in the button.
*/
-class KMdiTaskBarButton : public QPushButton
+class KMdiTaskBarButton : public TQPushButton
{
Q_OBJECT
+ TQ_OBJECT
// methods
public:
/**
@@ -87,7 +88,7 @@ signals:
*/
void rightMouseButtonClicked( KMdiChildView* );
/**
- * Emitted when the button text has changed. Internally connected with KMdiTaskBar::layoutTaskBar
+ * Emitted when the button text has changed. Internally connected with KMdiTaskBar::tqlayoutTaskBar
*/
void buttonTextChanged( int );
public slots:
@@ -129,11 +130,12 @@ class KMdiTaskBarPrivate;
class KMDI_EXPORT KMdiTaskBar : public KToolBar
{
Q_OBJECT
+ TQ_OBJECT
public:
/**
* Constructor (NoFocus, minimum width = 1, an internal TQPtrList of taskbar buttons (autodelete))
*/
- KMdiTaskBar( KMdiMainFrm *parent, TQMainWindow::ToolBarDock dock );
+ KMdiTaskBar( KMdiMainFrm *tqparent, TQMainWindow::ToolBarDock dock );
/**
* Destructor (deletes the taskbar button list)
*/
@@ -171,7 +173,7 @@ public:
};
protected:
/**
- * Reimplemented from its base class to call layoutTaskBar, additionally.
+ * Reimplemented from its base class to call tqlayoutTaskBar, additionally.
*/
void resizeEvent( TQResizeEvent* );
protected slots:
@@ -182,7 +184,7 @@ protected slots:
* fixed width and show() is called for each one.
* If one drags the taskbar to a vertical orientation, the button width is set to 80 pixel.
*/
- void layoutTaskBar( int taskBarWidth = 0 );
+ void tqlayoutTaskBar( int taskBarWidth = 0 );
public slots:
/**
* Pushes the desired taskbar button down (switch on), the old one is released (switched off).
@@ -196,7 +198,7 @@ protected:
*/
TQPtrList<KMdiTaskBarButton>* m_pButtonList;
/**
- * The belonging MDI mainframe (parent widget of this)
+ * The belonging MDI mainframe (tqparent widget of this)
*/
KMdiMainFrm* m_pFrm;
/**
@@ -215,5 +217,5 @@ private:
};
#endif //_KMDITASKBAR_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.cpp b/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.cpp
index 1d2cce94..af304edf 100644
--- a/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.cpp
@@ -29,10 +29,10 @@
#include "kmditoolviewaccessor.h"
#include "kmditoolviewaccessor_p.h"
-KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *parent, TQWidget *widgetToWrap, const TQString& tabToolTip, const TQString& tabCaption )
- : TQObject( parent )
+KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *tqparent, TQWidget *widgetToWrap, const TQString& tabToolTip, const TQString& tabCaption )
+ : TQObject( tqparent )
{
- mdiMainFrm = parent;
+ mdiMainFrm = tqparent;
d = new KMdiToolViewAccessorPrivate();
if ( widgetToWrap->inherits( "KDockWidget" ) )
{
@@ -55,9 +55,9 @@ KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *parent, TQWidget *widge
{
finalTabCaption = tabCaption;
}
- d->widgetContainer = parent->createDockWidget( widgetToWrap->name(),
+ d->widgetContainer = tqparent->createDockWidget( widgetToWrap->name(),
( widgetToWrap->icon() ? ( *( widgetToWrap->icon() ) ) : TQPixmap() ),
- 0L, // parent
+ 0L, // tqparent
widgetToWrap->caption(),
finalTabCaption );
d->widgetContainer->setWidget( widgetToWrap );
@@ -75,9 +75,9 @@ KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *parent, TQWidget *widge
d->widget->installEventFilter( this );
}
-KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *parent )
+KMdiToolViewAccessor::KMdiToolViewAccessor( KMdiMainFrm *tqparent )
{
- mdiMainFrm = parent;
+ mdiMainFrm = tqparent;
d = new KMdiToolViewAccessorPrivate();
}
@@ -133,7 +133,7 @@ void KMdiToolViewAccessor::setWidgetToWrap( TQWidget *widgetToWrap, const TQStri
{
tmp = mdiMainFrm->createDockWidget( widgetToWrap->name(),
widgetToWrap->icon() ? ( *( widgetToWrap->icon() ) ) : TQPixmap(),
- 0L, // parent
+ 0L, // tqparent
widgetToWrap->caption(),
finalTabCaption );
d->widgetContainer = tmp;
@@ -186,7 +186,7 @@ void KMdiToolViewAccessor::place( KDockWidget::DockPosition pos, TQWidget* pTarg
if ( pos == KDockWidget::DockNone )
{
d->widgetContainer->setEnableDocking( KDockWidget::DockNone );
- d->widgetContainer->reparent( mdiMainFrm, Qt::WType_TopLevel | Qt::WType_Dialog, TQPoint( 0, 0 ), true ); //pToolView->isVisible());
+ d->widgetContainer->reparent( mdiMainFrm, TQt::WType_TopLevel | TQt::WType_Dialog, TQPoint( 0, 0 ), true ); //pToolView->isVisible());
}
else
{ // add (and dock) the toolview as DockWidget view
@@ -222,9 +222,9 @@ void KMdiToolViewAccessor::place( KDockWidget::DockPosition pos, TQWidget* pTarg
pTargetDock = mdiMainFrm->dockManager->findWidgetParentDock( pTargetWnd );
if ( !pTargetDock )
{
- if ( pTargetWnd->parentWidget() )
+ if ( pTargetWnd->tqparentWidget() )
{
- pTargetDock = mdiMainFrm->dockManager->findWidgetParentDock( pTargetWnd->parentWidget() );
+ pTargetDock = mdiMainFrm->dockManager->findWidgetParentDock( pTargetWnd->tqparentWidget() );
}
}
}
@@ -262,8 +262,8 @@ void KMdiToolViewAccessor::show()
}
-#ifndef NO_INCLUDE_MOCFILES
+#ifndef NO_INCLUDE_TQMOCFILES
#include "kmditoolviewaccessor.moc"
#endif
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.h b/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.h
index 28241ea3..bb21bbcb 100644
--- a/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.h
+++ b/lib/compatibility/kmdi/qextmdi/kmditoolviewaccessor.h
@@ -35,9 +35,10 @@ class KMDIGUIClient;
}
-class KMDI_EXPORT KMdiToolViewAccessor : public QObject
+class KMDI_EXPORT KMdiToolViewAccessor : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
friend class KMdiMainFrm;
@@ -60,8 +61,8 @@ private:
bool m_bFocusInEventIsPending;
private:
- KMdiToolViewAccessor( class KMdiMainFrm *parent , TQWidget *widgetToWrap, const TQString& tabToolTip = 0, const TQString& tabCaption = 0 );
- KMdiToolViewAccessor( class KMdiMainFrm *parent );
+ KMdiToolViewAccessor( class KMdiMainFrm *tqparent , TQWidget *widgetToWrap, const TQString& tabToolTip = 0, const TQString& tabCaption = 0 );
+ KMdiToolViewAccessor( class KMdiMainFrm *tqparent );
public:
~KMdiToolViewAccessor();
TQWidget *wrapperWidget();
@@ -82,5 +83,5 @@ protected:
#endif //_KMDITOOLVIEWACCESSOR_H_
-// kate: space-indent off; tab-width 4; replace-tabs off; indent-mode csands;
+// kate: space-indent off; tab-width 4; tqreplace-tabs off; indent-mode csands;
diff --git a/lib/compatibility/kmdi/qextmdi/kmultitabbar.cpp b/lib/compatibility/kmdi/qextmdi/kmultitabbar.cpp
index 853f8e8e..3ad39b1c 100644
--- a/lib/compatibility/kmdi/qextmdi/kmultitabbar.cpp
+++ b/lib/compatibility/kmdi/qextmdi/kmultitabbar.cpp
@@ -47,7 +47,7 @@ public:
};
-KMultiTabBarInternal::KMultiTabBarInternal(TQWidget *parent, KMultiTabBar::KMultiTabBarMode bm):TQScrollView(parent)
+KMultiTabBarInternal::KMultiTabBarInternal(TQWidget *tqparent, KMultiTabBar::KMultiTabBarMode bm):TQScrollView(tqparent)
{
m_expandedTabSize=-1;
m_showActiveTabTexts=false;
@@ -73,9 +73,9 @@ KMultiTabBarInternal::KMultiTabBarInternal(TQWidget *parent, KMultiTabBar::KMult
}
addChild(box);
setFrameStyle(NoFrame);
- viewport()->setBackgroundMode(Qt::PaletteBackground);
-/* box->setPaletteBackgroundColor(Qt::red);
- setPaletteBackgroundColor(Qt::green);*/
+ viewport()->setBackgroundMode(TQt::PaletteBackground);
+/* box->setPaletteBackgroundColor(TQt::red);
+ setPaletteBackgroundColor(TQt::green);*/
}
void KMultiTabBarInternal::setStyle(enum KMultiTabBar::KMultiTabBarStyle style)
@@ -110,7 +110,7 @@ void KMultiTabBarInternal::setStyle(enum KMultiTabBar::KMultiTabBarStyle style)
mainLayout->setAutoAdd(true);
}
- viewport()->repaint();
+ viewport()->tqrepaint();
}
void KMultiTabBarInternal::drawContents ( TQPainter * paint, int clipx, int clipy, int clipw, int cliph )
@@ -120,9 +120,9 @@ void KMultiTabBarInternal::drawContents ( TQPainter * paint, int clipx, int clip
if (m_position==KMultiTabBar::Right)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(1,0,1,viewport()->height());
@@ -130,28 +130,28 @@ void KMultiTabBarInternal::drawContents ( TQPainter * paint, int clipx, int clip
else
if (m_position==KMultiTabBar::Left)
{
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(23,0,23,viewport()->height());
paint->drawLine(22,0,22,viewport()->height());
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());
}
else
if (m_position==KMultiTabBar::Bottom)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,viewport()->width(),0);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,1,viewport()->width(),1);
}
else
{
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(0,23,viewport()->width(),23);
paint->drawLine(0,22,viewport()->width(),22);
-/* paint->setPen(colorGroup().shadow());
+/* paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,viewport()->height());*/
}
@@ -188,8 +188,8 @@ void KMultiTabBarInternal::mousePressEvent(TQMouseEvent *ev)
void KMultiTabBarInternal::resizeEvent(TQResizeEvent *ev) {
/* kdDebug()<<"KMultiTabBarInternal::resizeEvent"<<endl;
- kdDebug()<<"KMultiTabBarInternal::resizeEvent - box geometry"<<box->geometry()<<endl;
- kdDebug()<<"KMultiTabBarInternal::resizeEvent - geometry"<<geometry()<<endl;*/
+ kdDebug()<<"KMultiTabBarInternal::resizeEvent - box tqgeometry"<<box->tqgeometry()<<endl;
+ kdDebug()<<"KMultiTabBarInternal::resizeEvent - tqgeometry"<<tqgeometry()<<endl;*/
if (ev) TQScrollView::resizeEvent(ev);
if ( (m_style==KMultiTabBar::KDEV3) ||
@@ -346,7 +346,7 @@ int KMultiTabBarInternal::appendTab(const TQPixmap &pic ,int id,const TQString&
tab->installEventFilter(this);
tab->showActiveTabText(m_showActiveTabTexts);
- if (m_style==KMultiTabBar::KONQSBC)
+ if (m_style==KMultiTabBar::KONTQSBC)
{
if (m_expandedTabSize<tab->neededSize()) {
m_expandedTabSize=tab->neededSize();
@@ -378,13 +378,13 @@ void KMultiTabBarInternal::setPosition(enum KMultiTabBar::KMultiTabBarPosition p
m_position=pos;
for (uint i=0;i<m_tabs.count();i++)
m_tabs.at(i)->setTabsPosition(m_position);
- viewport()->repaint();
+ viewport()->tqrepaint();
}
KMultiTabBarButton::KMultiTabBarButton(const TQPixmap& pic,const TQString& text, TQPopupMenu *popup,
- int id,TQWidget *parent,KMultiTabBar::KMultiTabBarPosition pos,KMultiTabBar::KMultiTabBarStyle style)
- :TQPushButton(TQIconSet(),text,parent),m_style(style)
+ int id,TQWidget *tqparent,KMultiTabBar::KMultiTabBarPosition pos,KMultiTabBar::KMultiTabBarStyle style)
+ :TQPushButton(TQIconSet(),text,tqparent),m_style(style)
{
setIconSet(pic);
setText(text);
@@ -399,8 +399,8 @@ KMultiTabBarButton::KMultiTabBarButton(const TQPixmap& pic,const TQString& text,
}
KMultiTabBarButton::KMultiTabBarButton(const TQString& text, TQPopupMenu *popup,
- int id,TQWidget *parent,KMultiTabBar::KMultiTabBarPosition pos,KMultiTabBar::KMultiTabBarStyle style)
- :TQPushButton(TQIconSet(),text,parent),m_style(style)
+ int id,TQWidget *tqparent,KMultiTabBar::KMultiTabBarPosition pos,KMultiTabBar::KMultiTabBarStyle style)
+ :TQPushButton(TQIconSet(),text,tqparent),m_style(style)
{
setText(text);
m_position=pos;
@@ -435,45 +435,45 @@ void KMultiTabBarButton::slotClicked()
void KMultiTabBarButton::setPosition(KMultiTabBar::KMultiTabBarPosition pos)
{
m_position=pos;
- repaint();
+ tqrepaint();
}
void KMultiTabBarButton::setStyle(KMultiTabBar::KMultiTabBarStyle style)
{
m_style=style;
- repaint();
+ tqrepaint();
}
void KMultiTabBarButton::hideEvent( TQHideEvent* he) {
TQPushButton::hideEvent(he);
- KMultiTabBar *tb=dynamic_cast<KMultiTabBar*>(parentWidget());
+ KMultiTabBar *tb=dynamic_cast<KMultiTabBar*>(tqparentWidget());
if (tb) tb->updateSeparator();
}
void KMultiTabBarButton::showEvent( TQShowEvent* he) {
TQPushButton::showEvent(he);
- KMultiTabBar *tb=dynamic_cast<KMultiTabBar*>(parentWidget());
+ KMultiTabBar *tb=dynamic_cast<KMultiTabBar*>(tqparentWidget());
if (tb) tb->updateSeparator();
}
-TQSize KMultiTabBarButton::sizeHint() const
+TQSize KMultiTabBarButton::tqsizeHint() const
{
constPolish();
int w = 0, h = 0;
// calculate contents size...
-#ifndef QT_NO_ICONSET
+#ifndef TQT_NO_ICONSET
if ( iconSet() && !iconSet()->isNull() ) {
int iw = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4;
int ih = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).height();
w += iw;
- h = QMAX( h, ih );
+ h = TQMAX( h, ih );
}
#endif
if ( isMenuButton() )
- w += style().pixelMetric(TQStyle::PM_MenuButtonIndicator, this);
+ w += tqstyle().tqpixelMetric(TQStyle::PM_MenuButtonIndicator, this);
if ( pixmap() ) {
TQPixmap *pm = (TQPixmap *)pixmap();
@@ -483,24 +483,24 @@ TQSize KMultiTabBarButton::sizeHint() const
TQString s( text() );
bool empty = s.isEmpty();
if ( empty )
- s = TQString::fromLatin1("XXXX");
+ s = TQString::tqfromLatin1("XXXX");
TQFontMetrics fm = fontMetrics();
TQSize sz = fm.size( ShowPrefix, s );
if(!empty || !w)
w += sz.width();
if(!empty || !h)
- h = QMAX(h, sz.height());
+ h = TQMAX(h, sz.height());
}
- return (style().sizeFromContents(TQStyle::CT_ToolButton, this, TQSize(w, h)).
+ return (tqstyle().tqsizeFromContents(TQStyle::CT_ToolButton, this, TQSize(w, h)).
expandedTo(TQApplication::globalStrut()));
}
KMultiTabBarTab::KMultiTabBarTab(const TQPixmap& pic, const TQString& text,
- int id,TQWidget *parent,KMultiTabBar::KMultiTabBarPosition pos,
+ int id,TQWidget *tqparent,KMultiTabBar::KMultiTabBarPosition pos,
KMultiTabBar::KMultiTabBarStyle style)
- :KMultiTabBarButton(text,0,id,parent,pos,style),
+ :KMultiTabBarButton(text,0,id,tqparent,pos,style),
m_showActiveTabText(false)
{
d=new KMultiTabBarTabPrivate();
@@ -526,7 +526,7 @@ void KMultiTabBarTab::setTabsPosition(KMultiTabBar::KMultiTabBarPosition pos)
}
setPosition(pos);
-// repaint();
+// tqrepaint();
}
void KMultiTabBarTab::setIcon(const TQString& icon)
@@ -567,23 +567,23 @@ void KMultiTabBarTab::setState(bool b)
void KMultiTabBarTab::updateState()
{
- if (m_style!=KMultiTabBar::KONQSBC) {
+ if (m_style!=KMultiTabBar::KONTQSBC) {
if ((m_style==KMultiTabBar::KDEV3) || (m_style==KMultiTabBar::KDEV3ICON) || (isOn())) {
TQPushButton::setText(m_text);
} else {
kdDebug()<<"KMultiTabBarTab::updateState(): setting text to an empty TQString***************"<<endl;
- TQPushButton::setText(TQString::null);
+ TQPushButton::setText(TQString());
}
if ((m_position==KMultiTabBar::Right || m_position==KMultiTabBar::Left)) {
setFixedWidth(24);
if ((m_style==KMultiTabBar::KDEV3) || (m_style==KMultiTabBar::KDEV3ICON) || (isOn())) {
- setFixedHeight(KMultiTabBarButton::sizeHint().width());
+ setFixedHeight(KMultiTabBarButton::tqsizeHint().width());
} else setFixedHeight(36);
} else {
setFixedHeight(24);
if ((m_style==KMultiTabBar::KDEV3) || (m_style==KMultiTabBar::KDEV3ICON) || (isOn())) {
- setFixedWidth(KMultiTabBarButton::sizeHint().width());
+ setFixedWidth(KMultiTabBarButton::tqsizeHint().width());
} else setFixedWidth(36);
}
} else {
@@ -623,7 +623,7 @@ void KMultiTabBarTab::drawButtonLabel(TQPainter *p) {
}
void KMultiTabBarTab::drawButton(TQPainter *paint)
{
- if (m_style!=KMultiTabBar::KONQSBC) drawButtonStyled(paint);
+ if (m_style!=KMultiTabBar::KONTQSBC) drawButtonStyled(paint);
else drawButtonClassic(paint);
}
@@ -634,7 +634,7 @@ void KMultiTabBarTab::drawButtonStyled(TQPainter *paint) {
const int height = 24;
if ((m_style==KMultiTabBar::KDEV3) || (m_style==KMultiTabBar::KDEV3ICON) || (isOn())) {
if ((m_position==KMultiTabBar::Left) || (m_position==KMultiTabBar::Right))
- sh=TQSize(this->height(),this->width());//KMultiTabBarButton::sizeHint();
+ sh=TQSize(this->height(),this->width());//KMultiTabBarButton::tqsizeHint();
else sh=TQSize(this->width(),this->height());
}
else
@@ -651,8 +651,8 @@ void KMultiTabBarTab::drawButtonStyled(TQPainter *paint) {
if (isOn()) st|=TQStyle::Style_On;
- style().drawControl(TQStyle::CE_PushButton,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), colorGroup(),st);
- style().drawControl(TQStyle::CE_PushButtonLabel,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), colorGroup(),st);
+ tqstyle().tqdrawControl(TQStyle::CE_PushButton,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), tqcolorGroup(),st);
+ tqstyle().tqdrawControl(TQStyle::CE_PushButtonLabel,&painter,this, TQRect(0,0,pixmap.width(),pixmap.height()), tqcolorGroup(),st);
switch (m_position) {
case KMultiTabBar::Left:
@@ -668,8 +668,8 @@ void KMultiTabBarTab::drawButtonStyled(TQPainter *paint) {
paint->drawPixmap(0,0,pixmap);
break;
}
-// style().drawControl(TQStyle::CE_PushButtonLabel,painter,this, TQRect(0,0,pixmap.width(),pixmap.height()),
-// colorGroup(),TQStyle::Style_Enabled);
+// tqstyle().tqdrawControl(TQStyle::CE_PushButtonLabel,painter,this, TQRect(0,0,pixmap.width(),pixmap.height()),
+// tqcolorGroup(),TQStyle::Style_Enabled);
}
@@ -679,58 +679,58 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
TQPixmap pixmap;
if ( iconSet())
pixmap = iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal );
- paint->fillRect(0, 0, 24, 24, colorGroup().background());
+ paint->fillRect(0, 0, 24, 24, tqcolorGroup().background());
if (!isOn())
{
if (m_position==KMultiTabBar::Right)
{
- paint->fillRect(0,0,21,21,TQBrush(colorGroup().background()));
+ paint->fillRect(0,0,21,21,TQBrush(tqcolorGroup().background()));
- paint->setPen(colorGroup().background().dark(150));
+ paint->setPen(tqcolorGroup().background().dark(150));
paint->drawLine(0,22,23,22);
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,23);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(1,0,1,23);
}
else
if ((m_position==KMultiTabBar::Bottom) || (m_position==KMultiTabBar::Top))
{
- paint->fillRect(0,1,23,22,TQBrush(colorGroup().background()));
+ paint->fillRect(0,1,23,22,TQBrush(tqcolorGroup().background()));
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(23,0,23,23);
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(0,22,23,22);
paint->drawLine(0,23,23,23);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,23,0);
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,1,23,1);
}
else
{
- paint->setPen(colorGroup().background().dark(120));
+ paint->setPen(tqcolorGroup().background().dark(120));
paint->drawLine(0,23,23,23);
- paint->fillRect(0,0,23,21,TQBrush(colorGroup().background()));
+ paint->fillRect(0,0,23,21,TQBrush(tqcolorGroup().background()));
paint->drawPixmap(12-pixmap.width()/2,12-pixmap.height()/2,pixmap);
- paint->setPen(colorGroup().light());
+ paint->setPen(tqcolorGroup().light());
paint->drawLine(23,0,23,23);
paint->drawLine(22,0,22,23);
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,0,0,23);
}
@@ -741,12 +741,12 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
{
if (m_position==KMultiTabBar::Right)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,height()-1,23,height()-1);
paint->drawLine(0,height()-2,23,height()-2);
paint->drawLine(23,0,23,height()-1);
paint->drawLine(22,0,22,height()-1);
- paint->fillRect(0,0,21,height()-3,TQBrush(colorGroup().light()));
+ paint->fillRect(0,0,21,height()-3,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
@@ -756,9 +756,9 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
TQPixmap tpixmap(height()-25-3, width()-2);
TQPainter painter(&tpixmap);
- painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(colorGroup().light()));
+ painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(tqcolorGroup().light()));
- painter.setPen(colorGroup().text());
+ painter.setPen(tqcolorGroup().text());
painter.drawText(0,+width()/2+TQFontMetrics(TQFont()).height()/2,m_text);
paint->rotate(90);
@@ -770,25 +770,25 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
else
if (m_position==KMultiTabBar::Top)
{
- paint->fillRect(0,0,width()-1,23,TQBrush(colorGroup().light()));
+ paint->fillRect(0,0,width()-1,23,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
- paint->setPen(colorGroup().text());
+ paint->setPen(tqcolorGroup().text());
paint->drawText(25,height()/2+TQFontMetrics(TQFont()).height()/2,m_text);
}
}
else
if (m_position==KMultiTabBar::Bottom)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,23,width()-1,23);
paint->drawLine(0,22,width()-1,22);
- paint->fillRect(0,0,width()-1,21,TQBrush(colorGroup().light()));
+ paint->fillRect(0,0,width()-1,21,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
- paint->setPen(colorGroup().text());
+ paint->setPen(tqcolorGroup().text());
paint->drawText(25,height()/2+TQFontMetrics(TQFont()).height()/2,m_text);
}
@@ -797,10 +797,10 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
{
- paint->setPen(colorGroup().shadow());
+ paint->setPen(tqcolorGroup().shadow());
paint->drawLine(0,height()-1,23,height()-1);
paint->drawLine(0,height()-2,23,height()-2);
- paint->fillRect(0,0,23,height()-3,TQBrush(colorGroup().light()));
+ paint->fillRect(0,0,23,height()-3,TQBrush(tqcolorGroup().light()));
paint->drawPixmap(10-pixmap.width()/2,10-pixmap.height()/2,pixmap);
if (m_showActiveTabText)
{
@@ -810,9 +810,9 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
TQPixmap tpixmap(height()-25-3, width()-2);
TQPainter painter(&tpixmap);
- painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(colorGroup().light()));
+ painter.fillRect(0,0,tpixmap.width(),tpixmap.height(),TQBrush(tqcolorGroup().light()));
- painter.setPen(colorGroup().text());
+ painter.setPen(tqcolorGroup().text());
painter.drawText(tpixmap.width()-TQFontMetrics(TQFont()).width(m_text),+width()/2+TQFontMetrics(TQFont()).height()/2,m_text);
paint->rotate(-90);
@@ -833,19 +833,19 @@ void KMultiTabBarTab::drawButtonClassic(TQPainter *paint)
-KMultiTabBar::KMultiTabBar(KMultiTabBarMode bm, TQWidget *parent,const char *name):TQWidget(parent,name)
+KMultiTabBar::KMultiTabBar(KMultiTabBarMode bm, TQWidget *tqparent,const char *name):TQWidget(tqparent,name)
{
m_buttons.setAutoDelete(false);
if (bm==Vertical)
{
m_l=new TQVBoxLayout(this);
- setSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Expanding, true);
+ tqsetSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Expanding, true);
// setFixedWidth(24);
}
else
{
m_l=new TQHBoxLayout(this);
- setSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, true);
+ tqsetSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, true);
// setFixedHeight(24);
}
m_l->setMargin(0);
@@ -855,7 +855,7 @@ KMultiTabBar::KMultiTabBar(KMultiTabBarMode bm, TQWidget *parent,const char *nam
setPosition((bm==KMultiTabBar::Vertical)?KMultiTabBar::Right:KMultiTabBar::Bottom);
setStyle(VSNET);
// setStyle(KDEV3);
- //setStyle(KONQSBC);
+ //setStyle(KONTQSBC);
m_l->insertWidget(0,m_internal);
m_l->insertWidget(0,m_btnTabSep=new TQFrame(this));
m_btnTabSep->setFixedHeight(4);
@@ -878,7 +878,7 @@ KMultiTabBar::~KMultiTabBar() {
int KMultiTabBar::appendButton(const TQPixmap &pic ,int id,TQPopupMenu *popup,const TQString&)
{
KMultiTabBarButton *btn;
- m_buttons.append(btn= new KMultiTabBarButton(pic,TQString::null,
+ m_buttons.append(btn= new KMultiTabBarButton(pic,TQString(),
popup,id,this,m_position,m_internal->m_style));
m_l->insertWidget(0,btn);
btn->show();
@@ -980,7 +980,7 @@ void KMultiTabBar::fontChange(const TQFont& /* oldFont */)
{
for (uint i=0;i<tabs()->count();i++)
tabs()->at(i)->resize();
- repaint();
+ tqrepaint();
}
TQPtrList<KMultiTabBarTab>* KMultiTabBar::tabs() {return m_internal->tabs();}
diff --git a/lib/compatibility/kmdi/qextmdi/kmultitabbar.h b/lib/compatibility/kmdi/qextmdi/kmultitabbar.h
index 575c3c65..39f701af 100644
--- a/lib/compatibility/kmdi/qextmdi/kmultitabbar.h
+++ b/lib/compatibility/kmdi/qextmdi/kmultitabbar.h
@@ -51,22 +51,23 @@ class KMultiTabBarInternal;
* should be raisable is left to the "user".
*@author Joseph Wenninger
*/
-class KUTILS_EXPORT KMultiTabBar: public QWidget
+class KUTILS_EXPORT KMultiTabBar: public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- enum KMultiTabBarMode{Horizontal, Vertical};
+ enum KMultiTabBarMode{Horizontal,Vertical};
enum KMultiTabBarPosition{Left, Right, Top, Bottom};
/**
* VSNET == Visual Studio .Net like (only show the text of active tabs
* KDEV3 == Kdevelop 3 like (always show the text)
- * KONQSBC == konqy's classic sidebar style (unthemed), this one is disabled
+ * KONTQSBC == konqy's classic sidebar style (unthemed), this one is disabled
* at the moment, but will be renabled soon too
*/
- enum KMultiTabBarStyle{VSNET=0, KDEV3=1, KONQSBC=2, KDEV3ICON=3,STYLELAST=0xffff};
+ enum KMultiTabBarStyle{VSNET=0, KDEV3=1, KONTQSBC=2, KDEV3ICON=3,STYLELAST=0xffff};
- KMultiTabBar(KMultiTabBarMode bm,TQWidget *parent=0,const char *name=0);
+ KMultiTabBar(KMultiTabBarMode bm,TQWidget *tqparent=0,const char *name=0);
virtual ~KMultiTabBar();
/**
@@ -78,7 +79,7 @@ public:
* @param popup A popup menu which should be displayed if the button is clicked
* @param not_used_yet will be used for a popup text in the future
*/
- int appendButton(const TQPixmap &pic,int id=-1,TQPopupMenu* popup=0,const TQString& not_used_yet=TQString::null);
+ int appendButton(const TQPixmap &pic,int id=-1,TQPopupMenu* popup=0,const TQString& not_used_yet=TQString());
/**
* remove a button with the given ID
*/
@@ -89,7 +90,7 @@ public:
* @param id an arbitrary ID which can be used later on to identify the tab
* @param text if a mode with text is used it will be the tab text, otherwise a mouse over hint
*/
- int appendTab(const TQPixmap &pic,int id=-1,const TQString& text=TQString::null);
+ int appendTab(const TQPixmap &pic,int id=-1,const TQString& text=TQString());
/**
* remove a tab with a given ID
*/
@@ -151,14 +152,15 @@ private:
/**
* This class should never be created except with the appendButton call of KMultiTabBar
*/
-class KUTILS_EXPORT KMultiTabBarButton: public QPushButton
+class KUTILS_EXPORT KMultiTabBarButton: public TQPushButton
{
Q_OBJECT
+ TQ_OBJECT
public:
KMultiTabBarButton(const TQPixmap& pic,const TQString&, TQPopupMenu *popup,
- int id,TQWidget *parent, KMultiTabBar::KMultiTabBarPosition pos, KMultiTabBar::KMultiTabBarStyle style);
+ int id,TQWidget *tqparent, KMultiTabBar::KMultiTabBarPosition pos, KMultiTabBar::KMultiTabBarStyle style);
KMultiTabBarButton(const TQString&, TQPopupMenu *popup,
- int id,TQWidget *parent, KMultiTabBar::KMultiTabBarPosition pos, KMultiTabBar::KMultiTabBarStyle style);
+ int id,TQWidget *tqparent, KMultiTabBar::KMultiTabBarPosition pos, KMultiTabBar::KMultiTabBarStyle style);
virtual ~KMultiTabBarButton();
int id() const;
@@ -179,7 +181,7 @@ public slots:
*/
void setText(const TQString &);
- TQSize sizeHint() const;
+ TQSize tqsizeHint() const;
protected:
KMultiTabBar::KMultiTabBarPosition m_position;
@@ -206,8 +208,9 @@ protected slots:
class KUTILS_EXPORT KMultiTabBarTab: public KMultiTabBarButton
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMultiTabBarTab(const TQPixmap& pic,const TQString&,int id,TQWidget *parent,
+ KMultiTabBarTab(const TQPixmap& pic,const TQString&,int id,TQWidget *tqparent,
KMultiTabBar::KMultiTabBarPosition pos,KMultiTabBar::KMultiTabBarStyle style);
virtual ~KMultiTabBarTab();
/**
diff --git a/lib/compatibility/kmdi/qextmdi/kmultitabbar_p.h b/lib/compatibility/kmdi/qextmdi/kmultitabbar_p.h
index e4820016..28ae5171 100644
--- a/lib/compatibility/kmdi/qextmdi/kmultitabbar_p.h
+++ b/lib/compatibility/kmdi/qextmdi/kmultitabbar_p.h
@@ -27,12 +27,13 @@
#include <tqscrollview.h>
#include <kmultitabbar.h>
-class KMultiTabBarInternal: public QScrollView
+class KMultiTabBarInternal: public TQScrollView
{
Q_OBJECT
+ TQ_OBJECT
public:
- KMultiTabBarInternal(TQWidget *parent,KMultiTabBar::KMultiTabBarMode bm);
- int appendTab(const TQPixmap &,int=-1,const TQString& =TQString::null);
+ KMultiTabBarInternal(TQWidget *tqparent,KMultiTabBar::KMultiTabBarMode bm);
+ int appendTab(const TQPixmap &,int=-1,const TQString& =TQString());
KMultiTabBarTab *tab(int) const;
void removeTab(int);
void setPosition(enum KMultiTabBar::KMultiTabBarPosition pos);
@@ -55,9 +56,9 @@ protected:
virtual void drawContents ( TQPainter *, int, int, int, int);
/**
- * [contentsM|m]ousePressEvent are reimplemented from QScrollView
+ * [contentsM|m]ousePressEvent are reimplemented from TQScrollView
* in order to ignore all mouseEvents on the viewport, so that the
- * parent can handle them.
+ * tqparent can handle them.
*/
virtual void contentsMousePressEvent(TQMouseEvent *);
virtual void mousePressEvent(TQMouseEvent *);
diff --git a/lib/compatibility/kmdi/qextmdi/ktabbar.cpp b/lib/compatibility/kmdi/qextmdi/ktabbar.cpp
index e961fda1..6ca33c2d 100644
--- a/lib/compatibility/kmdi/qextmdi/ktabbar.cpp
+++ b/lib/compatibility/kmdi/qextmdi/ktabbar.cpp
@@ -33,8 +33,8 @@
#include "ktabbar.h"
#include "ktabwidget.h"
-KTabBar::KTabBar( TQWidget *parent, const char *name )
- : TQTabBar( parent, name ), mReorderStartTab( -1 ), mReorderPreviousTab( -1 ),
+KTabBar::KTabBar( TQWidget *tqparent, const char *name )
+ : TQTabBar( tqparent, name ), mReorderStartTab( -1 ), mReorderPreviousTab( -1 ),
mHoverCloseButtonTab( 0 ), mDragSwitchTab( 0 ), mHoverCloseButton( 0 ),
mHoverCloseButtonEnabled( false ), mHoverCloseButtonDelayed( true ),
mTabReorderingEnabled( false ), mTabCloseActivatePrevious( false )
@@ -48,7 +48,7 @@ KTabBar::KTabBar( TQWidget *parent, const char *name )
mActivateDragSwitchTabTimer = new TQTimer( this );
connect( mActivateDragSwitchTabTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( activateDragSwitchTab() ) );
- connect(this, TQT_SIGNAL(layoutChanged()), TQT_SLOT(onLayoutChange()));
+ connect(this, TQT_SIGNAL(tqlayoutChanged()), TQT_SLOT(onLayoutChange()));
}
KTabBar::~KTabBar()
@@ -76,18 +76,18 @@ void KTabBar::setTabEnabled( int id, bool enabled )
if ( t->isEnabled() ) {
r = r.unite( t->rect() );
- tablist->append( tablist->take( tablist->findRef( t ) ) );
+ tablist->append( tablist->take( tablist->tqfindRef( t ) ) );
emit selected( t->identifier() );
}
}
- repaint( r );
+ tqrepaint( r );
}
}
}
void KTabBar::mouseDoubleClickEvent( TQMouseEvent *e )
{
- if( e->button() != LeftButton )
+ if( e->button() != Qt::LeftButton )
return;
TQTab *tab = selectTab( e->pos() );
@@ -100,11 +100,11 @@ void KTabBar::mouseDoubleClickEvent( TQMouseEvent *e )
void KTabBar::mousePressEvent( TQMouseEvent *e )
{
- if( e->button() == LeftButton ) {
+ if( e->button() == Qt::LeftButton ) {
mEnableCloseButtonTimer->stop();
mDragStart = e->pos();
}
- else if( e->button() == RightButton ) {
+ else if( e->button() == Qt::RightButton ) {
TQTab *tab = selectTab( e->pos() );
if( tab ) {
emit( contextMenu( indexOf( tab->identifier() ), mapToGlobal( e->pos() ) ) );
@@ -116,7 +116,7 @@ void KTabBar::mousePressEvent( TQMouseEvent *e )
void KTabBar::mouseMoveEvent( TQMouseEvent *e )
{
- if ( e->state() == LeftButton ) {
+ if ( e->state() == Qt::LeftButton ) {
TQTab *tab = selectTab( e->pos() );
if ( mDragSwitchTab && tab != mDragSwitchTab ) {
mActivateDragSwitchTabTimer->stop();
@@ -134,7 +134,7 @@ void KTabBar::mouseMoveEvent( TQMouseEvent *e )
}
}
}
- else if ( e->state() == MidButton ) {
+ else if ( e->state() == Qt::MidButton ) {
if (mReorderStartTab==-1) {
int delay = KGlobalSettings::dndEventDelay();
TQPoint newPos = e->pos();
@@ -172,8 +172,8 @@ void KTabBar::mouseMoveEvent( TQMouseEvent *e )
int xoff = 0, yoff = 0;
// The additional offsets were found by try and error, TODO: find the rational behind them
if ( t == tab( currentTab() ) ) {
- xoff = style().pixelMetric( TQStyle::PM_TabBarTabShiftHorizontal, this ) + 3;
- yoff = style().pixelMetric( TQStyle::PM_TabBarTabShiftVertical, this ) - 4;
+ xoff = tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabShiftHorizontal, this ) + 3;
+ yoff = tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabShiftVertical, this ) - 4;
}
else {
xoff = 7;
@@ -181,7 +181,7 @@ void KTabBar::mouseMoveEvent( TQMouseEvent *e )
}
rect.moveLeft( t->rect().left() + 2 + xoff );
rect.moveTop( t->rect().center().y()-pixmap.height()/2 + yoff );
- if ( rect.contains( e->pos() ) ) {
+ if ( rect.tqcontains( e->pos() ) ) {
if ( mHoverCloseButton ) {
if ( mHoverCloseButtonTab == t )
return;
@@ -229,7 +229,7 @@ void KTabBar::activateDragSwitchTab()
void KTabBar::mouseReleaseEvent( TQMouseEvent *e )
{
- if( e->button() == MidButton ) {
+ if( e->button() == Qt::MidButton ) {
if ( mReorderStartTab==-1 ) {
TQTab *tab = selectTab( e->pos() );
if( tab ) {
@@ -252,7 +252,7 @@ void KTabBar::dragMoveEvent( TQDragMoveEvent *e )
TQTab *tab = selectTab( e->pos() );
if( tab ) {
bool accept = false;
- // The receivers of the testCanDecode() signal has to adjust
+ // The tqreceivers of the testCanDecode() signal has to adjust
// 'accept' accordingly.
emit testCanDecode( e, accept);
if ( accept && tab != TQTabBar::tab( currentTab() ) ) {
@@ -278,10 +278,10 @@ void KTabBar::dropEvent( TQDropEvent *e )
TQTabBar::dropEvent( e );
}
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
void KTabBar::wheelEvent( TQWheelEvent *e )
{
- if ( e->orientation() == Horizontal )
+ if ( e->orientation() ==Qt::Horizontal )
return;
emit( wheelDelta( e->delta() ) );
@@ -293,16 +293,16 @@ void KTabBar::setTabColor( int id, const TQColor& color )
TQTab *t = tab( id );
if ( t ) {
mTabColors.insert( id, color );
- repaint( t->rect(), false );
+ tqrepaint( t->rect(), false );
}
}
const TQColor &KTabBar::tabColor( int id ) const
{
- if ( mTabColors.contains( id ) )
+ if ( mTabColors.tqcontains( id ) )
return mTabColors[id];
- return colorGroup().foreground();
+ return tqcolorGroup().foreground();
}
int KTabBar::insertTab( TQTab *t, int index )
@@ -311,7 +311,7 @@ int KTabBar::insertTab( TQTab *t, int index )
if ( mTabCloseActivatePrevious && count() > 2 ) {
TQPtrList<TQTab> *tablist = tabList();
- tablist->insert( count()-2, tablist->take( tablist->findRef( t ) ) );
+ tablist->insert( count()-2, tablist->take( tablist->tqfindRef( t ) ) );
}
return res;
@@ -340,8 +340,8 @@ void KTabBar::paintLabel( TQPainter *p, const TQRect& br,
r.setLeft( r.left() + pixw + 4 );
r.setRight( r.right() + 2 );
- int inactiveXShift = style().pixelMetric( TQStyle::PM_TabBarTabShiftHorizontal, this );
- int inactiveYShift = style().pixelMetric( TQStyle::PM_TabBarTabShiftVertical, this );
+ int inactiveXShift = tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabShiftHorizontal, this );
+ int inactiveYShift = tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabShiftVertical, this );
int right = t->text().isEmpty() ? br.right() - pixw : br.left() + 2;
@@ -357,12 +357,12 @@ void KTabBar::paintLabel( TQPainter *p, const TQRect& br,
if ( has_focus )
flags |= TQStyle::Style_HasFocus;
- TQColorGroup cg( colorGroup() );
- if ( mTabColors.contains( t->identifier() ) )
+ TQColorGroup cg( tqcolorGroup() );
+ if ( mTabColors.tqcontains( t->identifier() ) )
cg.setColor( TQColorGroup::Foreground, mTabColors[t->identifier()] );
- style().drawControl( TQStyle::CE_TabBarLabel, p, this, r,
- t->isEnabled() ? cg : palette().disabled(),
+ tqstyle().tqdrawControl( TQStyle::CE_TabBarLabel, p, this, r,
+ t->isEnabled() ? cg : tqpalette().disabled(),
flags, TQStyleOption(t) );
}
diff --git a/lib/compatibility/kmdi/qextmdi/ktabbar.h b/lib/compatibility/kmdi/qextmdi/ktabbar.h
index a1928aab..44deca5e 100644
--- a/lib/compatibility/kmdi/qextmdi/ktabbar.h
+++ b/lib/compatibility/kmdi/qextmdi/ktabbar.h
@@ -32,12 +32,13 @@ class KTabBarPrivate;
/**
* @since 3.2
*/
-class KDEUI_EXPORT KTabBar: public QTabBar
+class KDEUI_EXPORT KTabBar: public TQTabBar
{
Q_OBJECT
+ TQ_OBJECT
public:
- KTabBar( TQWidget* parent=0, const char* name=0 );
+ KTabBar( TQWidget* tqparent=0, const char* name=0 );
virtual ~KTabBar();
virtual void setTabEnabled( int, bool );
@@ -69,7 +70,7 @@ signals:
void receivedDropEvent( int, TQDropEvent * );
void moveTab( int, int );
void closeRequest( int );
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
void wheelDelta( int );
#endif
@@ -78,7 +79,7 @@ protected:
virtual void mousePressEvent( TQMouseEvent *e );
virtual void mouseMoveEvent( TQMouseEvent *e );
virtual void mouseReleaseEvent( TQMouseEvent *e );
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
virtual void wheelEvent( TQWheelEvent *e );
#endif
diff --git a/lib/compatibility/kmdi/qextmdi/ktabwidget.cpp b/lib/compatibility/kmdi/qextmdi/ktabwidget.cpp
index 21ed3e82..eab93b48 100644
--- a/lib/compatibility/kmdi/qextmdi/ktabwidget.cpp
+++ b/lib/compatibility/kmdi/qextmdi/ktabwidget.cpp
@@ -48,8 +48,8 @@ public:
}
};
-KTabWidget::KTabWidget( TQWidget *parent, const char *name, WFlags f )
- : TQTabWidget( parent, name, f )
+KTabWidget::KTabWidget( TQWidget *tqparent, const char *name, WFlags f )
+ : TQTabWidget( tqparent, name, f )
{
d = new KTabWidgetPrivate;
setTabBar( new KTabBar(this, "tabbar") );
@@ -63,7 +63,7 @@ KTabWidget::KTabWidget( TQWidget *parent, const char *name, WFlags f )
connect(tabBar(), TQT_SIGNAL(receivedDropEvent( int, TQDropEvent * )), TQT_SLOT(receivedDropEvent( int, TQDropEvent * )));
connect(tabBar(), TQT_SIGNAL(moveTab( int, int )), TQT_SLOT(moveTab( int, int )));
connect(tabBar(), TQT_SIGNAL(closeRequest( int )), TQT_SLOT(closeRequest( int )));
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
connect(tabBar(), TQT_SIGNAL(wheelDelta( int )), TQT_SLOT(wheelDelta( int )));
#endif
}
@@ -160,8 +160,8 @@ bool KTabWidget::tabCloseActivatePrevious() const
unsigned int KTabWidget::tabBarWidthForMaxChars( uint maxLength )
{
int hframe, overlap;
- hframe = tabBar()->style().pixelMetric( TQStyle::PM_TabBarTabHSpace, tabBar() );
- overlap = tabBar()->style().pixelMetric( TQStyle::PM_TabBarTabOverlap, tabBar() );
+ hframe = tabBar()->tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabHSpace, tabBar() );
+ overlap = tabBar()->tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabOverlap, tabBar() );
TQFontMetrics fm = tabBar()->fontMetrics();
int x = 0;
@@ -174,8 +174,8 @@ unsigned int KTabWidget::tabBarWidthForMaxChars( uint maxLength )
int iw = 0;
if ( tab->iconSet() )
iw = tab->iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4;
- x += ( tabBar()->style().sizeFromContents( TQStyle::CT_TabBarTab, this,
- TQSize( QMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ),
+ x += ( tabBar()->tqstyle().tqsizeFromContents( TQStyle::CT_TabBarTab, this,
+ TQSize( TQMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ),
TQStyleOption( tab ) ) ).width();
}
return x;
@@ -211,7 +211,7 @@ TQString KTabWidget::label( int index ) const
if ( index >= 0 && index < count() )
return d->m_tabNames[ index ];
else
- return TQString::null;
+ return TQString();
}
else
return TQTabWidget::label( index );
@@ -222,7 +222,7 @@ TQString KTabWidget::tabLabel( TQWidget * w ) const
if ( d->m_automaticResizeTabs ) {
int index = indexOf( w );
if ( index == -1 )
- return TQString::null;
+ return TQString();
else
return d->m_tabNames[ index ];
}
@@ -250,11 +250,11 @@ void KTabWidget::resizeTabs( int changeTabIndex )
newMaxLength=d->m_maxLength;
uint lcw=0, rcw=0;
- int tabBarHeight = tabBar()->sizeHint().height();
+ int tabBarHeight = tabBar()->tqsizeHint().height();
if ( cornerWidget( TopLeft ) && cornerWidget( TopLeft )->isVisible() )
- lcw = QMAX( cornerWidget( TopLeft )->width(), tabBarHeight );
+ lcw = TQMAX( cornerWidget( TopLeft )->width(), tabBarHeight );
if ( cornerWidget( TopRight ) && cornerWidget( TopRight )->isVisible() )
- rcw = QMAX( cornerWidget( TopRight )->width(), tabBarHeight );
+ rcw = TQMAX( cornerWidget( TopRight )->width(), tabBarHeight );
uint maxTabBarWidth = width() - lcw - rcw;
@@ -284,7 +284,7 @@ void KTabWidget::updateTab( int index )
setTabToolTip( page( index ), title );
title = KStringHandler::rsqueeze( title, d->m_CurrentMaxLength ).leftJustify( d->m_minLength, ' ' );
- title.replace( '&', "&&" );
+ title.tqreplace( '&', "&&" );
if ( TQTabWidget::label( index ) != title )
TQTabWidget::setTabLabel( page( index ), title );
@@ -294,7 +294,7 @@ void KTabWidget::dragMoveEvent( TQDragMoveEvent *e )
{
if ( isEmptyTabbarSpace( e->pos() ) ) {
bool accept = false;
- // The receivers of the testCanDecode() signal has to adjust
+ // The tqreceivers of the testCanDecode() signal has to adjust
// 'accept' accordingly.
emit testCanDecode( e, accept);
e->accept( accept );
@@ -313,10 +313,10 @@ void KTabWidget::dropEvent( TQDropEvent *e )
TQTabWidget::dropEvent( e );
}
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
void KTabWidget::wheelEvent( TQWheelEvent *e )
{
- if ( e->orientation() == Horizontal )
+ if ( e->orientation() ==Qt::Horizontal )
return;
if ( isEmptyTabbarSpace( e->pos() ) )
@@ -344,7 +344,7 @@ void KTabWidget::wheelDelta( int delta )
void KTabWidget::mouseDoubleClickEvent( TQMouseEvent *e )
{
- if( e->button() != LeftButton )
+ if( e->button() != Qt::LeftButton )
return;
if ( isEmptyTabbarSpace( e->pos() ) ) {
@@ -356,12 +356,12 @@ void KTabWidget::mouseDoubleClickEvent( TQMouseEvent *e )
void KTabWidget::mousePressEvent( TQMouseEvent *e )
{
- if ( e->button() == RightButton ) {
+ if ( e->button() == Qt::RightButton ) {
if ( isEmptyTabbarSpace( e->pos() ) ) {
emit( contextMenu( mapToGlobal( e->pos() ) ) );
return;
}
- } else if ( e->button() == MidButton ) {
+ } else if ( e->button() == Qt::MidButton ) {
if ( isEmptyTabbarSpace( e->pos() ) ) {
emit( mouseMiddleClick() );
return;
@@ -413,9 +413,9 @@ void KTabWidget::moveTab( int from, int to )
TQTabWidget::insertTab( w, t, to );
if ( d->m_automaticResizeTabs ) {
if ( to < 0 || to >= count() )
- d->m_tabNames.append( TQString::null );
+ d->m_tabNames.append( TQString() );
else
- d->m_tabNames.insert( d->m_tabNames.at( to ), TQString::null );
+ d->m_tabNames.insert( d->m_tabNames.at( to ), TQString() );
}
w = page( to );
@@ -445,7 +445,7 @@ void KTabWidget::removePage( TQWidget * w ) {
bool KTabWidget::isEmptyTabbarSpace( const TQPoint &p ) const
{
TQPoint point( p );
- TQSize size( tabBar()->sizeHint() );
+ TQSize size( tabBar()->tqsizeHint() );
if ( ( tabPosition()==Top && point.y()< size.height() ) || ( tabPosition()==Bottom && point.y()>(height()-size.height() ) ) ) {
TQWidget *rightcorner = cornerWidget( TopRight );
if ( rightcorner ) {
diff --git a/lib/compatibility/kmdi/qextmdi/ktabwidget.h b/lib/compatibility/kmdi/qextmdi/ktabwidget.h
index 3a686fa3..4db91b1e 100644
--- a/lib/compatibility/kmdi/qextmdi/ktabwidget.h
+++ b/lib/compatibility/kmdi/qextmdi/ktabwidget.h
@@ -33,17 +33,18 @@ class KTabWidgetPrivate;
*
* @since 3.2
*/
-class KDEUI_EXPORT KTabWidget : public QTabWidget
+class KDEUI_EXPORT KTabWidget : public TQTabWidget
{
Q_OBJECT
- Q_PROPERTY( bool tabReorderingEnabled READ isTabReorderingEnabled WRITE setTabReorderingEnabled )
- Q_PROPERTY( bool hoverCloseButton READ hoverCloseButton WRITE setHoverCloseButton )
- Q_PROPERTY( bool hoverCloseButtonDelayed READ hoverCloseButtonDelayed WRITE setHoverCloseButtonDelayed )
- Q_PROPERTY( bool tabCloseActivatePrevious READ tabCloseActivatePrevious WRITE setTabCloseActivatePrevious )
- Q_PROPERTY( bool automaticResizeTabs READ automaticResizeTabs WRITE setAutomaticResizeTabs )
+ TQ_OBJECT
+ TQ_PROPERTY( bool tabReorderingEnabled READ isTabReorderingEnabled WRITE setTabReorderingEnabled )
+ TQ_PROPERTY( bool hoverCloseButton READ hoverCloseButton WRITE setHoverCloseButton )
+ TQ_PROPERTY( bool hoverCloseButtonDelayed READ hoverCloseButtonDelayed WRITE setHoverCloseButtonDelayed )
+ TQ_PROPERTY( bool tabCloseActivatePrevious READ tabCloseActivatePrevious WRITE setTabCloseActivatePrevious )
+ TQ_PROPERTY( bool automaticResizeTabs READ automaticResizeTabs WRITE setAutomaticResizeTabs )
public:
- KTabWidget( TQWidget *parent = 0, const char *name = 0, WFlags f = 0 );
+ KTabWidget( TQWidget *tqparent = 0, const char *name = 0, WFlags f = 0 );
/**
* Destructor.
*/
@@ -264,7 +265,7 @@ protected:
virtual void dragMoveEvent( TQDragMoveEvent * );
virtual void dropEvent( TQDropEvent * );
unsigned int tabBarWidthForMaxChars( uint maxLength );
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
virtual void wheelEvent( TQWheelEvent *e );
#endif
virtual void resizeEvent( TQResizeEvent * );
@@ -276,7 +277,7 @@ protected slots:
virtual void mouseDoubleClick( int );
virtual void mouseMiddleClick( int );
virtual void closeRequest( int );
-#ifndef QT_NO_WHEELEVENT
+#ifndef TQT_NO_WHEELEVENT
virtual void wheelDelta( int );
#endif