casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
FeatherMain.qo.h
Go to the documentation of this file.
1 //# Copyright (C) 2005
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 #ifndef FEATHERMAIN_QO_H
26 #define FEATHERMAIN_QO_H
27 
28 #include <QMainWindow>
29 #include <QProgressDialog>
30 
31 #include <guitools/Feather/FeatherMain.ui.h>
37 
38 #include <casa/BasicSL/String.h>
39 #include <casa/aipstype.h>
40 #include <casa/Logging/LogIO.h>
41 
42 using namespace std;
43 
44 namespace casa {
45 
46 class PlotHolder;
47 class FeatherManager;
48 
49 
50 class FeatherMain : public QMainWindow
51 {
52  Q_OBJECT
53 
54 public:
55  FeatherMain(QWidget *parent = 0);
56  ~FeatherMain();
57 
58 signals:
59  void featherFinished();
60 
61 private slots:
62  void openAboutDialog();
63  void openFileLoader();
64  void featherImages( bool checkOutput = true );
65  void openPreferences();
66  void openPreferencesColor();
67  void ySupportChanged( bool ySupport );
68  //Called by the text edits when their values change. Sends
69  //the event down to the plots.
70  void dishDiameterXChanged( const QString& xDiameter );
71  void dishDiameterYChanged( const QString& yDiameter );
72  //Called when the diameter is set through a plot. Updates
73  //the text edits with the new values.
74  void dishDiameterXChanged( double value );
75  void dishDiameterYChanged( double value );
76 
77  void functionColorsChanged();
78  void imageFilesChanged();
79  void preferencesChanged();
80  void featheringDone();
81  void overWriteOK();
82 
83 private:
84  FeatherMain( const FeatherMain& other );
85  FeatherMain operator=( const FeatherMain& other );
86  QString getFileName( QString path ) const;
87 
88  void initializeDishDiameterLimit( QLabel* diamLimitLabel );
89 
90  void clearPlots();
91  bool isInputImagesChanged();
92  //bool generateInputImage();
93  pair<float,float> populateDishDiameters(bool& validDiameters);
94  float populateSDFactor() const;
95 
96  void updatePlaneInformation();
97  void addOriginalDataToPlots();
98  void addFeatheredDataToPlots();
99  void resetDishDiameters();
100  void resetData();
101  void resetDishDiameter( QLineEdit* dishEdit, QLabel* diamLimit,
102  float value, float defaultValue );
103 
104  const static int DISH_DIAMETER_DEFAULT;
105  const static int SINGLE_DISH_FACTOR_DEFAULT;
106 
107  Ui::FeatherMainClass ui;
111 
115  QString dirtyImagePath;
116 
119  QProgressDialog progressMeter;
123 
124 };
125 }
126 #endif // FEATHERMAIN_QO_H
casacore::LogIO logger
Ui::FeatherMainClass ui
PlotHolder * plotHolder
static const int SINGLE_DISH_FACTOR_DEFAULT
PtrHolder< T > & operator=(const PtrHolder< T > &other)
AboutDialog aboutDialog
FileLoader fileLoader
ostream-like interface to creating log messages.
Definition: LogIO.h:167
static const int DISH_DIAMETER_DEFAULT
FeatherWorker1 (SD, INT)
FeatherManager * dataManager
PreferencesColor preferencesColor
QProgressDialog progressMeter
std::string path(const std::string &name)
OverWriteFileDialog overWriteFileDialog
Warns the user that they will be overwriting the output file and provides them with the ability to ch...
Manages the display properties of all the curves that can be shown on the plots.
void defaultValue(CStokesVector &v)
Definition: StokesVector.h:228
FeatherPreferences preferences
LatticeExprNode value(const LatticeExprNode &expr)
This function returns the value of the expression without a mask.
Displays information about Feather to the user.