diff options
Diffstat (limited to 'doc/html/tutorial2-04.html')
-rw-r--r-- | doc/html/tutorial2-04.html | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/doc/html/tutorial2-04.html b/doc/html/tutorial2-04.html index 240225db5..5a0a850fc 100644 --- a/doc/html/tutorial2-04.html +++ b/doc/html/tutorial2-04.html @@ -35,29 +35,29 @@ body { background: #ffffff; color: black; } <p> (<tt>main.cpp</tt>.) <p> -<pre> #include <<a href="qapplication-h.html">ntqapplication.h</a>> +<pre> #include <<a href="tqapplication-h.html">tqapplication.h</a>> #include "chartform.h" int main( int argc, char *argv[] ) { - <a href="ntqapplication.html">TQApplication</a> app( argc, argv ); + <a href="tqapplication.html">TQApplication</a> app( argc, argv ); <a href="tqstring.html">TQString</a> filename; - <a name="x2557"></a> if ( app.<a href="ntqapplication.html#argc">argc</a>() > 1 ) { - <a name="x2558"></a> filename = app.<a href="ntqapplication.html#argv">argv</a>()[1]; + <a name="x2557"></a> if ( app.<a href="tqapplication.html#argc">argc</a>() > 1 ) { + <a name="x2558"></a> filename = app.<a href="tqapplication.html#argv">argv</a>()[1]; <a name="x2561"></a> if ( !filename.<a href="tqstring.html#endsWith">endsWith</a>( ".cht" ) ) filename = <a href="tqstring.html#TQString-null">TQString::null</a>; } ChartForm *cf = new ChartForm( filename ); - <a name="x2560"></a> app.<a href="ntqapplication.html#setMainWidget">setMainWidget</a>( cf ); + <a name="x2560"></a> app.<a href="tqapplication.html#setMainWidget">setMainWidget</a>( cf ); cf-><a href="tqwidget.html#show">show</a>(); - return app.<a href="ntqapplication.html#exec">exec</a>(); + return app.<a href="tqapplication.html#exec">exec</a>(); } </pre> <p> We have kept the main() function simple and small. We create a -<a href="ntqapplication.html">TQApplication</a> object and pass it the command line arguments. We are +<a href="tqapplication.html">TQApplication</a> object and pass it the command line arguments. We are allowing users to invoke the program with <tt>chart mychart.cht</tt>, so if they've added a filename we pass that through to the chart form constructor. Most of the action takes place within the chart form |