OTB  6.7.0
Orfeo Toolbox
mvdQuicklookViewManipulator.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2005-2019 Centre National d'Etudes Spatiales (CNES)
3  *
4  * This file is part of Orfeo Toolbox
5  *
6  * https://www.orfeo-toolbox.org/
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 
22 #ifndef mvdQuicklookViewManipulator_h
23 #define mvdQuicklookViewManipulator_h
24 
25 //
26 // Configuration include.
28 #include "ConfigureMonteverdi.h"
29 
30 
31 /*****************************************************************************/
32 /* INCLUDE SECTION */
33 
34 //
35 // Qt includes (sorted by alphabetic order)
37 #include <QtWidgets>
38 
39 //
40 // System includes (sorted by alphabetic order)
41 
42 //
43 // ITK includes (sorted by alphabetic order)
44 
45 //
46 // OTB includes (sorted by alphabetic order)
47 #include "OTBMonteverdiGUIExport.h"
48 //
49 // Monteverdi includes (sorted by alphabetic order)
51 
52 
53 /*****************************************************************************/
54 /* PRE-DECLARATION SECTION */
55 
56 //
57 // External classes pre-declaration.
58 namespace
59 {
60 }
61 
62 namespace mvd
63 {
64 //
65 // Internal classes pre-declaration.
66 
67 
68 /*****************************************************************************/
69 /* CLASS DEFINITION SECTION */
70 
78 class OTBMonteverdiGUI_EXPORT QuicklookViewManipulator :
80 {
81 
82  /*-[ QOBJECT SECTION ]-----------------------------------------------------*/
83 
84  Q_OBJECT;
85 
86  /*-[ PUBLIC SECTION ]------------------------------------------------------*/
87 
88 //
89 // Public methods.
90 public:
91 
93 #if USE_VIEW_SETTINGS_SIDE_EFFECT
95  QObject* p =NULL );
96 #else // USE_VIEW_SETTINGS_SIDE_EFFECT
97  QuicklookViewManipulator( QObject* p =NULL );
98 #endif // USE_VIEW_SETTINGS_SIDE_EFFECT
99 
101  ~QuicklookViewManipulator() override;
102 
103  //
104  // ImageViewManipulator overloads.
105 
106  ZoomType GetFixedZoomType() const override;
107 
108 
109  void
110  SetupRenderingContext(
111  AbstractImageViewRenderer::RenderingContext * const ) const override;
112 
113 
114  void MousePressEvent( QMouseEvent* event ) override;
115 
116  void MouseMoveEvent( QMouseEvent* event ) override;
117 
118  // virtual void MousePressEvent( QMouseEvent* event );
119 
120  // virtual void MouseReleaseEvent( QMouseEvent* event );
121 
122  void MouseDoubleClickEvent( QMouseEvent * ) override {};
123 
124  void WheelEvent( QWheelEvent* event) override;
125 
126  void ResizeEvent( QResizeEvent * event ) override;
127 
128  void KeyPressEvent( QKeyEvent* event ) override;
129 
130  void KeyReleaseEvent( QKeyEvent* event ) override;
131 
132  /*-[ PUBLIC SLOTS SECTION ]-----------------------------------------------**/
133 
134 //
135 // Public SLOTS.
136 public slots:
137 
138  /*-[ SIGNALS SECTION ]-----------------------------------------------------*/
139 
140 //
141 // Signals.
142 signals:
143 
144  /*-[ PROTECTED SECTION ]---------------------------------------------------*/
145 
146 //
147 // Protected methods.
148 protected:
149 
150 //
151 // Protected attributes.
152 protected:
153 
154  /*-[ PRIVATE SECTION ]-----------------------------------------------------*/
155 
156 //
157 // Private types.
158 private:
159 
160 //
161 // Private methods.
162 private:
163 
164 //
165 // Private attributes.
166 private:
170 
174 
178 
179  /*-[ PRIVATE SLOTS SECTION ]-----------------------------------------------*/
180 
181 //
182 // Slots.
183 private slots:
186  void OnRoiChanged( const PointType& origin,
187  const SizeType& size,
188  const SpacingType& spacing,
189  const PointType& center );
190 };
191 
192 } // end namespace 'mvd'
193 
194 /*****************************************************************************/
195 /* INLINE SECTION */
196 
197 namespace mvd
198 {
199 } // end namespace 'mvd'
200 
201 #endif // mvdQuicklookViewManipulator_h
void MouseDoubleClickEvent(QMouseEvent *) override
ZoomType
Definition: mvdGui.h:148
VectorImageType::SpacingType SpacingType
Definition: mvdTypes.h:181
VectorImageType::PointType PointType
Definition: mvdTypes.h:189