casa
5.7.0-16
|
Subclass of RegionShape used for drawing text. More...
#include <RegionShapes.h>
Public Member Functions | |
RSText (double x, double y, const casacore::String &text, casacore::MDirection::Types worldSys, double angle=0) | |
World Constructor. More... | |
RSText (double x, double y, const casacore::String &text, double angle=0) | |
Pixel Constructor. More... | |
RSText (const casacore::RecordInterface &properties) | |
casacore::Record Constructor. More... | |
~RSText () | |
Destructor. More... | |
bool | drawAndUpdateBoundingBox (WorldCanvasHolder &wch, casacore::String *err=NULL) |
Implements RegionShape::drawAndUpdateBoundingBox. More... | |
casacore::String | type () const |
Implements RegionShape::type. More... | |
void | getTextCoordinates (double &x, double &y, double &angle, casacore::String toSystem="") const |
Gets text-specific coordinates, to avoid dependence on coordParameterValues() when the shape type is known. More... | |
std::vector< double > | coordParameterValues () const |
Implements RegionShape::coordParameterValues. More... | |
std::vector< double > | coordParameterValues (casacore::String toSystem) const |
Implements RegionShape::coordParameterValues. More... | |
std::vector< casacore::String > | coordParameterNames () const |
Implements RegionShape::coordParameterNames. More... | |
std::vector < CoordinateParameterType > | coordParameterTypes () const |
Implements RegionShape::coordParameterPositions. More... | |
void | setCoordParameters (const std::vector< double > &vals) |
Implements RegionShape::setCoordParameters. More... | |
void | setCoordParameters (const std::vector< double > &vals, casacore::String valSystem) |
Implements RegionShape::setCoordParameters. More... | |
void | move (double dx, double dy, casacore::String system="") |
Implements RegionShape::move. More... | |
RSHandle | getHandle () const |
Implements RegionShape::getHandle. More... | |
std::vector< casacore::String > | optionNames () const |
Implements RegionShape option methods. More... | |
std::vector< OptionType > | optionTypes () const |
std::vector< RSOption > | optionValues () const |
void | setOptionValues (const vector< RSOption > &) |
Protected Member Functions | |
void | getShapeSpecificProperties (casacore::Record &properties) const |
Implements RegionShape::getShapeSpecificProperties. More... | |
void | setShapeSpecificProperties (const casacore::RecordInterface &) |
Implements RegionShape::setShapeSpecificProperties. More... | |
bool | updateScreenCoordinates (WorldCanvasHolder &wch, casacore::String *err) |
Updates screen coords using world/pixel coords and the given WorldCanvas. More... | |
void | updateMinMax () |
Update m_xMin, m_xMax, m_yMin, and m_yMax. More... | |
Protected Attributes | |
double | m_x |
double | m_y |
double | m_angle |
double | m_wWidth |
double | m_screenX |
updated during updateScreenCoordinates More... | |
double | m_screenY |
Subclass of RegionShape used for drawing text.
Text uses RegionShape's label property.
Definition at line 923 of file RegionShapes.h.
RSText::RSText | ( | double | x, |
double | y, | ||
const casacore::String & | text, | ||
casacore::MDirection::Types | worldSys, | ||
double | angle = 0 |
||
) |
World Constructor.
x, y, and angle must both be 1) using the same world system as defined by worldSystem, and 2) in unit RegionShape::UNIT. Angle is counterclockwise, and the base is the east vector.
RSText::RSText | ( | double | x, |
double | y, | ||
const casacore::String & | text, | ||
double | angle = 0 |
||
) |
Pixel Constructor.
Angle is counterclockwise.
RSText::RSText | ( | const casacore::RecordInterface & | properties | ) |
casacore::Record Constructor.
RSText::~RSText | ( | ) |
Destructor.
std::vector<casacore::String> RSText::coordParameterNames | ( | ) | const |
Implements RegionShape::coordParameterNames.
std::vector<CoordinateParameterType> RSText::coordParameterTypes | ( | ) | const |
Implements RegionShape::coordParameterPositions.
std::vector<double> RSText::coordParameterValues | ( | ) | const |
Implements RegionShape::coordParameterValues.
std::vector<double> RSText::coordParameterValues | ( | casacore::String | toSystem | ) | const |
Implements RegionShape::coordParameterValues.
bool RSText::drawAndUpdateBoundingBox | ( | WorldCanvasHolder & | wch, |
casacore::String * | err = NULL |
||
) |
Implements RegionShape::drawAndUpdateBoundingBox.
RSHandle RSText::getHandle | ( | ) | const |
Implements RegionShape::getHandle.
|
inlineprotected |
Implements RegionShape::getShapeSpecificProperties.
Definition at line 1002 of file RegionShapes.h.
References casacore::RecordInterface::define().
void RSText::getTextCoordinates | ( | double & | x, |
double & | y, | ||
double & | angle, | ||
casacore::String | toSystem = "" |
||
) | const |
Gets text-specific coordinates, to avoid dependence on coordParameterValues() when the shape type is known.
If toSystem is empty, no conversion is done; otherwise see the constraints listed in RegionShape::coordParameterValues(casacore::String).
void RSText::move | ( | double | dx, |
double | dy, | ||
casacore::String | system = "" |
||
) |
Implements RegionShape::move.
|
inline |
Implements RegionShape option methods.
Note: text do not have additonal options.
Definition at line 982 of file RegionShapes.h.
|
inline |
Definition at line 985 of file RegionShapes.h.
|
inline |
Definition at line 988 of file RegionShapes.h.
void RSText::setCoordParameters | ( | const std::vector< double > & | vals | ) |
Implements RegionShape::setCoordParameters.
void RSText::setCoordParameters | ( | const std::vector< double > & | vals, |
casacore::String | valSystem | ||
) |
Implements RegionShape::setCoordParameters.
|
inline |
Definition at line 991 of file RegionShapes.h.
|
inlineprotected |
Implements RegionShape::setShapeSpecificProperties.
Definition at line 1007 of file RegionShapes.h.
|
inline |
Implements RegionShape::type.
Definition at line 944 of file RegionShapes.h.
|
protected |
Update m_xMin, m_xMax, m_yMin, and m_yMax.
Note that this is only valid the screen coordinates have been updated.
|
protected |
Updates screen coords using world/pixel coords and the given WorldCanvas.
|
protected |
Definition at line 996 of file RegionShapes.h.
|
protected |
updated during updateScreenCoordinates
Definition at line 999 of file RegionShapes.h.
|
protected |
Definition at line 999 of file RegionShapes.h.
|
protected |
Definition at line 997 of file RegionShapes.h.
|
protected |
Definition at line 995 of file RegionShapes.h.
|
protected |
Definition at line 995 of file RegionShapes.h.