• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

dox/GUISupport/Qt/Chart/vtkQtChartLegendManager.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkQtChartLegendManager.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00015 /*-------------------------------------------------------------------------
00016   Copyright 2008 Sandia Corporation.
00017   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00018   the U.S. Government retains certain rights in this software.
00019 -------------------------------------------------------------------------*/
00020 
00023 
00024 #ifndef _vtkQtChartLegendManager_h
00025 #define _vtkQtChartLegendManager_h
00026 
00027 #include "vtkQtChartExport.h"
00028 #include <QObject>
00029 
00030 class vtkQtChartArea;
00031 class vtkQtChartLayer;
00032 class vtkQtChartLegend;
00033 class vtkQtChartLegendManagerInternal;
00034 class vtkQtChartLegendModel;
00035 class vtkQtChartSeriesLayer;
00036 class vtkQtChartSeriesModel;
00037 
00038 
00043 class VTKQTCHART_EXPORT vtkQtChartLegendManager : public QObject
00044 {
00045   Q_OBJECT
00046 
00047 public:
00051   vtkQtChartLegendManager(QObject *parent=0);
00052   virtual ~vtkQtChartLegendManager();
00053 
00055 
00056 
00057 
00058 
00059   void setChartArea(vtkQtChartArea *area);
00060 
00064   void setChartLegend(vtkQtChartLegend *legend);
00066 
00067 public slots:
00072   void insertLayer(int index, vtkQtChartLayer *chart);
00073 
00078   void removeLayer(int index, vtkQtChartLayer *chart);
00079 
00084   void setLayerVisible(vtkQtChartLayer *chart, bool visible);
00085 
00086 private slots:
00091   void changeModel(vtkQtChartSeriesModel *previous,
00092       vtkQtChartSeriesModel *current);
00093 
00098   void updateSeriesVisibility(int series, bool visible);
00099 
00104   void updateModelEntries(int first, int last);
00105 
00107   void insertModelEntries();
00108 
00113   void insertModelEntries(int first, int last);
00114 
00116   void removeModelEntries();
00117 
00122   void removeModelEntries(int first, int last);
00123 
00124 private:
00130   int getLegendIndex(vtkQtChartSeriesLayer *chart);
00131 
00138   int getLegendIndex(vtkQtChartSeriesModel *model,
00139       vtkQtChartSeriesLayer **chart=0);
00140 
00149   void insertLegendEntries(vtkQtChartLegendModel *legend, int index,
00150       vtkQtChartSeriesLayer *chart, vtkQtChartSeriesModel *model,
00151       int first, int last);
00152 
00159   void removeLegendEntries(vtkQtChartLegendModel *legend, int index,
00160       int first, int last);
00161 
00162 private:
00163   vtkQtChartLegendManagerInternal *Internal; 
00164   vtkQtChartArea *Area;                      
00165   vtkQtChartLegend *Legend;                  
00166 
00167 private:
00168   vtkQtChartLegendManager(const vtkQtChartLegendManager &);
00169   vtkQtChartLegendManager &operator=(const vtkQtChartLegendManager &);
00170 };
00171 
00172 #endif

Generated by  doxygen 1.7.1