diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-07-02 21:37:22 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-07-06 11:24:55 +0900 |
commit | 7552c6d73043b1040139033f6864db48ae5446cf (patch) | |
tree | f90d24d072dd3ee6a3f909bf7778abc7669f03ef /doc/html/simple-application-example.html | |
parent | c113da2069b66130f67a0f27c699e1cec83588a5 (diff) | |
download | tqt3-7552c6d73043b1040139033f6864db48ae5446cf.tar.gz tqt3-7552c6d73043b1040139033f6864db48ae5446cf.zip |
Rename main window nt* related files to equivalent tq*. The file
"ntqsession.h" was totally unnecessary and has been removed.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'doc/html/simple-application-example.html')
-rw-r--r-- | doc/html/simple-application-example.html | 92 |
1 files changed, 46 insertions, 46 deletions
diff --git a/doc/html/simple-application-example.html b/doc/html/simple-application-example.html index f550bc2c8..70194e767 100644 --- a/doc/html/simple-application-example.html +++ b/doc/html/simple-application-example.html @@ -53,11 +53,11 @@ this example. #ifndef APPLICATION_H #define APPLICATION_H -#include <<a href="qmainwindow-h.html">ntqmainwindow.h</a>> +#include <<a href="tqmainwindow-h.html">tqmainwindow.h</a>> class TQTextEdit; -class ApplicationWindow: public <a href="ntqmainwindow.html">TQMainWindow</a> +class ApplicationWindow: public <a href="tqmainwindow.html">TQMainWindow</a> { <a href="metaobjects.html#TQ_OBJECT">TQ_OBJECT</a> @@ -105,14 +105,14 @@ private: #include <<a href="tqimage-h.html">tqimage.h</a>> #include <<a href="qpixmap-h.html">ntqpixmap.h</a>> -#include <<a href="qtoolbar-h.html">ntqtoolbar.h</a>> -#include <<a href="qtoolbutton-h.html">ntqtoolbutton.h</a>> -#include <<a href="qpopupmenu-h.html">ntqpopupmenu.h</a>> -#include <<a href="qmenubar-h.html">ntqmenubar.h</a>> +#include <<a href="tqtoolbar-h.html">tqtoolbar.h</a>> +#include <<a href="tqtoolbutton-h.html">tqtoolbutton.h</a>> +#include <<a href="tqpopupmenu-h.html">tqpopupmenu.h</a>> +#include <<a href="tqmenubar-h.html">tqmenubar.h</a>> #include <<a href="tqtextedit-h.html">tqtextedit.h</a>> #include <<a href="qfile-h.html">ntqfile.h</a>> #include <<a href="qfiledialog-h.html">ntqfiledialog.h</a>> -#include <<a href="qstatusbar-h.html">ntqstatusbar.h</a>> +#include <<a href="tqstatusbar-h.html">tqstatusbar.h</a>> #include <<a href="qmessagebox-h.html">ntqmessagebox.h</a>> #include <<a href="qprinter-h.html">ntqprinter.h</a>> #include <<a href="qapplication-h.html">ntqapplication.h</a>> @@ -128,27 +128,27 @@ private: #include "fileprint.xpm" <a name="f459"></a>ApplicationWindow::ApplicationWindow() - : <a href="ntqmainwindow.html">TQMainWindow</a>( 0, "example application main window", WDestructiveClose | WGroupLeader ) + : <a href="tqmainwindow.html">TQMainWindow</a>( 0, "example application main window", WDestructiveClose | WGroupLeader ) { printer = new <a href="ntqprinter.html">TQPrinter</a>( TQPrinter::HighResolution ); <a href="ntqpixmap.html">TQPixmap</a> openIcon, saveIcon, printIcon; - <a href="ntqtoolbar.html">TQToolBar</a> * fileTools = new <a href="ntqtoolbar.html">TQToolBar</a>( this, "file operations" ); -<a name="x1590"></a> fileTools-><a href="ntqtoolbar.html#setLabel">setLabel</a>( "File Operations" ); + <a href="tqtoolbar.html">TQToolBar</a> * fileTools = new <a href="tqtoolbar.html">TQToolBar</a>( this, "file operations" ); +<a name="x1590"></a> fileTools-><a href="tqtoolbar.html#setLabel">setLabel</a>( "File Operations" ); openIcon = TQPixmap( fileopen ); TQToolButton * fileOpen - = new <a href="ntqtoolbutton.html">TQToolButton</a>( openIcon, "Open File", <a href="tqstring.html#TQString-null">TQString::null</a>, + = new <a href="tqtoolbutton.html">TQToolButton</a>( openIcon, "Open File", <a href="tqstring.html#TQString-null">TQString::null</a>, this, TQ_SLOT(choose()), fileTools, "open file" ); saveIcon = TQPixmap( filesave ); TQToolButton * fileSave - = new <a href="ntqtoolbutton.html">TQToolButton</a>( saveIcon, "Save File", TQString::null, + = new <a href="tqtoolbutton.html">TQToolButton</a>( saveIcon, "Save File", TQString::null, this, TQ_SLOT(save()), fileTools, "save file" ); printIcon = TQPixmap( fileprint ); TQToolButton * filePrint - = new <a href="ntqtoolbutton.html">TQToolButton</a>( printIcon, "Print File", TQString::null, + = new <a href="tqtoolbutton.html">TQToolButton</a>( printIcon, "Print File", TQString::null, this, TQ_SLOT(print()), fileTools, "print file" ); @@ -178,50 +178,50 @@ private: TQWhatsThis::<a href="ntqwhatsthis.html#add">add</a>( filePrint, filePrintText ); - <a href="ntqpopupmenu.html">TQPopupMenu</a> * file = new <a href="ntqpopupmenu.html">TQPopupMenu</a>( this ); - <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&File", file ); + <a href="tqpopupmenu.html">TQPopupMenu</a> * file = new <a href="tqpopupmenu.html">TQPopupMenu</a>( this ); + <a href="tqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&File", file ); - file-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&New", this, TQ_SLOT(newDoc()), CTRL+Key_N ); + file-><a href="tqmenudata.html#insertItem">insertItem</a>( "&New", this, TQ_SLOT(newDoc()), CTRL+Key_N ); int id; - id = file-><a href="ntqmenudata.html#insertItem">insertItem</a>( openIcon, "&Open...", + id = file-><a href="tqmenudata.html#insertItem">insertItem</a>( openIcon, "&Open...", this, TQ_SLOT(choose()), CTRL+Key_O ); -<a name="x1554"></a> file-><a href="ntqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileOpenText ); +<a name="x1554"></a> file-><a href="tqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileOpenText ); - id = file-><a href="ntqmenudata.html#insertItem">insertItem</a>( saveIcon, "&Save", + id = file-><a href="tqmenudata.html#insertItem">insertItem</a>( saveIcon, "&Save", this, TQ_SLOT(save()), CTRL+Key_S ); - file-><a href="ntqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileSaveText ); + file-><a href="tqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileSaveText ); - id = file-><a href="ntqmenudata.html#insertItem">insertItem</a>( "Save &As...", this, TQ_SLOT(saveAs()) ); - file-><a href="ntqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileSaveText ); + id = file-><a href="tqmenudata.html#insertItem">insertItem</a>( "Save &As...", this, TQ_SLOT(saveAs()) ); + file-><a href="tqmenudata.html#setWhatsThis">setWhatsThis</a>( id, fileSaveText ); - file-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + file-><a href="tqmenudata.html#insertSeparator">insertSeparator</a>(); - id = file-><a href="ntqmenudata.html#insertItem">insertItem</a>( printIcon, "&Print...", + id = file-><a href="tqmenudata.html#insertItem">insertItem</a>( printIcon, "&Print...", this, TQ_SLOT(print()), CTRL+Key_P ); - file-><a href="ntqmenudata.html#setWhatsThis">setWhatsThis</a>( id, filePrintText ); + file-><a href="tqmenudata.html#setWhatsThis">setWhatsThis</a>( id, filePrintText ); - file-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + file-><a href="tqmenudata.html#insertSeparator">insertSeparator</a>(); - file-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&Close", this, TQ_SLOT(<a href="tqwidget.html#close">close</a>()), CTRL+Key_W ); + file-><a href="tqmenudata.html#insertItem">insertItem</a>( "&Close", this, TQ_SLOT(<a href="tqwidget.html#close">close</a>()), CTRL+Key_W ); -<a name="x1544"></a> file-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&Quit", tqApp, TQ_SLOT( <a href="ntqapplication.html#closeAllWindows">closeAllWindows</a>() ), CTRL+Key_Q ); +<a name="x1544"></a> file-><a href="tqmenudata.html#insertItem">insertItem</a>( "&Quit", tqApp, TQ_SLOT( <a href="ntqapplication.html#closeAllWindows">closeAllWindows</a>() ), CTRL+Key_Q ); - <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertSeparator(); + <a href="tqmainwindow.html#menuBar">menuBar</a>()->insertSeparator(); - <a href="ntqpopupmenu.html">TQPopupMenu</a> * help = new <a href="ntqpopupmenu.html">TQPopupMenu</a>( this ); - <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Help", help ); + <a href="tqpopupmenu.html">TQPopupMenu</a> * help = new <a href="tqpopupmenu.html">TQPopupMenu</a>( this ); + <a href="tqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Help", help ); - help-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&About", this, TQ_SLOT(about()), Key_F1 ); - help-><a href="ntqmenudata.html#insertItem">insertItem</a>( "About &TQt", this, TQ_SLOT(aboutTQt()) ); - help-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); - help-><a href="ntqmenudata.html#insertItem">insertItem</a>( "What's &This", this, TQ_SLOT(<a href="ntqmainwindow.html#whatsThis">whatsThis</a>()), SHIFT+Key_F1 ); + help-><a href="tqmenudata.html#insertItem">insertItem</a>( "&About", this, TQ_SLOT(about()), Key_F1 ); + help-><a href="tqmenudata.html#insertItem">insertItem</a>( "About &TQt", this, TQ_SLOT(aboutTQt()) ); + help-><a href="tqmenudata.html#insertSeparator">insertSeparator</a>(); + help-><a href="tqmenudata.html#insertItem">insertItem</a>( "What's &This", this, TQ_SLOT(<a href="tqmainwindow.html#whatsThis">whatsThis</a>()), SHIFT+Key_F1 ); e = new <a href="tqtextedit.html">TQTextEdit</a>( this, "editor" ); e-><a href="tqwidget.html#setFocus">setFocus</a>(); - <a href="ntqmainwindow.html#setCentralWidget">setCentralWidget</a>( e ); - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Ready", 2000 ); + <a href="tqmainwindow.html#setCentralWidget">setCentralWidget</a>( e ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Ready", 2000 ); <a href="tqwidget.html#resize">resize</a>( 450, 600 ); } @@ -248,7 +248,7 @@ void <a name="f461"></a>ApplicationWindow::choose() if ( !fn.<a href="tqstring.html#isEmpty">isEmpty</a>() ) load( fn ); else - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Loading aborted", 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Loading aborted", 2000 ); } @@ -262,7 +262,7 @@ void <a name="f462"></a>ApplicationWindow::load( const <a href="tqstring.html">T <a name="x1589"></a><a name="x1586"></a> e-><a href="tqtextedit.html#setText">setText</a>( ts.<a href="tqtextstream.html#read">read</a>() ); <a name="x1585"></a> e-><a href="tqtextedit.html#setModified">setModified</a>( FALSE ); <a href="tqwidget.html#setCaption">setCaption</a>( fileName ); - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Loaded document " + fileName, 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Loaded document " + fileName, 2000 ); } @@ -276,7 +276,7 @@ void <a name="f463"></a>ApplicationWindow::save() <a name="x1588"></a> <a href="tqstring.html">TQString</a> text = e-><a href="tqtextedit.html#text">text</a>(); <a href="ntqfile.html">TQFile</a> f( filename ); if ( !f.<a href="ntqfile.html#open">open</a>( <a href="ntqfile.html#open">IO_WriteOnly</a> ) ) { - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( TQString("Could not write to %1").arg(filename), + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( TQString("Could not write to %1").arg(filename), 2000 ); return; } @@ -289,7 +289,7 @@ void <a name="f463"></a>ApplicationWindow::save() <a href="tqwidget.html#setCaption">setCaption</a>( filename ); - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( TQString( "File %1 saved" ).arg( filename ), 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( TQString( "File %1 saved" ).arg( filename ), 2000 ); } @@ -301,7 +301,7 @@ void <a name="f464"></a>ApplicationWindow::saveAs() filename = fn; save(); } else { - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Saving aborted", 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Saving aborted", 2000 ); } } @@ -310,10 +310,10 @@ void <a name="f465"></a>ApplicationWindow::print() { <a name="x1568"></a> printer-><a href="ntqprinter.html#setFullPage">setFullPage</a>( TRUE ); <a name="x1569"></a> if ( printer-><a href="ntqprinter.html#setup">setup</a>(this) ) { // printer dialog - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Printing..." ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Printing..." ); <a href="ntqpainter.html">TQPainter</a> p; if( !p.<a href="ntqpainter.html#begin">begin</a>( printer ) ) { // paint on printer - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Printing aborted", 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Printing aborted", 2000 ); return; } @@ -341,9 +341,9 @@ void <a name="f465"></a>ApplicationWindow::print() page++; } while (TRUE); - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Printing completed", 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Printing completed", 2000 ); } else { - <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Printing aborted", 2000 ); + <a href="tqmainwindow.html#statusBar">statusBar</a>()->message( "Printing aborted", 2000 ); } } |