Mercurial > hg > svgui
annotate widgets/LayerTree.h @ 54:8dae7f6732c1
* improve label drawing logic in colour plot layer
author | Chris Cannam |
---|---|
date | Wed, 15 Mar 2006 18:21:17 +0000 |
parents | 78515b1e29eb |
children | fedaf3ffe80a |
rev | line source |
---|---|
Chris@43 | 1 |
Chris@43 | 2 /* -*- c-basic-offset: 4 -*- vi:set ts=8 sts=4 sw=4: */ |
Chris@43 | 3 |
Chris@43 | 4 /* |
Chris@43 | 5 A waveform viewer and audio annotation editor. |
Chris@43 | 6 Chris Cannam, Queen Mary University of London, 2005-2006 |
Chris@43 | 7 |
Chris@43 | 8 This is experimental software. Not for distribution. |
Chris@43 | 9 */ |
Chris@43 | 10 |
Chris@43 | 11 #ifndef _LAYER_TREE_H_ |
Chris@43 | 12 #define _LAYER_TREE_H_ |
Chris@43 | 13 |
Chris@43 | 14 #include <QAbstractItemModel> |
Chris@43 | 15 |
Chris@43 | 16 class PaneStack; |
Chris@43 | 17 |
Chris@43 | 18 class LayerTreeModel : public QAbstractItemModel |
Chris@43 | 19 { |
Chris@43 | 20 Q_OBJECT |
Chris@43 | 21 |
Chris@43 | 22 public: |
Chris@43 | 23 LayerTreeModel(PaneStack *stack, QObject *parent = 0); |
Chris@43 | 24 virtual ~LayerTreeModel(); |
Chris@43 | 25 |
Chris@43 | 26 QVariant data(const QModelIndex &index, int role) const; |
Chris@43 | 27 |
Chris@43 | 28 // Qt::ItemFlags flags(const QModelIndex &index) const; |
Chris@43 | 29 |
Chris@43 | 30 // QVariant headerData(int section, Qt::Orientation orientation, |
Chris@43 | 31 // int role = Qt::DisplayRole) const; |
Chris@43 | 32 |
Chris@43 | 33 QModelIndex index(int row, int column, |
Chris@43 | 34 const QModelIndex &parent = QModelIndex()) const; |
Chris@43 | 35 |
Chris@43 | 36 QModelIndex parent(const QModelIndex &index) const; |
Chris@43 | 37 |
Chris@43 | 38 int rowCount(const QModelIndex &parent = QModelIndex()) const; |
Chris@43 | 39 int columnCount(const QModelIndex &parent = QModelIndex()) const; |
Chris@43 | 40 |
Chris@43 | 41 protected: |
Chris@43 | 42 PaneStack *m_stack; |
Chris@43 | 43 }; |
Chris@43 | 44 |
Chris@43 | 45 #endif |