diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-26 23:32:43 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-26 23:32:43 -0600 |
commit | ea318d1431c89e647598c510c4245c6571aa5f46 (patch) | |
tree | 996d29b80c30d453dda86d1a23162d441628f169 /doc/html/canvas-chart-example.html | |
parent | aaf89d4b48f69c9293feb187db26362e550b5561 (diff) | |
download | tqt3-ea318d1431c89e647598c510c4245c6571aa5f46.tar.gz tqt3-ea318d1431c89e647598c510c4245c6571aa5f46.zip |
Update to latest tqt3 automated conversion
Diffstat (limited to 'doc/html/canvas-chart-example.html')
-rw-r--r-- | doc/html/canvas-chart-example.html | 450 |
1 files changed, 225 insertions, 225 deletions
diff --git a/doc/html/canvas-chart-example.html b/doc/html/canvas-chart-example.html index bcf4ae444..f17307533 100644 --- a/doc/html/canvas-chart-example.html +++ b/doc/html/canvas-chart-example.html @@ -35,7 +35,7 @@ body { background: #ffffff; color: black; } <p> <p> This is a complete example program with a main window, menus and -toolbars. The main widget is a <a href="qcanvas.html">TQCanvas</a>, and this example +toolbars. The main widget is a <a href="ntqcanvas.html">TQCanvas</a>, and this example demonstrates basic canvas usage. <p> <hr> @@ -67,10 +67,10 @@ SOURCES += element.cpp \ <p> <pre>#ifndef ELEMENT_H #define ELEMENT_H -#include <<a href="qcolor-h.html">qcolor.h</a>> -#include <<a href="qnamespace-h.html">qnamespace.h</a>> -#include <<a href="qstring-h.html">qstring.h</a>> -#include <<a href="qvaluevector-h.html">qvaluevector.h</a>> +#include <<a href="qcolor-h.html">ntqcolor.h</a>> +#include <<a href="qnamespace-h.html">ntqnamespace.h</a>> +#include <<a href="qstring-h.html">ntqstring.h</a>> +#include <<a href="qvaluevector-h.html">ntqvaluevector.h</a>> class Element; @@ -91,8 +91,8 @@ public: Element( double value = INVALID, TQColor valueColor = TQt::gray, int valuePattern = TQt::SolidPattern, - const <a href="qstring.html">TQString</a>& label = <a href="qstring.html#TQString-null">TQString::null</a>, - <a href="qcolor.html">TQColor</a> labelColor = TQt::black ) { + const <a href="ntqstring.html">TQString</a>& label = <a href="ntqstring.html#TQString-null">TQString::null</a>, + <a href="ntqcolor.html">TQColor</a> labelColor = TQt::black ) { init( value, valueColor, valuePattern, label, labelColor ); for ( int i = 0; i < MAX_PROPOINTS * 2; ++i ) m_propoints[i] = NO_PROPORTION; @@ -102,24 +102,24 @@ public: bool isValid() const { return m_value > EPSILON; } double value() const { return m_value; } - <a href="qcolor.html">TQColor</a> valueColor() const { return m_valueColor; } + <a href="ntqcolor.html">TQColor</a> valueColor() const { return m_valueColor; } int valuePattern() const { return m_valuePattern; } - <a href="qstring.html">TQString</a> label() const { return m_label; } - <a href="qcolor.html">TQColor</a> labelColor() const { return m_labelColor; } + <a href="ntqstring.html">TQString</a> label() const { return m_label; } + <a href="ntqcolor.html">TQColor</a> labelColor() const { return m_labelColor; } double proX( int index ) const; double proY( int index ) const; void set( double value = INVALID, TQColor valueColor = TQt::gray, int valuePattern = TQt::SolidPattern, - const <a href="qstring.html">TQString</a>& label = TQString::null, - <a href="qcolor.html">TQColor</a> labelColor = TQt::black ) { + const <a href="ntqstring.html">TQString</a>& label = TQString::null, + <a href="ntqcolor.html">TQColor</a> labelColor = TQt::black ) { init( value, valueColor, valuePattern, label, labelColor ); } void setValue( double value ) { m_value = value; } - void setValueColor( <a href="qcolor.html">TQColor</a> valueColor ) { m_valueColor = valueColor; } + void setValueColor( <a href="ntqcolor.html">TQColor</a> valueColor ) { m_valueColor = valueColor; } void setValuePattern( int valuePattern ); - void setLabel( const <a href="qstring.html">TQString</a>& label ) { m_label = label; } - void setLabelColor( <a href="qcolor.html">TQColor</a> labelColor ) { m_labelColor = labelColor; } + void setLabel( const <a href="ntqstring.html">TQString</a>& label ) { m_label = label; } + void setLabelColor( <a href="ntqcolor.html">TQColor</a> labelColor ) { m_labelColor = labelColor; } void setProX( int index, double value ); void setProY( int index, double value ); @@ -133,19 +133,19 @@ public: private: void init( double value, TQColor valueColor, int valuePattern, - const <a href="qstring.html">TQString</a>& label, TQColor labelColor ); + const <a href="ntqstring.html">TQString</a>& label, TQColor labelColor ); double m_value; - <a href="qcolor.html">TQColor</a> m_valueColor; + <a href="ntqcolor.html">TQColor</a> m_valueColor; int m_valuePattern; - <a href="qstring.html">TQString</a> m_label; - <a href="qcolor.html">TQColor</a> m_labelColor; + <a href="ntqstring.html">TQString</a> m_label; + <a href="ntqcolor.html">TQColor</a> m_labelColor; double m_propoints[2 * MAX_PROPOINTS]; }; -TQTextStream &operator<<( <a href="qtextstream.html">TQTextStream</a>&, const Element& ); -TQTextStream &operator>>( <a href="qtextstream.html">TQTextStream</a>&, Element& ); +TQTextStream &operator<<( <a href="ntqtextstream.html">TQTextStream</a>&, const Element& ); +TQTextStream &operator>>( <a href="ntqtextstream.html">TQTextStream</a>&, Element& ); #endif </pre> @@ -155,8 +155,8 @@ TQTextStream &operator>>( <a href="qtextstream.html">TQTextStream</a>& #include "element.h" -#include <<a href="qmainwindow-h.html">qmainwindow.h</a>> -#include <<a href="qstringlist-h.html">qstringlist.h</a>> +#include <<a href="qmainwindow-h.html">ntqmainwindow.h</a>> +#include <<a href="qstringlist-h.html">ntqstringlist.h</a>> class CanvasView; @@ -168,7 +168,7 @@ class TQPrinter; class TQString; -class ChartForm: public <a href="qmainwindow.html">TQMainWindow</a> +class ChartForm: public <a href="ntqmainwindow.html">TQMainWindow</a> { <a href="metaobjects.html#Q_OBJECT">Q_OBJECT</a> public: @@ -177,14 +177,14 @@ public: enum ChartType { PIE, VERTICAL_BAR, HORIZONTAL_BAR }; enum AddValuesType { NO, YES, AS_PERCENTAGE }; - ChartForm( const <a href="qstring.html">TQString</a>& filename ); + ChartForm( const <a href="ntqstring.html">TQString</a>& filename ); ~ChartForm(); int chartType() { return m_chartType; } void setChanged( bool changed = TRUE ) { m_changed = changed; } void drawElements(); - <a href="qpopupmenu.html">TQPopupMenu</a> *optionsMenu; // Why public? See canvasview.cpp + <a href="ntqpopupmenu.html">TQPopupMenu</a> *optionsMenu; // Why public? See canvasview.cpp protected: virtual void closeEvent( <a href="qcloseevent.html">TQCloseEvent</a> * ); @@ -199,7 +199,7 @@ private slots: void filePrint(); void fileQuit(); void optionsSetData(); - void updateChartType( <a href="qaction.html">TQAction</a> *action ); + void updateChartType( <a href="ntqaction.html">TQAction</a> *action ); void optionsSetFont(); void optionsSetOptions(); void helpHelp(); @@ -209,34 +209,34 @@ private slots: private: void init(); - void load( const <a href="qstring.html">TQString</a>& filename ); + void load( const <a href="ntqstring.html">TQString</a>& filename ); bool okToClear(); void drawPieChart( const double scales[], double total, int count ); void drawVerticalBarChart( const double scales[], double total, int count ); void drawHorizontalBarChart( const double scales[], double total, int count ); - <a href="qstring.html">TQString</a> valueLabel( const <a href="qstring.html">TQString</a>& label, double value, double total ); - void updateRecentFiles( const <a href="qstring.html">TQString</a>& filename ); + <a href="ntqstring.html">TQString</a> valueLabel( const <a href="ntqstring.html">TQString</a>& label, double value, double total ); + void updateRecentFiles( const <a href="ntqstring.html">TQString</a>& filename ); void updateRecentFilesMenu(); void setChartType( ChartType chartType ); - <a href="qpopupmenu.html">TQPopupMenu</a> *fileMenu; - <a href="qaction.html">TQAction</a> *optionsPieChartAction; - <a href="qaction.html">TQAction</a> *optionsHorizontalBarChartAction; - <a href="qaction.html">TQAction</a> *optionsVerticalBarChartAction; + <a href="ntqpopupmenu.html">TQPopupMenu</a> *fileMenu; + <a href="ntqaction.html">TQAction</a> *optionsPieChartAction; + <a href="ntqaction.html">TQAction</a> *optionsHorizontalBarChartAction; + <a href="ntqaction.html">TQAction</a> *optionsVerticalBarChartAction; - <a href="qstring.html">TQString</a> m_filename; - <a href="qstringlist.html">TQStringList</a> m_recentFiles; - <a href="qcanvas.html">TQCanvas</a> *m_canvas; + <a href="ntqstring.html">TQString</a> m_filename; + <a href="ntqstringlist.html">TQStringList</a> m_recentFiles; + <a href="ntqcanvas.html">TQCanvas</a> *m_canvas; CanvasView *m_canvasView; bool m_changed; ElementVector m_elements; - <a href="qprinter.html">TQPrinter</a> *m_printer; + <a href="ntqprinter.html">TQPrinter</a> *m_printer; ChartType m_chartType; AddValuesType m_addValues; int m_decimalPlaces; - <a href="qfont.html">TQFont</a> m_font; + <a href="ntqfont.html">TQFont</a> m_font; }; #endif @@ -249,24 +249,24 @@ private: #include "optionsform.h" #include "setdataform.h" -#include <<a href="qaction-h.html">qaction.h</a>> -#include <<a href="qapplication-h.html">qapplication.h</a>> -#include <<a href="qcombobox-h.html">qcombobox.h</a>> -#include <<a href="qfile-h.html">qfile.h</a>> -#include <<a href="qfiledialog-h.html">qfiledialog.h</a>> -#include <<a href="qfont-h.html">qfont.h</a>> -#include <<a href="qfontdialog-h.html">qfontdialog.h</a>> -#include <<a href="qmenubar-h.html">qmenubar.h</a>> -#include <<a href="qmessagebox-h.html">qmessagebox.h</a>> -#include <<a href="qpixmap-h.html">qpixmap.h</a>> -#include <<a href="qpopupmenu-h.html">qpopupmenu.h</a>> -#include <<a href="qprinter-h.html">qprinter.h</a>> -#include <<a href="qradiobutton-h.html">qradiobutton.h</a>> -#include <<a href="qsettings-h.html">qsettings.h</a>> -#include <<a href="qspinbox-h.html">qspinbox.h</a>> -#include <<a href="qstatusbar-h.html">qstatusbar.h</a>> -#include <<a href="qtoolbar-h.html">qtoolbar.h</a>> -#include <<a href="qtoolbutton-h.html">qtoolbutton.h</a>> +#include <<a href="qaction-h.html">ntqaction.h</a>> +#include <<a href="qapplication-h.html">ntqapplication.h</a>> +#include <<a href="qcombobox-h.html">ntqcombobox.h</a>> +#include <<a href="qfile-h.html">ntqfile.h</a>> +#include <<a href="qfiledialog-h.html">ntqfiledialog.h</a>> +#include <<a href="qfont-h.html">ntqfont.h</a>> +#include <<a href="qfontdialog-h.html">ntqfontdialog.h</a>> +#include <<a href="qmenubar-h.html">ntqmenubar.h</a>> +#include <<a href="qmessagebox-h.html">ntqmessagebox.h</a>> +#include <<a href="qpixmap-h.html">ntqpixmap.h</a>> +#include <<a href="qpopupmenu-h.html">ntqpopupmenu.h</a>> +#include <<a href="qprinter-h.html">ntqprinter.h</a>> +#include <<a href="qradiobutton-h.html">ntqradiobutton.h</a>> +#include <<a href="qsettings-h.html">ntqsettings.h</a>> +#include <<a href="qspinbox-h.html">ntqspinbox.h</a>> +#include <<a href="qstatusbar-h.html">ntqstatusbar.h</a>> +#include <<a href="qtoolbar-h.html">ntqtoolbar.h</a>> +#include <<a href="qtoolbutton-h.html">ntqtoolbutton.h</a>> #include "images/file_new.xpm" #include "images/file_open.xpm" @@ -280,177 +280,177 @@ private: #include "images/options_verticalbarchart.xpm" -const <a href="qstring.html">TQString</a> WINDOWS_REGISTRY = "/Trolltech/TQtExamples"; -const <a href="qstring.html">TQString</a> APP_KEY = "/Chart/"; +const <a href="ntqstring.html">TQString</a> WINDOWS_REGISTRY = "/Trolltech/TQtExamples"; +const <a href="ntqstring.html">TQString</a> APP_KEY = "/Chart/"; -<a name="f596"></a>ChartForm::ChartForm( const <a href="qstring.html">TQString</a>& filename ) - : <a href="qmainwindow.html">TQMainWindow</a>( 0, 0, WDestructiveClose ) +<a name="f596"></a>ChartForm::ChartForm( const <a href="ntqstring.html">TQString</a>& filename ) + : <a href="ntqmainwindow.html">TQMainWindow</a>( 0, 0, WDestructiveClose ) { - <a href="qwidget.html#setIcon">setIcon</a>( TQPixmap( options_piechart ) ); - - <a href="qaction.html">TQAction</a> *fileNewAction; - <a href="qaction.html">TQAction</a> *fileOpenAction; - <a href="qaction.html">TQAction</a> *fileSaveAction; - <a href="qaction.html">TQAction</a> *fileSaveAsAction; - <a href="qaction.html">TQAction</a> *fileSaveAsPixmapAction; - <a href="qaction.html">TQAction</a> *filePrintAction; - <a href="qaction.html">TQAction</a> *fileQuitAction; - <a href="qaction.html">TQAction</a> *optionsSetDataAction; - <a href="qaction.html">TQAction</a> *optionsSetFontAction; - <a href="qaction.html">TQAction</a> *optionsSetOptionsAction; - - fileNewAction = new <a href="qaction.html">TQAction</a>( + <a href="ntqwidget.html#setIcon">setIcon</a>( TQPixmap( options_piechart ) ); + + <a href="ntqaction.html">TQAction</a> *fileNewAction; + <a href="ntqaction.html">TQAction</a> *fileOpenAction; + <a href="ntqaction.html">TQAction</a> *fileSaveAction; + <a href="ntqaction.html">TQAction</a> *fileSaveAsAction; + <a href="ntqaction.html">TQAction</a> *fileSaveAsPixmapAction; + <a href="ntqaction.html">TQAction</a> *filePrintAction; + <a href="ntqaction.html">TQAction</a> *fileQuitAction; + <a href="ntqaction.html">TQAction</a> *optionsSetDataAction; + <a href="ntqaction.html">TQAction</a> *optionsSetFontAction; + <a href="ntqaction.html">TQAction</a> *optionsSetOptionsAction; + + fileNewAction = new <a href="ntqaction.html">TQAction</a>( "New Chart", TQPixmap( file_new ), "&New", CTRL+Key_N, this, "new" ); -<a name="x2869"></a> <a href="qobject.html#connect">connect</a>( fileNewAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), this, SLOT( fileNew() ) ); +<a name="x2869"></a> <a href="ntqobject.html#connect">connect</a>( fileNewAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileNew() ) ); - fileOpenAction = new <a href="qaction.html">TQAction</a>( + fileOpenAction = new <a href="ntqaction.html">TQAction</a>( "Open Chart", TQPixmap( file_open ), "&Open...", CTRL+Key_O, this, "open" ); - <a href="qobject.html#connect">connect</a>( fileOpenAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), this, SLOT( fileOpen() ) ); + <a href="ntqobject.html#connect">connect</a>( fileOpenAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileOpen() ) ); - fileSaveAction = new <a href="qaction.html">TQAction</a>( + fileSaveAction = new <a href="ntqaction.html">TQAction</a>( "Save Chart", TQPixmap( file_save ), "&Save", CTRL+Key_S, this, "save" ); - <a href="qobject.html#connect">connect</a>( fileSaveAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), this, SLOT( fileSave() ) ); + <a href="ntqobject.html#connect">connect</a>( fileSaveAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileSave() ) ); - fileSaveAsAction = new <a href="qaction.html">TQAction</a>( + fileSaveAsAction = new <a href="ntqaction.html">TQAction</a>( "Save Chart As", TQPixmap( file_save ), "Save &As...", 0, this, "save as" ); - <a href="qobject.html#connect">connect</a>( fileSaveAsAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( fileSaveAsAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileSaveAs() ) ); - fileSaveAsPixmapAction = new <a href="qaction.html">TQAction</a>( + fileSaveAsPixmapAction = new <a href="ntqaction.html">TQAction</a>( "Save Chart As Bitmap", TQPixmap( file_save ), "Save As &Bitmap...", CTRL+Key_B, this, "save as bitmap" ); - <a href="qobject.html#connect">connect</a>( fileSaveAsPixmapAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( fileSaveAsPixmapAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileSaveAsPixmap() ) ); - filePrintAction = new <a href="qaction.html">TQAction</a>( + filePrintAction = new <a href="ntqaction.html">TQAction</a>( "Print Chart", TQPixmap( file_print ), "&Print Chart...", CTRL+Key_P, this, "print chart" ); - <a href="qobject.html#connect">connect</a>( filePrintAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( filePrintAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( filePrint() ) ); - optionsSetDataAction = new <a href="qaction.html">TQAction</a>( + optionsSetDataAction = new <a href="ntqaction.html">TQAction</a>( "Set Data", TQPixmap( options_setdata ), "Set &Data...", CTRL+Key_D, this, "set data" ); - <a href="qobject.html#connect">connect</a>( optionsSetDataAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( optionsSetDataAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( optionsSetData() ) ); <a href="qactiongroup.html">TQActionGroup</a> *chartGroup = new <a href="qactiongroup.html">TQActionGroup</a>( this ); // Connected later <a name="x2874"></a> chartGroup-><a href="qactiongroup.html#setExclusive">setExclusive</a>( TRUE ); - optionsPieChartAction = new <a href="qaction.html">TQAction</a>( + optionsPieChartAction = new <a href="ntqaction.html">TQAction</a>( "Pie Chart", TQPixmap( options_piechart ), "&Pie Chart", CTRL+Key_I, chartGroup, "pie chart" ); -<a name="x2872"></a> optionsPieChartAction-><a href="qaction.html#setToggleAction">setToggleAction</a>( TRUE ); +<a name="x2872"></a> optionsPieChartAction-><a href="ntqaction.html#setToggleAction">setToggleAction</a>( TRUE ); - optionsHorizontalBarChartAction = new <a href="qaction.html">TQAction</a>( + optionsHorizontalBarChartAction = new <a href="ntqaction.html">TQAction</a>( "Horizontal Bar Chart", TQPixmap( options_horizontalbarchart ), "&Horizontal Bar Chart", CTRL+Key_H, chartGroup, "horizontal bar chart" ); - optionsHorizontalBarChartAction-><a href="qaction.html#setToggleAction">setToggleAction</a>( TRUE ); + optionsHorizontalBarChartAction-><a href="ntqaction.html#setToggleAction">setToggleAction</a>( TRUE ); - optionsVerticalBarChartAction = new <a href="qaction.html">TQAction</a>( + optionsVerticalBarChartAction = new <a href="ntqaction.html">TQAction</a>( "Vertical Bar Chart", TQPixmap( options_verticalbarchart ), "&Vertical Bar Chart", CTRL+Key_V, chartGroup, "Vertical bar chart" ); - optionsVerticalBarChartAction-><a href="qaction.html#setToggleAction">setToggleAction</a>( TRUE ); + optionsVerticalBarChartAction-><a href="ntqaction.html#setToggleAction">setToggleAction</a>( TRUE ); - optionsSetFontAction = new <a href="qaction.html">TQAction</a>( + optionsSetFontAction = new <a href="ntqaction.html">TQAction</a>( "Set Font", TQPixmap( options_setfont ), "Set &Font...", CTRL+Key_F, this, "set font" ); - <a href="qobject.html#connect">connect</a>( optionsSetFontAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( optionsSetFontAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( optionsSetFont() ) ); - optionsSetOptionsAction = new <a href="qaction.html">TQAction</a>( + optionsSetOptionsAction = new <a href="ntqaction.html">TQAction</a>( "Set Options", TQPixmap( options_setoptions ), "Set &Options...", 0, this, "set options" ); - <a href="qobject.html#connect">connect</a>( optionsSetOptionsAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), + <a href="ntqobject.html#connect">connect</a>( optionsSetOptionsAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( optionsSetOptions() ) ); - fileQuitAction = new <a href="qaction.html">TQAction</a>( "Quit", "&Quit", CTRL+Key_Q, this, "quit" ); - <a href="qobject.html#connect">connect</a>( fileQuitAction, SIGNAL( <a href="qaction.html#activated">activated</a>() ), this, SLOT( fileQuit() ) ); - - - <a href="qtoolbar.html">TQToolBar</a>* fileTools = new <a href="qtoolbar.html">TQToolBar</a>( this, "file operations" ); -<a name="x2895"></a> fileTools-><a href="qtoolbar.html#setLabel">setLabel</a>( "File Operations" ); -<a name="x2870"></a> fileNewAction-><a href="qaction.html#addTo">addTo</a>( fileTools ); - fileOpenAction-><a href="qaction.html#addTo">addTo</a>( fileTools ); - fileSaveAction-><a href="qaction.html#addTo">addTo</a>( fileTools ); -<a name="x2894"></a> fileTools-><a href="qtoolbar.html#addSeparator">addSeparator</a>(); - filePrintAction-><a href="qaction.html#addTo">addTo</a>( fileTools ); - - <a href="qtoolbar.html">TQToolBar</a> *optionsTools = new <a href="qtoolbar.html">TQToolBar</a>( this, "options operations" ); - optionsTools-><a href="qtoolbar.html#setLabel">setLabel</a>( "Options Operations" ); - optionsSetDataAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - optionsTools-><a href="qtoolbar.html#addSeparator">addSeparator</a>(); - optionsPieChartAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - optionsHorizontalBarChartAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - optionsVerticalBarChartAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - optionsTools-><a href="qtoolbar.html#addSeparator">addSeparator</a>(); - optionsSetFontAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - optionsTools-><a href="qtoolbar.html#addSeparator">addSeparator</a>(); - optionsSetOptionsAction-><a href="qaction.html#addTo">addTo</a>( optionsTools ); - - fileMenu = new <a href="qpopupmenu.html">TQPopupMenu</a>( this ); - <a href="qmainwindow.html#menuBar">menuBar</a>()->insertItem( "&File", fileMenu ); - fileNewAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileOpenAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileSaveAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileSaveAsAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - fileSaveAsPixmapAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - filePrintAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - fileMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - fileQuitAction-><a href="qaction.html#addTo">addTo</a>( fileMenu ); - - optionsMenu = new <a href="qpopupmenu.html">TQPopupMenu</a>( this ); - <a href="qmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Options", optionsMenu ); - optionsSetDataAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - optionsMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - optionsPieChartAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - optionsHorizontalBarChartAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - optionsVerticalBarChartAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - optionsMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - optionsSetFontAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - optionsMenu-><a href="qmenudata.html#insertSeparator">insertSeparator</a>(); - optionsSetOptionsAction-><a href="qaction.html#addTo">addTo</a>( optionsMenu ); - - <a href="qmainwindow.html#menuBar">menuBar</a>()->insertSeparator(); - - <a href="qpopupmenu.html">TQPopupMenu</a> *helpMenu = new <a href="qpopupmenu.html">TQPopupMenu</a>( this ); - <a href="qmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Help", helpMenu ); - helpMenu-><a href="qmenudata.html#insertItem">insertItem</a>( "&Help", this, SLOT(helpHelp()), Key_F1 ); - helpMenu-><a href="qmenudata.html#insertItem">insertItem</a>( "&About", this, SLOT(helpAbout()) ); - helpMenu-><a href="qmenudata.html#insertItem">insertItem</a>( "About &TQt", this, SLOT(helpAboutTQt()) ); + fileQuitAction = new <a href="ntqaction.html">TQAction</a>( "Quit", "&Quit", CTRL+Key_Q, this, "quit" ); + <a href="ntqobject.html#connect">connect</a>( fileQuitAction, SIGNAL( <a href="ntqaction.html#activated">activated</a>() ), this, SLOT( fileQuit() ) ); + + + <a href="ntqtoolbar.html">TQToolBar</a>* fileTools = new <a href="ntqtoolbar.html">TQToolBar</a>( this, "file operations" ); +<a name="x2895"></a> fileTools-><a href="ntqtoolbar.html#setLabel">setLabel</a>( "File Operations" ); +<a name="x2870"></a> fileNewAction-><a href="ntqaction.html#addTo">addTo</a>( fileTools ); + fileOpenAction-><a href="ntqaction.html#addTo">addTo</a>( fileTools ); + fileSaveAction-><a href="ntqaction.html#addTo">addTo</a>( fileTools ); +<a name="x2894"></a> fileTools-><a href="ntqtoolbar.html#addSeparator">addSeparator</a>(); + filePrintAction-><a href="ntqaction.html#addTo">addTo</a>( fileTools ); + + <a href="ntqtoolbar.html">TQToolBar</a> *optionsTools = new <a href="ntqtoolbar.html">TQToolBar</a>( this, "options operations" ); + optionsTools-><a href="ntqtoolbar.html#setLabel">setLabel</a>( "Options Operations" ); + optionsSetDataAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + optionsTools-><a href="ntqtoolbar.html#addSeparator">addSeparator</a>(); + optionsPieChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + optionsHorizontalBarChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + optionsVerticalBarChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + optionsTools-><a href="ntqtoolbar.html#addSeparator">addSeparator</a>(); + optionsSetFontAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + optionsTools-><a href="ntqtoolbar.html#addSeparator">addSeparator</a>(); + optionsSetOptionsAction-><a href="ntqaction.html#addTo">addTo</a>( optionsTools ); + + fileMenu = new <a href="ntqpopupmenu.html">TQPopupMenu</a>( this ); + <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&File", fileMenu ); + fileNewAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileOpenAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileSaveAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileSaveAsAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + fileSaveAsPixmapAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + filePrintAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + fileMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + fileQuitAction-><a href="ntqaction.html#addTo">addTo</a>( fileMenu ); + + optionsMenu = new <a href="ntqpopupmenu.html">TQPopupMenu</a>( this ); + <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Options", optionsMenu ); + optionsSetDataAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + optionsMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + optionsPieChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + optionsHorizontalBarChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + optionsVerticalBarChartAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + optionsMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + optionsSetFontAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + optionsMenu-><a href="ntqmenudata.html#insertSeparator">insertSeparator</a>(); + optionsSetOptionsAction-><a href="ntqaction.html#addTo">addTo</a>( optionsMenu ); + + <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertSeparator(); + + <a href="ntqpopupmenu.html">TQPopupMenu</a> *helpMenu = new <a href="ntqpopupmenu.html">TQPopupMenu</a>( this ); + <a href="ntqmainwindow.html#menuBar">menuBar</a>()->insertItem( "&Help", helpMenu ); + helpMenu-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&Help", this, SLOT(helpHelp()), Key_F1 ); + helpMenu-><a href="ntqmenudata.html#insertItem">insertItem</a>( "&About", this, SLOT(helpAbout()) ); + helpMenu-><a href="ntqmenudata.html#insertItem">insertItem</a>( "About &TQt", this, SLOT(helpAboutTQt()) ); m_printer = 0; m_elements.resize( MAX_ELEMENTS ); - <a href="qsettings.html">TQSettings</a> settings; -<a name="x2890"></a> settings.<a href="qsettings.html#insertSearchPath">insertSearchPath</a>( TQSettings::Windows, WINDOWS_REGISTRY ); - int windowWidth = settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowWidth", 460 ); - int windowHeight = settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowHeight", 530 ); - int windowX = settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowX", -1 ); - int windowY = settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowY", -1 ); + <a href="ntqsettings.html">TQSettings</a> settings; +<a name="x2890"></a> settings.<a href="ntqsettings.html#insertSearchPath">insertSearchPath</a>( TQSettings::Windows, WINDOWS_REGISTRY ); + int windowWidth = settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowWidth", 460 ); + int windowHeight = settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowHeight", 530 ); + int windowX = settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowX", -1 ); + int windowY = settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "WindowY", -1 ); setChartType( ChartType( - settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "ChartType", int(PIE) ) ) ); + settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "ChartType", int(PIE) ) ) ); m_addValues = AddValuesType( - settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "AddValues", int(NO) )); - m_decimalPlaces = settings.<a href="qsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "Decimals", 2 ); + settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "AddValues", int(NO) )); + m_decimalPlaces = settings.<a href="ntqsettings.html#readNumEntry">readNumEntry</a>( APP_KEY + "Decimals", 2 ); m_font = TQFont( "Helvetica", 18, TQFont::Bold ); m_font.fromString( - settings.<a href="qsettings.html#readEntry">readEntry</a>( APP_KEY + "Font", m_font.toString() ) ); + settings.<a href="ntqsettings.html#readEntry">readEntry</a>( APP_KEY + "Font", m_font.toString() ) ); for ( int i = 0; i < MAX_RECENTFILES; ++i ) { - <a href="qstring.html">TQString</a> filename = settings.<a href="qsettings.html#readEntry">readEntry</a>( APP_KEY + "File" + -<a name="x2893"></a> TQString::<a href="qstring.html#number">number</a>( i + 1 ) ); -<a name="x2892"></a> if ( !filename.<a href="qstring.html#isEmpty">isEmpty</a>() ) + <a href="ntqstring.html">TQString</a> filename = settings.<a href="ntqsettings.html#readEntry">readEntry</a>( APP_KEY + "File" + +<a name="x2893"></a> TQString::<a href="ntqstring.html#number">number</a>( i + 1 ) ); +<a name="x2892"></a> if ( !filename.<a href="ntqstring.html#isEmpty">isEmpty</a>() ) m_recentFiles.push_back( filename ); } if ( m_recentFiles.count() ) @@ -459,20 +459,20 @@ const <a href="qstring.html">TQString</a> APP_KEY = "/Chart/"; // Connect *after* we've set the chart type on so we don't call // drawElements() prematurely. -<a name="x2873"></a> <a href="qobject.html#connect">connect</a>( chartGroup, SIGNAL( <a href="qactiongroup.html#selected">selected</a>(TQAction*) ), +<a name="x2873"></a> <a href="ntqobject.html#connect">connect</a>( chartGroup, SIGNAL( <a href="qactiongroup.html#selected">selected</a>(TQAction*) ), this, SLOT( updateChartType(TQAction*) ) ); - <a href="qwidget.html#resize">resize</a>( windowWidth, windowHeight ); + <a href="ntqwidget.html#resize">resize</a>( windowWidth, windowHeight ); if ( windowX != -1 || windowY != -1 ) - <a href="qwidget.html#move">move</a>( windowX, windowY ); + <a href="ntqwidget.html#move">move</a>( windowX, windowY ); - m_canvas = new <a href="qcanvas.html">TQCanvas</a>( this ); -<a name="x2876"></a> m_canvas-><a href="qcanvas.html#resize">resize</a>( <a href="qwidget.html#width">width</a>(), height() ); + m_canvas = new <a href="ntqcanvas.html">TQCanvas</a>( this ); +<a name="x2876"></a> m_canvas-><a href="ntqcanvas.html#resize">resize</a>( <a href="ntqwidget.html#width">width</a>(), height() ); m_canvasView = new CanvasView( m_canvas, &m_elements, this ); - <a href="qmainwindow.html#setCentralWidget">setCentralWidget</a>( m_canvasView ); - m_canvasView-><a href="qwidget.html#show">show</a>(); + <a href="ntqmainwindow.html#setCentralWidget">setCentralWidget</a>( m_canvasView ); + m_canvasView-><a href="ntqwidget.html#show">show</a>(); - if ( !filename.<a href="qstring.html#isEmpty">isEmpty</a>() ) + if ( !filename.<a href="ntqstring.html#isEmpty">isEmpty</a>() ) load( filename ); else { init(); @@ -484,7 +484,7 @@ const <a href="qstring.html">TQString</a> APP_KEY = "/Chart/"; drawElements(); } - <a href="qmainwindow.html#statusBar">statusBar</a>()->message( "Ready", 2000 ); + <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Ready", 2000 ); } @@ -496,7 +496,7 @@ ChartForm::~ChartForm() void <a name="f597"></a>ChartForm::init() { - <a href="qwidget.html#setCaption">setCaption</a>( "Chart" ); + <a href="ntqwidget.html#setCaption">setCaption</a>( "Chart" ); m_filename = TQString::null; m_changed = FALSE; @@ -520,7 +520,7 @@ void <a name="f597"></a>ChartForm::init() } } -<a name="x2896"></a>void ChartForm::<a href="qwidget.html#closeEvent">closeEvent</a>( <a href="qcloseevent.html">TQCloseEvent</a> * ) +<a name="x2896"></a>void ChartForm::<a href="ntqwidget.html#closeEvent">closeEvent</a>( <a href="qcloseevent.html">TQCloseEvent</a> * ) { fileQuit(); } @@ -540,25 +540,25 @@ void <a name="f599"></a>ChartForm::fileOpen() if ( !okToClear() ) return; - <a href="qstring.html">TQString</a> filename = TQFileDialog::<a href="qfiledialog.html#getOpenFileName">getOpenFileName</a>( + <a href="ntqstring.html">TQString</a> filename = TQFileDialog::<a href="ntqfiledialog.html#getOpenFileName">getOpenFileName</a>( TQString::null, "Charts (*.cht)", this, "file open", "Chart -- File Open" ); - if ( !filename.<a href="qstring.html#isEmpty">isEmpty</a>() ) + if ( !filename.<a href="ntqstring.html#isEmpty">isEmpty</a>() ) load( filename ); else - <a href="qmainwindow.html#statusBar">statusBar</a>()->message( "File Open abandoned", 2000 ); + <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "File Open abandoned", 2000 ); } void <a name="f600"></a>ChartForm::fileSaveAs() { - <a href="qstring.html">TQString</a> filename = TQFileDialog::<a href="qfiledialog.html#getSaveFileName">getSaveFileName</a>( + <a href="ntqstring.html">TQString</a> filename = TQFileDialog::<a href="ntqfiledialog.html#getSaveFileName">getSaveFileName</a>( TQString::null, "Charts (*.cht)", this, "file save as", "Chart -- File Save As" ); - if ( !filename.<a href="qstring.html#isEmpty">isEmpty</a>() ) { + if ( !filename.<a href="ntqstring.html#isEmpty">isEmpty</a>() ) { int answer = 0; -<a name="x2878"></a> if ( TQFile::<a href="qfile.html#exists">exists</a>( filename ) ) -<a name="x2889"></a> answer = TQMessageBox::<a href="qmessagebox.html#warning">warning</a>( +<a name="x2878"></a> if ( TQFile::<a href="ntqfile.html#exists">exists</a>( filename ) ) +<a name="x2889"></a> answer = TQMessageBox::<a href="ntqmessagebox.html#warning">warning</a>( this, "Chart -- Overwrite File", TQString( "Overwrite\n\'%1\'?" ). arg( filename ), @@ -570,7 +570,7 @@ void <a name="f600"></a>ChartForm::fileSaveAs() return; } } - <a href="qmainwindow.html#statusBar">statusBar</a>()->message( "Saving abandoned", 2000 ); + <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Saving abandoned", 2000 ); } @@ -583,7 +583,7 @@ void <a name="f601"></a>ChartForm::fileOpenRecent( int index ) } -void <a name="f602"></a>ChartForm::updateRecentFiles( const <a href="qstring.html">TQString</a>& filename ) +void <a name="f602"></a>ChartForm::updateRecentFiles( const <a href="ntqstring.html">TQString</a>& filename ) { if ( m_recentFiles.find( filename ) != m_recentFiles.end() ) return; @@ -599,10 +599,10 @@ void <a name="f602"></a>ChartForm::updateRecentFiles( const <a href="qstring.htm void <a name="f603"></a>ChartForm::updateRecentFilesMenu() { for ( int i = 0; i < MAX_RECENTFILES; ++i ) { -<a name="x2882"></a> if ( fileMenu-><a href="qmenudata.html#findItem">findItem</a>( i ) ) -<a name="x2885"></a> fileMenu-><a href="qmenudata.html#removeItem">removeItem</a>( i ); +<a name="x2882"></a> if ( fileMenu-><a href="ntqmenudata.html#findItem">findItem</a>( i ) ) +<a name="x2885"></a> fileMenu-><a href="ntqmenudata.html#removeItem">removeItem</a>( i ); if ( i < int(m_recentFiles.count()) ) - fileMenu-><a href="qmenudata.html#insertItem">insertItem</a>( TQString( "&%1 %2" ). + fileMenu-><a href="ntqmenudata.html#insertItem">insertItem</a>( TQString( "&%1 %2" ). arg( i + 1 ).arg( m_recentFiles[i] ), this, SLOT( fileOpenRecent(int) ), 0, i ); @@ -614,7 +614,7 @@ void <a name="f604"></a>ChartForm::fileQuit() { if ( okToClear() ) { saveOptions(); -<a name="x2875"></a> qApp-><a href="qapplication.html#exit">exit</a>( 0 ); +<a name="x2875"></a> qApp-><a href="ntqapplication.html#exit">exit</a>( 0 ); } } @@ -622,14 +622,14 @@ void <a name="f604"></a>ChartForm::fileQuit() bool <a name="f605"></a>ChartForm::okToClear() { if ( m_changed ) { - <a href="qstring.html">TQString</a> msg; + <a href="ntqstring.html">TQString</a> msg; if ( m_filename.isEmpty() ) msg = "Unnamed chart "; else msg = TQString( "Chart '%1'\n" ).arg( m_filename ); msg += "has been changed."; - int x = TQMessageBox::<a href="qmessagebox.html#information">information</a>( this, "Chart -- Unsaved Changes", + int x = TQMessageBox::<a href="ntqmessagebox.html#information">information</a>( this, "Chart -- Unsaved Changes", msg, "&Save", "Cancel", "&Abandon", 0, 1 ); switch( x ) { @@ -650,18 +650,18 @@ bool <a name="f605"></a>ChartForm::okToClear() void <a name="f606"></a>ChartForm::saveOptions() { - <a href="qsettings.html">TQSettings</a> settings; - settings.<a href="qsettings.html#insertSearchPath">insertSearchPath</a>( TQSettings::Windows, WINDOWS_REGISTRY ); -<a name="x2891"></a> settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowWidth", width() ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowHeight", height() ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowX", x() ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowY", y() ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "ChartType", int(m_chartType) ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "AddValues", int(m_addValues) ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "Decimals", m_decimalPlaces ); - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "Font", m_font.toString() ); + <a href="ntqsettings.html">TQSettings</a> settings; + settings.<a href="ntqsettings.html#insertSearchPath">insertSearchPath</a>( TQSettings::Windows, WINDOWS_REGISTRY ); +<a name="x2891"></a> settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowWidth", width() ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowHeight", height() ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowX", x() ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "WindowY", y() ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "ChartType", int(m_chartType) ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "AddValues", int(m_addValues) ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "Decimals", m_decimalPlaces ); + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "Font", m_font.toString() ); for ( int i = 0; i < int(m_recentFiles.count()); ++i ) - settings.<a href="qsettings.html#writeEntry">writeEntry</a>( APP_KEY + "File" + TQString::number( i + 1 ), + settings.<a href="ntqsettings.html#writeEntry">writeEntry</a>( APP_KEY + "File" + TQString::number( i + 1 ), m_recentFiles[i] ); } @@ -669,7 +669,7 @@ void <a name="f606"></a>ChartForm::saveOptions() void <a name="f607"></a>ChartForm::optionsSetData() { SetDataForm *setDataForm = new SetDataForm( &m_elements, m_decimalPlaces, this ); -<a name="x2877"></a> if ( setDataForm-><a href="qdialog.html#exec">exec</a>() ) { +<a name="x2877"></a> if ( setDataForm-><a href="ntqdialog.html#exec">exec</a>() ) { m_changed = TRUE; drawElements(); } @@ -682,19 +682,19 @@ void <a name="f608"></a>ChartForm::setChartType( ChartType chartType ) m_chartType = chartType; switch ( m_chartType ) { case PIE: -<a name="x2871"></a> optionsPieChartAction-><a href="qaction.html#setOn">setOn</a>( TRUE ); +<a name="x2871"></a> optionsPieChartAction-><a href="ntqaction.html#setOn">setOn</a>( TRUE ); break; case VERTICAL_BAR: - optionsVerticalBarChartAction-><a href="qaction.html#setOn">setOn</a>( TRUE ); + optionsVerticalBarChartAction-><a href="ntqaction.html#setOn">setOn</a>( TRUE ); break; case HORIZONTAL_BAR: - optionsHorizontalBarChartAction-><a href="qaction.html#setOn">setOn</a>( TRUE ); + optionsHorizontalBarChartAction-><a href="ntqaction.html#setOn">setOn</a>( TRUE ); break; } } -void <a name="f609"></a>ChartForm::updateChartType( <a href="qaction.html">TQAction</a> *action ) +void <a name="f609"></a>ChartForm::updateChartType( <a href="ntqaction.html">TQAction</a> *action ) { if ( action == optionsPieChartAction ) { m_chartType = PIE; @@ -713,7 +713,7 @@ void <a name="f609"></a>ChartForm::updateChartType( <a href="qaction.html">TQAct void <a name="f610"></a>ChartForm::optionsSetFont() { bool ok; -<a name="x2881"></a> <a href="qfont.html">TQFont</a> font = TQFontDialog::<a href="qfontdialog.html#getFont">getFont</a>( &ok, m_font, this ); +<a name="x2881"></a> <a href="ntqfont.html">TQFont</a> font = TQFontDialog::<a href="ntqfontdialog.html#getFont">getFont</a>( &ok, m_font, this ); if ( ok ) { m_font = font; drawElements(); @@ -725,7 +725,7 @@ void <a name="f611"></a>ChartForm::optionsSetOptions() { OptionsForm *optionsForm = new OptionsForm( this ); optionsForm->chartTypeComboBox->setCurrentItem( m_chartType ); - optionsForm-><a href="qwidget.html#setFont">setFont</a>( m_font ); + optionsForm-><a href="ntqwidget.html#setFont">setFont</a>( m_font ); switch ( m_addValues ) { case NO: optionsForm->noRadioButton->setChecked( TRUE ); @@ -738,10 +738,10 @@ void <a name="f611"></a>ChartForm::optionsSetOptions() break; } optionsForm->decimalPlacesSpinBox->setValue( m_decimalPlaces ); - if ( optionsForm-><a href="qdialog.html#exec">exec</a>() ) { + if ( optionsForm-><a href="ntqdialog.html#exec">exec</a>() ) { setChartType( ChartType( optionsForm->chartTypeComboBox->currentItem()) ); -<a name="x2897"></a> m_font = optionsForm-><a href="qwidget.html#font">font</a>(); +<a name="x2897"></a> m_font = optionsForm-><a href="ntqwidget.html#font">font</a>(); if ( optionsForm->noRadioButton->isChecked() ) m_addValues = NO; else if ( optionsForm->yesRadioButton->isChecked() ) @@ -757,13 +757,13 @@ void <a name="f611"></a>ChartForm::optionsSetOptions() void <a name="f612"></a>ChartForm::helpHelp() { - <a href="qmainwindow.html#statusBar">statusBar</a>()->message( "Help is not implemented yet", 2000 ); + <a href="ntqmainwindow.html#statusBar">statusBar</a>()->message( "Help is not implemented yet", 2000 ); } void <a name="f613"></a>ChartForm::helpAbout() { -<a name="x2886"></a> TQMessageBox::<a href="qmessagebox.html#about">about</a>( this, "Chart -- About", +<a name="x2886"></a> TQMessageBox::<a href="ntqmessagebox.html#about">about</a>( this, "Chart -- About", "<center><h1><font color=blue>Chart<font></h1></center>" "<p>Chart your data with <i>chart</i>.</p>" ); @@ -772,33 +772,33 @@ void <a name="f613"></a>ChartForm::helpAbout() void <a name="f614"></a>ChartForm::helpAboutTQt() { -<a name="x2887"></a> TQMessageBox::<a href="qmessagebox.html#aboutTQt">aboutTQt</a>( this, "Chart -- About TQt" ); +<a name="x2887"></a> TQMessageBox::<a href="ntqmessagebox.html#aboutTQt">aboutTQt</a>( this, "Chart -- About TQt" ); } </pre> <p> <hr> <p> Main: -<p> <pre>#include <<a href="qapplication-h.html">qapplication.h</a>> +<p> <pre>#include <<a href="qapplication-h.html">ntqapplication.h</a>> #include "chartform.h" int main( int argc, char *argv[] ) { - <a href="qapplication.html">TQApplication</a> app( argc, argv ); + <a href="ntqapplication.html">TQApplication</a> app( argc, argv ); - <a href="qstring.html">TQString</a> filename; -<a name="x2900"></a> if ( app.<a href="qapplication.html#argc">argc</a>() > 1 ) { -<a name="x2901"></a> filename = app.<a href="qapplication.html#argv">argv</a>()[1]; -<a name="x2904"></a> if ( !filename.<a href="qstring.html#endsWith">endsWith</a>( ".cht" ) ) + <a href="ntqstring.html">TQString</a> filename; +<a name="x2900"></a> if ( app.<a href="ntqapplication.html#argc">argc</a>() > 1 ) { +<a name="x2901"></a> filename = app.<a href="ntqapplication.html#argv">argv</a>()[1]; +<a name="x2904"></a> if ( !filename.<a href="ntqstring.html#endsWith">endsWith</a>( ".cht" ) ) filename = TQString::null; } ChartForm *cf = new ChartForm( filename ); - app.<a href="qapplication.html#setMainWidget">setMainWidget</a>( cf ); - cf-><a href="qwidget.html#show">show</a>(); + app.<a href="ntqapplication.html#setMainWidget">setMainWidget</a>( cf ); + cf-><a href="ntqwidget.html#show">show</a>(); - return app.<a href="qapplication.html#exec">exec</a>(); + return app.<a href="ntqapplication.html#exec">exec</a>(); } </pre> |