Bridges-C++
3.4.4
Bridges(C++ API)
|
#include <ElementVisualizer.h>
This class maintains the visual properties of the a Bridges element.
This class is used to store the visualization elements for Bridges Visualiztions, including the color, shape, and size of the node. Defaults of "steelblue", CIRCLE, and 10.0 respectively.
Size values must range from [1.0, 50.0]. Colors can be specified by name or by (R,G,B) triplets. See the Color class for details.
BRIDGES supports a number of shapes (specified as enums), namely, CIRCLE, SQUARE, DIAMOND", CROSS, WYE, TRIANGLE, STAR
Objects of this class are stored as properties of all Element subclasses.
Public Member Functions | |
ElementVisualizer (const Color &hue=DEFAULT_COLOR(), const double &sz=DEFAULT_SIZE(), const Shape &shp=DEFAULT_SHAPE()) | |
void | setSize (const double &sz) |
double | getSize () const |
void | setColor (const Color &col) |
Set the color to "col". More... | |
void | setColor (const string &col) |
Set the color to a named color. More... | |
Color | getColor () const |
Return the element color. More... | |
void | setOpacity (double opacity) |
Set opacity of element. More... | |
double | getOpacity () |
Get opacity of element. More... | |
void | setShape (const Shape &shp) |
Set the shape of the element. More... | |
Shape | getShape () const |
Return the shape of the element. More... | |
void | setLocation (const double &locX, const double &locY) |
double | getLocationX () const |
get X coordinate of element location More... | |
double | getLocationY () const |
get Y coordinate of element location More... | |
Static Public Member Functions | |
static const Color | DEFAULT_COLOR () |
static constexpr Shape | DEFAULT_SHAPE () |
static constexpr double | DEFAULT_SIZE () |
|
inline |
|
inlinestatic |
|
inlinestaticconstexpr |
|
inlinestaticconstexpr |
|
inline |
Return the element color.
|
inline |
get X coordinate of element location
|
inline |
get Y coordinate of element location
|
inline |
Get opacity of element.
|
inline |
Return the shape of the element.
|
inline |
|
inline |
Set the color to "col".
col | The color of the element |
|
inline |
Set the color to a named color.
col | The color name. Check the Color class for supported values. |
|
inline |
Set the location attributes of an element. Set location to INFINITY for bridges to chose the location.
locX | X coordinate of the element location |
locY | Y coordinate of the element location |
|
inline |
Set opacity of element.
Set opacity of element - use the 4th color component
opacity | opacity of element to be set |
|
inline |
Set the shape of the element.
shp | is one of CIRCLE, SQUARE, DIAMOND, CROSS, TRIANGLE, WYE, STAR |
|
inline |
Sets size to "sz" Valid Range:[1,50]
sz | The size in pixel weight of the element |
string | If size is invalid |