pqSpreadSheetViewDecorator.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: pqSpreadSheetViewDecorator.h
5 
6  Copyright (c) 2005,2006 Sandia Corporation, Kitware Inc.
7  All rights reserved.
8 
9  ParaView is a free software; you can redistribute it and/or modify it
10  under the terms of the ParaView license version 1.2.
11 
12  See License_v1.2.txt for the full ParaView license.
13  A copy of this license can be obtained by contacting
14  Kitware Inc.
15  28 Corporate Drive
16  Clifton Park, NY 12065
17  USA
18 
19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20 ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
22 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR
23 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
24 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
25 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
26 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
27 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
28 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
29 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 
31 ========================================================================*/
32 #ifndef pqSpreadSheetViewDecorator_h
33 #define pqSpreadSheetViewDecorator_h
34 
36 #include <QObject>
37 #include <QScopedPointer> // for QScopedPointer
38 
39 class pqSpreadSheetView;
40 class pqOutputPort;
42 
50 {
51  Q_OBJECT
52  typedef QObject Superclass;
53  Q_PROPERTY(bool allowChangeOfSource READ allowChangeOfSource WRITE setAllowChangeOfSource);
54 
56 
60  Q_PROPERTY(
61  bool generateCellConnectivity READ generateCellConnectivity WRITE setGenerateCellConnectivity);
62  Q_PROPERTY(
63  bool showSelectedElementsOnly READ showSelectedElementsOnly WRITE setShowSelectedElementsOnly);
64  Q_PROPERTY(int fieldAssociation READ fieldAssociation WRITE setFieldAssociation);
66 
67 public:
69  ~pqSpreadSheetViewDecorator() override;
70 
72 
76  bool generateCellConnectivity() const;
77  void setGenerateCellConnectivity(bool);
78  bool showSelectedElementsOnly() const;
79  void setShowSelectedElementsOnly(bool);
80  int fieldAssociation() const;
81  void setFieldAssociation(int);
83 
84  void setPrecision(int);
85  void setFixedRepresentation(bool);
86 
91  bool allowChangeOfSource() const;
92 
96  void setAllowChangeOfSource(bool val);
97 
101  bool eventFilter(QObject* object, QEvent* e) override;
102 
103 Q_SIGNALS:
104  void uiModified();
105 
106 protected Q_SLOTS:
107  void currentIndexChanged(pqOutputPort*);
108  void showing(pqDataRepresentation*);
109  void displayPrecisionChanged(int);
110  void toggleFixedRepresentation(bool);
111  void copyToClipboard();
112 
113 protected:
115 
116 private:
117  Q_DISABLE_COPY(pqSpreadSheetViewDecorator)
118 
119  class pqInternal;
120  QScopedPointer<pqInternal> Internal;
121 };
122 
123 #endif
pqDataRepresentation is the superclass for a display for a pqPipelineSource i.e.
pqOutputPort is a server manager model item for an output port of any pqPipelineSource item...
Definition: pqOutputPort.h:58
#define PQAPPLICATIONCOMPONENTS_EXPORT
View for spread-sheet view.
pqSpreadSheetViewDecorator adds decoration to a spread-sheet view.