00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef WTABLE_H
00032 #define WTABLE_H
00033
00034 #include <qwidget.h>
00035 #include <qwidgetplugin.h>
00036 #include <qobjectlist.h>
00037 #include <qscrollview.h>
00038 #include <qtable.h>
00039 #include <qlabel.h>
00040 #include <qevent.h>
00041 #include <qdatatable.h>
00042 #include "acfg.h"
00043 #include "aobject.h"
00044 #include "awidget.h"
00045
00063 class QT_WIDGET_PLUGIN_EXPORT wTable : public QTable
00064 {
00065 Q_OBJECT
00066
00067 public:
00068
00069 wTable(QWidget* parent, const char * name);
00070 virtual ~wTable();
00071 public slots:
00072 virtual void setDocument(int row, aObject *object);
00073 void setText(int row, int col, const QString& text);
00074 QString text(int col, int row);
00075 void setHeaderText(int col, const QString& text);
00076 QString textHeader(int col);
00077 virtual void sortColumn ( int col, bool ascending = TRUE, bool wholeRows = TRUE );
00078 virtual void setColumnWidth(int col, int width);
00079 virtual int columnWidth(int col);
00080 virtual void setNumCols ( int r );
00081 virtual int numCols () const ;
00082 virtual void hideColumn ( int col );
00083 virtual void showColumn ( int col );
00084
00085 virtual void adjustColumn ( int col );
00086 virtual void setColumnStretchable ( int col, bool stretch );
00087 bool isColumnStretchable ( int col ) const;
00088 virtual void swapColumns ( int col1, int col2, bool swapHeader = FALSE );
00089 virtual void swapCells ( int row1, int col1, int row2, int col2 );
00090 virtual void setCurrentCell ( int row, int col );
00091 virtual void setColumnReadOnly ( int col, bool ro );
00092 virtual void insertColumns ( int col, int count = 1 );
00093 virtual void removeColumn ( int col );
00094 virtual void editCell ( int row, int col, bool replace = FALSE );
00095 virtual void swapRows ( int row1, int row2, bool swapHeader = FALSE );
00096 virtual int currentRow() {return QTable::currentRow();};
00097 signals:
00098
00099
00100
00101
00102
00103 protected slots:
00104 virtual void columnClicked ( int col );
00105
00106 private slots:
00107
00108
00109
00110
00111 protected:
00112 virtual void activateNextCell () {} ;
00113
00114 };
00115
00116 #endif