casa
$Rev:20696$
|
All regions are specified in "linear coordinates", not "pixel coordinates". More...
#include <QtRectangle.qo.h>
Public Slots | |
void | adjustCorners (double, double, double, double) |
Public Member Functions | |
~QtRectangle () | |
const std::string | name () const |
std::string | lineColor () const |
std::string | centerColor () const |
int | lineWidth () const |
Region::LineStyle | lineStyle () const |
std::string | textColor () const |
std::string | textFont () const |
int | textFontSize () const |
int | textFontStyle () const |
std::string | textValue () const |
Region::TextPosition | textPosition () const |
void | textPositionDelta (int &x, int &y) const |
void | getCoordinatesAndUnits (Region::Coord &c, Region::Units &x_units, Region::Units &y_units, std::string &width_height_units) const |
void | getPositionString (std::string &x, std::string &y, std::string &angle, double &bounding_width, double &bounding_height, Region::Coord coord=Region::DefaultCoord, Region::Units x_units=Region::DefaultUnits, Region::Units y_units=Region::DefaultUnits, const std::string &bounding_units="rad") const |
bool | translateX (const std::string &x, const std::string &x_units, const std::string &coordsys) |
bool | translateY (const std::string &y, const std::string &y_units, const std::string &coordsys) |
bool | resizeX (const std::string &x, const std::string &x_units, const std::string &coordsys) |
bool | resizeY (const std::string &y, const std::string &y_units, const std::string &coordsys) |
int | numFrames () const |
void | zRange (int &min, int &max) const |
int | zIndex () const |
bool | regionVisible () const |
void | linearCenter (double &x, double &y) const |
void | pixelCenter (double &x, double &y) const |
DISPLAY_PURE_VIRTUAL(region::linearCenter,);. | |
QtRectangle (QtRegionSourceKernel *factory, WorldCanvas *wc, double blc_x, double blc_y, double trc_x, double trc_y, bool hold_signals=false) | |
void | refresh () |
qt-event -> QtRegion -> QtRectangle -> Region::refresh( ) | |
AnnotationBase * | annotation () const |
void | selectedInCanvas () |
indicates that the user has selected this rectangle... | |
bool | weaklySelected () const |
is this region weakly or temporarily selected? | |
void | weaklySelect () |
void | weaklyUnselect () |
void | updateStateInfo (bool region_modified, Region::RegionChanges change) |
indicates that region movement requires that the statistcs be updated... | |
void | invalidateCenterInfo () |
indicates that the center info is no longer valid | |
void | clearStatistics () |
void | setLabel (const std::string &l) |
set attributes when loading a casa region text file... | |
void | setLabelPosition (TextPosition pos) |
void | setLabelDelta (const std::vector< int > &delta) |
void | setFont (const std::string &font="", int font_size=-1, int font_style=0, const std::string &font_color="") |
void | setLine (const std::string &line_color="", Region::LineStyle line_style=SolidLine, unsigned int line_width=1) |
void | setAnnotation (bool ann) |
void | mark (bool set=true) |
functions added with the introduction of RegionToolManager and the unified selection and manipulation of the various region types... | |
bool | marked () const |
bool | mark_toggle () |
void | status (const std::string &msg, const std::string &type="info") |
bool | markCenter () const |
bool | skyComponent () const |
void | output (ds9writer &out) const |
void | emitUpdate () |
called for existing regions when spectral profile tool is opened... | |
Protected Member Functions | |
std::list< RegionInfo > * | generate_dds_statistics () |
--------------------==================== from old QtRegion ====================-------------------- | |
ImageRegion * | get_image_region (DisplayData *dd) const |
const std::list< Region * > & | get_selected_regions () |
size_t | selected_region_count () |
size_t | marked_region_count () |
virtual Region * | fetch_my_region () |
virtual void | fetch_region_details (RegionTypes &type, std::vector< std::pair< int, int > > &pixel_pts, std::vector< std::pair< double, double > > &world_pts) const |
std::list< RegionInfo > * | generate_dds_centers () |
All regions are specified in "linear coordinates", not "pixel coordinates".
This is necessary because "linear coordinates" scale with zooming whereas "pixel coordinates" do not. Unfortunately, this means that coordinate transformation is required each time the region is drawn.
Key points:
Definition at line 46 of file QtRectangle.qo.h.
casa::viewer::QtRectangle::QtRectangle | ( | QtRegionSourceKernel * | factory, |
WorldCanvas * | wc, | ||
double | blc_x, | ||
double | blc_y, | ||
double | trc_x, | ||
double | trc_y, | ||
bool | hold_signals = false |
||
) |
void casa::viewer::QtRectangle::adjustCorners | ( | double | , |
double | , | ||
double | , | ||
double | |||
) | [slot] |
Reimplemented from casa::viewer::Region.
AnnotationBase* casa::viewer::QtRectangle::annotation | ( | ) | const [inline] |
Reimplemented from casa::viewer::Rectangle.
Definition at line 98 of file QtRectangle.qo.h.
std::string casa::viewer::QtRectangle::centerColor | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 54 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::clearStatistics | ( | ) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 113 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::emitUpdate | ( | ) | [inline] |
called for existing regions when spectral profile tool is opened...
Reimplemented from casa::viewer::QtRegion.
Definition at line 138 of file QtRectangle.qo.h.
virtual Region* casa::viewer::QtRectangle::fetch_my_region | ( | ) | [inline, protected, virtual] |
Definition at line 149 of file QtRectangle.qo.h.
virtual void casa::viewer::QtRectangle::fetch_region_details | ( | RegionTypes & | type, |
std::vector< std::pair< int, int > > & | pixel_pts, | ||
std::vector< std::pair< double, double > > & | world_pts | ||
) | const [inline, protected, virtual] |
Definition at line 150 of file QtRectangle.qo.h.
std::list<RegionInfo>* casa::viewer::QtRectangle::generate_dds_centers | ( | ) | [inline, protected, virtual] |
Reimplemented from casa::viewer::Rectangle.
Definition at line 153 of file QtRectangle.qo.h.
std::list<RegionInfo>* casa::viewer::QtRectangle::generate_dds_statistics | ( | ) | [inline, protected, virtual] |
--------------------==================== from old QtRegion ====================--------------------
Reimplemented from casa::viewer::Region.
Definition at line 144 of file QtRectangle.qo.h.
ImageRegion* casa::viewer::QtRectangle::get_image_region | ( | DisplayData * | dd | ) | const [inline, protected, virtual] |
Implements casa::viewer::QtRegion.
Definition at line 145 of file QtRectangle.qo.h.
const std::list<Region*>& casa::viewer::QtRectangle::get_selected_regions | ( | ) | [inline, protected, virtual] |
Implements casa::viewer::Region.
Definition at line 146 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::getCoordinatesAndUnits | ( | Region::Coord & | c, |
Region::Units & | x_units, | ||
Region::Units & | y_units, | ||
std::string & | width_height_units | ||
) | const [inline] |
Reimplemented from casa::viewer::Region.
Definition at line 67 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::getPositionString | ( | std::string & | x, |
std::string & | y, | ||
std::string & | angle, | ||
double & | bounding_width, | ||
double & | bounding_height, | ||
Region::Coord | coord = Region::DefaultCoord , |
||
Region::Units | x_units = Region::DefaultUnits , |
||
Region::Units | y_units = Region::DefaultUnits , |
||
const std::string & | bounding_units = "rad" |
||
) | const [inline] |
Reimplemented from casa::viewer::Region.
Definition at line 69 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::invalidateCenterInfo | ( | ) | [inline] |
indicates that the center info is no longer valid
Reimplemented from casa::viewer::QtRegion.
Definition at line 111 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::linearCenter | ( | double & | x, |
double & | y | ||
) | const [inline] |
Reimplemented from casa::viewer::Rectangle.
Definition at line 91 of file QtRectangle.qo.h.
std::string casa::viewer::QtRectangle::lineColor | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 53 of file QtRectangle.qo.h.
Region::LineStyle casa::viewer::QtRectangle::lineStyle | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 56 of file QtRectangle.qo.h.
int casa::viewer::QtRectangle::lineWidth | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 55 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::mark | ( | bool | set = true | ) | [inline] |
functions added with the introduction of RegionToolManager and the unified selection and manipulation of the various region types...
Reimplemented from casa::viewer::QtRegion.
Definition at line 126 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::mark_toggle | ( | ) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 128 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::markCenter | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 132 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::marked | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 127 of file QtRectangle.qo.h.
size_t casa::viewer::QtRectangle::marked_region_count | ( | ) | [inline, protected] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 148 of file QtRectangle.qo.h.
const std::string casa::viewer::QtRectangle::name | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 51 of file QtRectangle.qo.h.
int casa::viewer::QtRectangle::numFrames | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 86 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::output | ( | ds9writer & | out | ) | const [virtual] |
Implements casa::viewer::QtRegion.
void casa::viewer::QtRectangle::pixelCenter | ( | double & | , |
double & | |||
) | const [inline, virtual] |
DISPLAY_PURE_VIRTUAL(region::linearCenter,);.
Implements casa::viewer::QtRegion.
Definition at line 92 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::refresh | ( | ) | [inline] |
qt-event -> QtRegion -> QtRectangle -> Region::refresh( )
Reimplemented from casa::viewer::Region.
Definition at line 97 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::regionVisible | ( | ) | const [inline] |
Reimplemented from casa::viewer::Region.
Definition at line 90 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::resizeX | ( | const std::string & | x, |
const std::string & | x_units, | ||
const std::string & | coordsys | ||
) | [inline, virtual] |
Implements casa::viewer::QtRegion.
Definition at line 81 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::resizeY | ( | const std::string & | y, |
const std::string & | y_units, | ||
const std::string & | coordsys | ||
) | [inline, virtual] |
Implements casa::viewer::QtRegion.
Definition at line 83 of file QtRectangle.qo.h.
size_t casa::viewer::QtRectangle::selected_region_count | ( | ) | [inline, protected] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 147 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::selectedInCanvas | ( | ) | [inline, virtual] |
indicates that the user has selected this rectangle...
Reimplemented from casa::viewer::Region.
Definition at line 101 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setAnnotation | ( | bool | ann | ) | [inline, virtual] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 122 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setFont | ( | const std::string & | font = "" , |
int | font_size = -1 , |
||
int | font_style = 0 , |
||
const std::string & | font_color = "" |
||
) | [inline, virtual] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 118 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setLabel | ( | const std::string & | l | ) | [inline, virtual] |
set attributes when loading a casa region text file...
Reimplemented from casa::viewer::QtRegion.
Definition at line 115 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setLabelDelta | ( | const std::vector< int > & | delta | ) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 117 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setLabelPosition | ( | TextPosition | pos | ) | [inline, virtual] |
Implements casa::viewer::Region.
Definition at line 116 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::setLine | ( | const std::string & | line_color = "" , |
Region::LineStyle | line_style = SolidLine , |
||
unsigned int | line_width = 1 |
||
) | [inline, virtual] |
Implements casa::viewer::Region.
Definition at line 120 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::skyComponent | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 134 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::status | ( | const std::string & | msg, |
const std::string & | type = "info" |
||
) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 130 of file QtRectangle.qo.h.
References casa::viewer::Rectangle::type().
std::string casa::viewer::QtRectangle::textColor | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 59 of file QtRectangle.qo.h.
std::string casa::viewer::QtRectangle::textFont | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 60 of file QtRectangle.qo.h.
int casa::viewer::QtRectangle::textFontSize | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 61 of file QtRectangle.qo.h.
int casa::viewer::QtRectangle::textFontStyle | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 62 of file QtRectangle.qo.h.
Region::TextPosition casa::viewer::QtRectangle::textPosition | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 64 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::textPositionDelta | ( | int & | x, |
int & | y | ||
) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 65 of file QtRectangle.qo.h.
std::string casa::viewer::QtRectangle::textValue | ( | ) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 63 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::translateX | ( | const std::string & | x, |
const std::string & | x_units, | ||
const std::string & | coordsys | ||
) | [inline, virtual] |
Implements casa::viewer::QtRegion.
Definition at line 77 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::translateY | ( | const std::string & | y, |
const std::string & | y_units, | ||
const std::string & | coordsys | ||
) | [inline, virtual] |
Implements casa::viewer::QtRegion.
Definition at line 79 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::updateStateInfo | ( | bool | region_modified, |
Region::RegionChanges | change | ||
) | [inline] |
indicates that region movement requires that the statistcs be updated...
Definition at line 108 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::weaklySelect | ( | ) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 104 of file QtRectangle.qo.h.
bool casa::viewer::QtRectangle::weaklySelected | ( | ) | const [inline] |
is this region weakly or temporarily selected?
Reimplemented from casa::viewer::QtRegion.
Definition at line 103 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::weaklyUnselect | ( | ) | [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 105 of file QtRectangle.qo.h.
int casa::viewer::QtRectangle::zIndex | ( | ) | const [inline] |
Reimplemented from casa::viewer::Region.
Definition at line 88 of file QtRectangle.qo.h.
void casa::viewer::QtRectangle::zRange | ( | int & | min, |
int & | max | ||
) | const [inline] |
Reimplemented from casa::viewer::QtRegion.
Definition at line 87 of file QtRectangle.qo.h.