casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PixelRangeDialog.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 PIXEL_RANGE_DIALOG_QO_H_1
26 #define PIXEL_RANGE_DIALOG_QO_H_1
27 
28 #include <display/Fit/PixelRangeDialog.ui.h>
29 #include <casa/aips.h>
31 #include <utility>
32 #include <QDialog>
33 
34 using namespace std;
35 
36 namespace casacore{
37 
38  template <class T> class ImageInterface;
39  class ImageRegion;
40 }
41 
42 namespace casa {
43 
44  class BinPlotWidget;
45 
46 //Displays a histogram that allows the user
47 //to set a include/exclude pixel range for the fit.
48 
49  class PixelRangeDialog : public QDialog {
50  Q_OBJECT
51 
52  public:
53  PixelRangeDialog(QWidget *parent = 0);
54  void setImage( const std::shared_ptr<const casacore::ImageInterface<float> > img );
55  void setInterval( double minValue, double maxValue );
56  void setImageMode( bool imageMode );
57  void setLineMode( bool lineMode );
58  void setChannelValue( int channel );
59  bool setImageRegion( casacore::ImageRegion* imageRegion, int id );
60  void setTitle( const QString& title );
61  void deleteImageRegion( int id );
62  void imageRegionSelected( int id );
63  pair<double,double> getInterval() const;
64  std::vector<float> getXValues() const;
66 
67  protected:
68  void keyPressEvent( QKeyEvent* event );
69 
70 
71 
72  private:
73  PixelRangeDialog( const PixelRangeDialog& other );
75 
76  Ui::PixelRangeDialogClass ui;
81 
82  };
83 
84 
85 
86 
87 }
88 #endif // THRESHOLDINGBINPLOTDIALOG_H
PtrHolder< T > & operator=(const PtrHolder< T > &other)
A base class for astronomical images.
Ui::PixelRangeDialogClass ui
Display a histogram of intensity vs count.
Class to hold a region of interest in an image.
Definition: ImageRegion.h:86
Displays a histogram that allows the user to set a include/exclude pixel range for the fit...
#define casacore
&lt;X11/Intrinsic.h&gt; #defines true, false, casacore::Bool, and String.
Definition: X11Intrinsic.h:42