diff options
Diffstat (limited to 'kate/cppsymbolviewer/plugin_katesymbolviewer.cpp')
-rw-r--r-- | kate/cppsymbolviewer/plugin_katesymbolviewer.cpp | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/kate/cppsymbolviewer/plugin_katesymbolviewer.cpp b/kate/cppsymbolviewer/plugin_katesymbolviewer.cpp index 3e18097..9165878 100644 --- a/kate/cppsymbolviewer/plugin_katesymbolviewer.cpp +++ b/kate/cppsymbolviewer/plugin_katesymbolviewer.cpp @@ -11,11 +11,11 @@ * Nov 28 2003 v.1.1 - Structured for multilanguage support * Added preliminary Tcl/Tk parser (thanks Rohit). To be improved. * Various bugfixing. - * Jun 19 2003 v.1.0 - Removed QTimer (polling is Evil(tm)... ) + * Jun 19 2003 v.1.0 - Removed TQTimer (polling is Evil(tm)... ) * - Captured documentChanged() event to refresh symbol list * - Tooltips vanished into nowhere...sigh :( * May 04 2003 v 0.6 - Symbol List becomes a KListView object. Removed Tooltip class. - * Added a QTimer that every 200ms checks: + * Added a TQTimer that every 200ms checks: * * if the list width has changed * * if the document has changed * Added an entry in the popup menu to switch between List and Tree mode @@ -47,15 +47,15 @@ #include <kgenericfactory.h> #include <kfiledialog.h> -#include <qlayout.h> -#include <qgroupbox.h> +#include <tqlayout.h> +#include <tqgroupbox.h> K_EXPORT_COMPONENT_FACTORY( katecppsymbolviewerplugin, KGenericFactory<KatePluginSymbolViewer>( "katesymbolviewer" ) ) KatePluginSymbolViewerView::KatePluginSymbolViewerView(Kate::MainWindow *w) { KGlobal::locale()->insertCatalogue("katecppsymbolviewer"); - KToggleAction* act = new KToggleAction ( i18n("Hide Symbols"), 0, this, SLOT( slotInsertSymbol() ), actionCollection(), "view_insert_symbolviewer" ); + KToggleAction* act = new KToggleAction ( i18n("Hide Symbols"), 0, this, TQT_SLOT( slotInsertSymbol() ), actionCollection(), "view_insert_symbolviewer" ); act->setCheckedState(i18n("Show Symbols")); setInstance (new KInstance("kate")); @@ -65,15 +65,15 @@ KatePluginSymbolViewerView::KatePluginSymbolViewerView(Kate::MainWindow *w) symbols = 0; m_Active = false; - popup = new QPopupMenu(); - popup->insertItem(i18n("Refresh List"), this, SLOT(slotRefreshSymbol())); + popup = new TQPopupMenu(); + popup->insertItem(i18n("Refresh List"), this, TQT_SLOT(slotRefreshSymbol())); popup->insertSeparator(); - m_macro = popup->insertItem(i18n("Show Macros"), this, SLOT(toggleShowMacros())); - m_struct = popup->insertItem(i18n("Show Structures"), this, SLOT(toggleShowStructures())); - m_func = popup->insertItem(i18n("Show Functions"), this, SLOT(toggleShowFunctions())); + m_macro = popup->insertItem(i18n("Show Macros"), this, TQT_SLOT(toggleShowMacros())); + m_struct = popup->insertItem(i18n("Show Structures"), this, TQT_SLOT(toggleShowStructures())); + m_func = popup->insertItem(i18n("Show Functions"), this, TQT_SLOT(toggleShowFunctions())); popup->insertSeparator(); - popup->insertItem(i18n("List/Tree Mode"), this, SLOT(slotChangeMode())); - m_sort = popup->insertItem(i18n("Enable sorting"), this, SLOT(slotEnableSorting())); + popup->insertItem(i18n("List/Tree Mode"), this, TQT_SLOT(slotChangeMode())); + m_sort = popup->insertItem(i18n("Enable sorting"), this, TQT_SLOT(slotEnableSorting())); popup->setItemChecked(m_macro, true); popup->setItemChecked(m_struct, true); @@ -117,7 +117,7 @@ void KatePluginSymbolViewerView::toggleShowFunctions(void) void KatePluginSymbolViewerView::slotInsertSymbol() { - QPixmap cls( ( const char** ) class_xpm ); + TQPixmap cls( ( const char** ) class_xpm ); if (m_Active == false) { @@ -126,17 +126,17 @@ void KatePluginSymbolViewerView::slotInsertSymbol() symbols = new KListView(dock); treeMode = 0; - connect(symbols, SIGNAL(executed(QListViewItem *)), this, SLOT(goToSymbol(QListViewItem *))); - connect(symbols, SIGNAL(rightButtonClicked(QListViewItem *, const QPoint&, int)), - SLOT(slotShowContextMenu(QListViewItem *, const QPoint&, int))); - connect(win->viewManager(), SIGNAL(viewChanged()), this, SLOT(slotDocChanged())); - //connect(symbols, SIGNAL(resizeEvent(QResizeEvent *)), this, SLOT(slotViewChanged(QResizeEvent *))); + connect(symbols, TQT_SIGNAL(executed(TQListViewItem *)), this, TQT_SLOT(goToSymbol(TQListViewItem *))); + connect(symbols, TQT_SIGNAL(rightButtonClicked(TQListViewItem *, const TQPoint&, int)), + TQT_SLOT(slotShowContextMenu(TQListViewItem *, const TQPoint&, int))); + connect(win->viewManager(), TQT_SIGNAL(viewChanged()), this, TQT_SLOT(slotDocChanged())); + //connect(symbols, TQT_SIGNAL(resizeEvent(TQResizeEvent *)), this, TQT_SLOT(slotViewChanged(TQResizeEvent *))); m_Active = true; //symbols->addColumn(i18n("Symbols"), symbols->parentWidget()->width()); symbols->addColumn(i18n("Symbols")); symbols->addColumn(i18n("Position")); - symbols->setColumnWidthMode(1, QListView::Manual); + symbols->setColumnWidthMode(1, TQListView::Manual); symbols->setColumnWidth ( 1, 0 ); symbols->setSorting(-1, FALSE); symbols->setRootIsDecorated(0); @@ -189,13 +189,13 @@ void KatePluginSymbolViewerView::slotDocChanged() slotRefreshSymbol(); } -void KatePluginSymbolViewerView::slotViewChanged(QResizeEvent *) +void KatePluginSymbolViewerView::slotViewChanged(TQResizeEvent *) { kdDebug(13000)<<"View changed !!!!"<<endl; symbols->setColumnWidth(0, symbols->parentWidget()->width()); } -void KatePluginSymbolViewerView::slotShowContextMenu(QListViewItem *, const QPoint &p, int) +void KatePluginSymbolViewerView::slotShowContextMenu(TQListViewItem *, const TQPoint &p, int) { popup->popup(p); } @@ -215,9 +215,9 @@ void KatePluginSymbolViewerView::parseSymbols(void) /** Get the current highlighting mode */ hlMode = kv->hlMode(); - QString hlModeName = kv->hlModeName(hlMode); + TQString hlModeName = kv->hlModeName(hlMode); - //QListViewItem mcrNode = new QListViewItem(symbols, symbols->lastItem(), hlModeName); + //TQListViewItem mcrNode = new TQListViewItem(symbols, symbols->lastItem(), hlModeName); if (hlModeName == "C++" || hlModeName == "C") parseCppSymbols(); @@ -227,7 +227,7 @@ void KatePluginSymbolViewerView::parseSymbols(void) parseCppSymbols(); } -void KatePluginSymbolViewerView::goToSymbol(QListViewItem *it) +void KatePluginSymbolViewerView::goToSymbol(TQListViewItem *it) { Kate::View *kv = win->viewManager()->activeView(); @@ -241,7 +241,7 @@ void KatePluginSymbolViewerView::goToSymbol(QListViewItem *it) kv->gotoLineNumber(it->text(1).toInt(NULL, 10)); } -KatePluginSymbolViewer::KatePluginSymbolViewer( QObject* parent, const char* name, const QStringList& ) +KatePluginSymbolViewer::KatePluginSymbolViewer( TQObject* parent, const char* name, const TQStringList& ) : Kate::Plugin ( (Kate::Application*)parent, name ), pConfig("katecppsymbolviewerpluginrc") { @@ -276,12 +276,12 @@ void KatePluginSymbolViewer::removeView(Kate::MainWindow *win) } Kate::PluginConfigPage* KatePluginSymbolViewer::configPage( - uint, QWidget *w, const char* /*name*/) + uint, TQWidget *w, const char* /*name*/) { KatePluginSymbolViewerConfigPage* p = new KatePluginSymbolViewerConfigPage(this, w); initConfigPage( p ); - connect( p, SIGNAL(configPageApplyRequest(KatePluginSymbolViewerConfigPage*)), - SLOT(applyConfig(KatePluginSymbolViewerConfigPage *)) ); + connect( p, TQT_SIGNAL(configPageApplyRequest(KatePluginSymbolViewerConfigPage*)), + TQT_SLOT(applyConfig(KatePluginSymbolViewerConfigPage *)) ); return (Kate::PluginConfigPage*)p; } @@ -307,24 +307,24 @@ void KatePluginSymbolViewer::applyConfig( KatePluginSymbolViewerConfigPage* p ) // BEGIN KatePluginSymbolViewerConfigPage KatePluginSymbolViewerConfigPage::KatePluginSymbolViewerConfigPage( - QObject* /*parent*/ /*= 0L*/, QWidget *parentWidget /*= 0L*/) + TQObject* /*parent*/ /*= 0L*/, TQWidget *parentWidget /*= 0L*/) : Kate::PluginConfigPage( parentWidget ) { - QVBoxLayout* top = new QVBoxLayout(this, 0, + TQVBoxLayout* top = new TQVBoxLayout(this, 0, KDialogBase::spacingHint()); - QGroupBox* gb = new QGroupBox( i18n("Parser Options"), + TQGroupBox* gb = new TQGroupBox( i18n("Parser Options"), this, "cppsymbolviewer_config_page_layout" ); gb->setColumnLayout(1, Qt::Horizontal); gb->setInsideSpacing(KDialogBase::spacingHint()); - viewReturns = new QCheckBox(i18n("Display functions parameters"), gb); - expandTree = new QCheckBox(i18n("Automatically expand nodes in tree mode"), gb); + viewReturns = new TQCheckBox(i18n("Display functions parameters"), gb); + expandTree = new TQCheckBox(i18n("Automatically expand nodes in tree mode"), gb); top->add(gb); top->addStretch(1); // throw signal changed - connect(viewReturns, SIGNAL(toggled(bool)), this, SIGNAL(changed())); - connect(expandTree, SIGNAL(toggled(bool)), this, SIGNAL(changed())); + connect(viewReturns, TQT_SIGNAL(toggled(bool)), this, TQT_SIGNAL(changed())); + connect(expandTree, TQT_SIGNAL(toggled(bool)), this, TQT_SIGNAL(changed())); } KatePluginSymbolViewerConfigPage::~KatePluginSymbolViewerConfigPage() {} |