diff options
Diffstat (limited to 'experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp')
-rw-r--r-- | experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp b/experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp index def15eb2a..c5c74851c 100644 --- a/experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp +++ b/experimental/tqtinterface/qt4/tools/designer/designer/mainwindow.cpp @@ -143,7 +143,7 @@ static TQString textNoAccel( const TQString& text) { TQString t = text; int i; - while ( (i = t.tqfind('&') )>= 0 ) { + while ( (i = t.find('&') )>= 0 ) { t.remove(i,1); } return t; @@ -752,10 +752,10 @@ void MainWindow::helpContents() TQTextStream ts( &f ); while ( !ts.eof() ) { TQString s = ts.readLine(); - int from = s.tqfind( "\"" ); + int from = s.find( "\"" ); if ( from == -1 ) continue; - int to = s.tqfindRev( "\"" ); + int to = s.findRev( "\"" ); if ( to == -1 ) continue; propertyDocumentation[ s.mid( from + 1, to - from - 1 ) ] = s.mid( to + 2 ) + "-prop"; @@ -781,7 +781,7 @@ void MainWindow::helpContents() else source = propertyDocumentation[ "TQObject/name" ]; } else { - while ( mo && !propertyDocumentation.tqcontains( ( s = TQString( mo->className() ) + "/" + cp ) ) ) + while ( mo && !propertyDocumentation.contains( ( s = TQString( mo->className() ) + "/" + cp ) ) ) mo = TQT_TQMETAOBJECT(const_cast<QMetaObject*>(mo->superClass())); if ( mo ) source = "p:" + propertyDocumentation[s]; @@ -939,12 +939,12 @@ bool MainWindow::eventFilter( TQObject *o, TQEvent *e ) TQPoint pos = ((TQMouseEvent*)e)->pos(); MenuBarEditor *m = ::tqqt_cast<MenuBarEditor*>(o); showProperties( o ); - if ( m->tqfindItem( pos ) >= m->count() ) + if ( m->findItem( pos ) >= m->count() ) m->setFocus(); } else if ( e->type() == TQEvent::MouseButtonPress && ::tqqt_cast<PopupMenuEditor*>(o) ) { PopupMenuEditor *m = ::tqqt_cast<PopupMenuEditor*>(o); PopupMenuEditorItem *i = m->at( ((TQMouseEvent*)e)->pos() ); - if ( m->tqfind( i->action() ) != -1 && !i->isSeparator() ) + if ( m->find( i->action() ) != -1 && !i->isSeparator() ) showProperties( i->action() ); } return TQMainWindow::eventFilter( o, e ); @@ -1261,7 +1261,7 @@ FormWindow *MainWindow::formWindow() if ( ::tqqt_cast<FormWindow*>(qworkspace->activeWindow()) ) fw = (FormWindow*)qworkspace->activeWindow(); else if ( lastActiveFormWindow && - qworkspace->windowList().tqfind( lastActiveFormWindow ) != -1) + qworkspace->windowList().find( lastActiveFormWindow ) != -1) fw = lastActiveFormWindow; return fw; } @@ -1555,18 +1555,18 @@ void MainWindow::popupWidgetMenu( const TQPoint &gp, FormWindow * /*fw*/, TQWidg void MainWindow::setupRMBProperties( TQValueList<uint> &ids, TQMap<TQString, int> &props, TQWidget *w ) { - const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "text", TRUE ), TRUE ); + const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "text", TRUE ), TRUE ); if ( text && qstrcmp( text->type(), "TQString") != 0 ) text = 0; - const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "title", TRUE ), TRUE ); + const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "title", TRUE ), TRUE ); if ( title && qstrcmp( title->type(), "TQString") != 0 ) title = 0; const TQMetaProperty* pagetitle = - w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "pageTitle", TRUE ), TRUE ); + w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "pageTitle", TRUE ), TRUE ); if ( pagetitle && qstrcmp( pagetitle->type(), "TQString") != 0 ) pagetitle = 0; const TQMetaProperty* pixmap = - w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "pixmap", TRUE ), TRUE ); + w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "pixmap", TRUE ), TRUE ); if ( pixmap && qstrcmp( pixmap->type(), "TQPixmap") != 0 ) pixmap = 0; @@ -2137,7 +2137,7 @@ void MainWindow::selectionChanged() static TQString fixArgs( const TQString &s2 ) { TQString s = s2; - return s.tqreplace( ',', ';' ); + return s.replace( ',', ';' ); } void MainWindow::writeConfig() @@ -2247,7 +2247,7 @@ void MainWindow::writeConfig() static TQString fixArgs2( const TQString &s2 ) { TQString s = s2; - return s.tqreplace( ';', ',' ); + return s.replace( ';', ',' ); } void MainWindow::readConfig() @@ -2295,14 +2295,14 @@ void MainWindow::readConfig() } // We know that the oldSettingsKey() will return 3.1 if ( keybase == DesignerApplication::oldSettingsKey() ) { - if (keybase.tqcontains("3.1")) + if (keybase.contains("3.1")) recentlyFiles = config.readListEntry( keybase + "RecentlyOpenedFiles", ',' ); else recentlyFiles = config.readListEntry(keybase + "RecentlyOpenedFiles"); if ( recentlyFiles.count() == 1 && recentlyFiles[0].isNull() ) recentlyFiles.clear(); - if (keybase.tqcontains("3.1")) + if (keybase.contains("3.1")) recentlyProjects = config.readListEntry( keybase + "RecentlyOpenedProjects", ',' ); else recentlyProjects = config.readListEntry( keybase + "RecentlyOpenedProjects"); @@ -2579,7 +2579,7 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) TQString fullSignal; for ( int i = 0; i < (int)sigs.count(); ++i ) { TQString sig = sigs.at( i ); - if ( sig.left( sig.tqfind( '(' ) ) == defSignal ) { + if ( sig.left( sig.find( '(' ) ) == defSignal ) { fullSignal = sig; break; } @@ -2587,14 +2587,14 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) if ( !fullSignal.isEmpty() ) { TQString signl = fullSignal; - fullSignal = fullSignal.mid( fullSignal.tqfind( '(' ) + 1 ); + fullSignal = fullSignal.mid( fullSignal.find( '(' ) + 1 ); fullSignal.remove( (int)fullSignal.length() - 1, 1 ); fullSignal = iface->createArguments( fullSignal.simplifyWhiteSpace() ); s += "(" + fullSignal + ")"; if ( !MetaDataBase::hasFunction( f, s.latin1() ) ) MetaDataBase::addFunction( f, s.latin1(), "", "public", "slot", f->project()->language(), "void" ); - s = s.left( s.tqfind( '(' ) ).latin1(); + s = s.left( s.find( '(' ) ).latin1(); if ( !MetaDataBase::hasConnection( f, w, defSignal.latin1(), f->mainContainer(), s.latin1() ) ) { MetaDataBase::Connection conn; conn.sender = TQT_TQOBJECT(w); @@ -2622,8 +2622,8 @@ bool MainWindow::openEditor( TQWidget *w, FormWindow *f ) return TRUE; } - const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "text", TRUE ), TRUE ); - const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( "title", TRUE ), TRUE ); + const TQMetaProperty* text = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "text", TRUE ), TRUE ); + const TQMetaProperty* title = w->tqmetaObject()->property( w->tqmetaObject()->findProperty( "title", TRUE ), TRUE ); if ( text && text->designable(w) ) { bool ok = FALSE; bool oldDoWrap = FALSE; @@ -2809,7 +2809,7 @@ void MainWindow::projectSelected( TQAction *a ) a->setOn( TRUE ); if ( currentProject ) currentProject->setActive( FALSE ); - Project *p = *projects.tqfind( a ); + Project *p = *projects.find( a ); p->setActive( TRUE ); if ( currentProject == p ) return; @@ -2886,9 +2886,9 @@ void MainWindow::showDialogHelp() else if ( ::tqqt_cast<ProjectSettingsBase*>(w) ) link += "dialog-project-settings"; else if ( ::tqqt_cast<FindDialog*>(w) ) - link += "dialog-tqfind-text"; + link += "dialog-find-text"; else if ( ::tqqt_cast<ReplaceDialog*>(w) ) - link += "dialog-tqreplace-text"; + link += "dialog-replace-text"; else if ( ::tqqt_cast<GotoLineDialog*>(w) ) link += "dialog-go-to-line"; // else if ( ::tqqt_cast<ConnectionEditorBase*>(w) ) @@ -3037,7 +3037,7 @@ TQStringList MainWindow::projectFileNames() const return res; } -Project *MainWindow::tqfindProject( const TQString &projectName ) const +Project *MainWindow::findProject( const TQString &projectName ) const { for ( TQMap<TQAction*, Project* >::ConstIterator it = projects.begin(); it != projects.end(); ++it ) { if ( (*it)->projectName() == projectName ) @@ -3104,7 +3104,7 @@ void MainWindow::addRecentlyOpened( const TQString &fn, TQStringList &lst ) TQFileInfo fi( fn ); fi.convertToAbs(); TQString f = fi.filePath(); - if ( lst.tqfind( f ) != lst.end() ) + if ( lst.find( f ) != lst.end() ) lst.remove( f ); if ( lst.count() >= 10 ) lst.pop_back(); @@ -3215,7 +3215,7 @@ void MainWindow::setModified( bool b, TQWidget *window ) void MainWindow::editorClosed( SourceEditor *e ) { - sourceEditors.take( sourceEditors.tqfindRef( e ) ); + sourceEditors.take( sourceEditors.findRef( e ) ); } void MainWindow::functionsChanged() @@ -3427,7 +3427,7 @@ void MainWindow::showSourceLine( TQObject *o, int line, LineMode lm ) mblockNewForms = TRUE; if ( !fw ) - openFormWindow( currentProject->makeAbsolute( *qwf_forms->tqfind( (TQWidget*)o ) ) ); + openFormWindow( currentProject->makeAbsolute( *qwf_forms->find( (TQWidget*)o ) ) ); else fw->formFile()->showEditor( FALSE ); tqApp->processEvents(); // give all views the chance to get the formwindow @@ -3449,7 +3449,7 @@ void MainWindow::showSourceLine( TQObject *o, int line, LineMode lm ) } -TQObject *MainWindow::tqfindRealObject( TQObject *o ) +TQObject *MainWindow::findRealObject( TQObject *o ) { TQWidgetList windows = qWorkspace()->windowList(); for ( TQWidget *w = windows.first(); w; w = windows.next() ) { @@ -3625,13 +3625,13 @@ TQString MainWindow::whatsThisFrom( const TQString &key ) } } - int i = menuHelpFile.tqfind( key ); + int i = menuHelpFile.find( key ); if ( i == -1 ) return TQString(); int start = i; int end = i; - start = menuHelpFile.tqfindRev( "<li>", i ) + 4; - end = menuHelpFile.tqfind( '\n', i ) - 1; + start = menuHelpFile.findRev( "<li>", i ) + 4; + end = menuHelpFile.find( '\n', i ) - 1; return menuHelpFile.mid( start, end - start + 1 ); } |