casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SlicerMainWindow.qo.h
Go to the documentation of this file.
1 //# Copyright (C) 1994,1995,1996,1997,1998,1999,2000
2 //# Associated Universities, Inc. Washington DC, USA.
3 //#
4 //# This library is free software; you can redistribute it and/or modify it
5 //# under the terms of the GNU Library General Public License as published by
6 //# the Free Software Foundation; either version 2 of the License, or (at your
7 //# option) any later version.
8 //#
9 //# This library is distributed in the hope that it will be useful, but WITHOUT
10 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
12 //# License for more details.
13 //#
14 //# You should have received a copy of the GNU Library General Public License
15 //# along with this library; if not, write to the Free Software Foundation,
16 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
17 //#
18 //# Correspondence concerning AIPS++ should be addressed as follows:
19 //# Internet email: aips2-request@nrao.edu.
20 //# Postal address: AIPS++ Project Office
21 //# National Radio Astronomy Observatory
22 //# 520 Edgemont Road
23 //# Charlottesville, VA 22903-2475 USA
24 //#
25 
26 #ifndef SLICER_MAINWINDOW_QO_H
27 #define SLICER_MAINWINDOW_QO_H
28 
29 #include <QMainWindow>
30 #include <display/Slicer/SlicerMainWindow.ui.h>
32 
33 class QCursor;
34 
35 namespace casa {
36 
37  class SliceZoomer;
38  class SliceColorPreferences;
39  class SlicePlotPreferences;
40  class StatisticsRegion;
41 
42  class SlicerMainWindow : public QMainWindow {
43 
44  Q_OBJECT
45 
46  public:
47  SlicerMainWindow(QWidget *parent = 0);
48  void updateChannel( int channel );
49  void updatePolyLine( int regionId, viewer::region::RegionChanges regionChanges,
50  const QList<double> & worldX, const QList<double> & worldY,
51  const QList<int> &pixelX, const QList<int> & pixelY );
52  void addPolyLine( int regionId, viewer::region::RegionChanges regionChanges,
53  const QList<double> & worldX, const QList<double> & worldY,
54  const QList<int> &pixelX, const QList<int> & pixelY, const QString& colorName );
55  void setImage( std::shared_ptr<casacore::ImageInterface<float> > img );
56  bool setRegionSelected( int regionId, bool selected );
57  void setCurveColor( int id, const QString& color );
58  void updatePositionInformation( int id, const QVector<casacore::String>& info );
60 
61  signals:
62  void markerPositionChanged(int regionId,int segmentIndex,float percentage);
63  void markerVisibilityChanged(int regionId,bool showMarker);
64 
65  private slots:
66  void clearCurves();
67  void autoCountChanged( bool selected );
68  void sampleCountChanged();
69  void accumulateChanged( bool accumulate );
70  void interpolationMethodChanged( const QString& method );
71  void showPlotPreferences();
72  void resetPlotPreferences();
73  void exportSlice();
74  void showColorDialog();
75  void resetColors();
76  void zoomIn();
77  void zoomNeutral();
78  void zoomOut();
79  bool checkZoom();
80  void markPositionChanged(int regionId,int segmentIndex,float percentage);
81  void markVisibilityChanged(int regionId,bool showMarker);
82 
83  private:
84  void initializeZooming();
85  SlicerMainWindow( const SlicerMainWindow& mainWindow );
87 
88  int populateSampleCount() const;
89 
90  //Persistence
91  bool toImageFormat( const QString& fileName, const QString& format );
92  bool toASCII( const QString& fileName );
93 
94  //Statistics
96 
100 
102 
103  QStringList methodList;
104  QStringList xAxisList;
105 
106  Ui::SlicerMainWindowClass ui;
107 
108  };
109 }
110 
111 #endif // SLICERMAINWINDOW_QO_H
void updateStatisticsLayout()
Statistics.
void markerVisibilityChanged(int regionId, bool showMarker)
void markPositionChanged(int regionId, int segmentIndex, float percentage)
void updatePositionInformation(int id, const QVector< casacore::String > &info)
void markerPositionChanged(int regionId, int segmentIndex, float percentage)
SlicePlotPreferences * plotPreferences
Ui::SlicerMainWindowClass ui
Specialization for Quantum&lt;Vector&lt;T&gt; &gt;
Definition: QVector.h:37
bool toImageFormat(const QString &fileName, const QString &format)
Persistence.
SlicerMainWindow(QWidget *parent=0)
void interpolationMethodChanged(const QString &method)
int populateSampleCount() const
void markVisibilityChanged(int regionId, bool showMarker)
void updateChannel(int channel)
bool toASCII(const QString &fileName)
void accumulateChanged(bool accumulate)
bool setRegionSelected(int regionId, bool selected)
void updatePolyLine(int regionId, viewer::region::RegionChanges regionChanges, const QList< double > &worldX, const QList< double > &worldY, const QList< int > &pixelX, const QList< int > &pixelY)
SlicerMainWindow & operator=(const SlicerMainWindow &other)
void autoCountChanged(bool selected)
void setCurveColor(int id, const QString &color)
ABSTRACT CLASSES Abstract class for colors Any implementation of color should be able to provide a hexadecimal form of the color(i.e.,"000000"for black) and
void setImage(std::shared_ptr< casacore::ImageInterface< float > > img)
void addPolyLine(int regionId, viewer::region::RegionChanges regionChanges, const QList< double > &worldX, const QList< double > &worldY, const QList< int > &pixelX, const QList< int > &pixelY, const QString &colorName)
SliceColorPreferences * colorPreferences