#include <mechanism-arrow.h>
Public Member Functions | |
MechanismArrow () | |
virtual | ~MechanismArrow () |
void | SetSource (gcu::Object *source) |
void | SetSourceAux (gcu::Object *aux) |
void | SetTarget (gcu::Object *target) |
void | SetControlPoint (int num, double dx, double dy) |
void | SetShowControls (bool show) |
void | SetPair (bool is_pair) |
void | SetEndAtNewBondCenter (bool end_at_new_bond_center) |
xmlNodePtr | Save (xmlDocPtr xml) const |
bool | Load (xmlNodePtr node) |
void | Transform2D (gcu::Matrix2D &m, double x, double y) |
void | AddItem () |
void | SetSelected (int state) |
void | OnUnlink (Object *object) |
void | OnLoaded () |
std::string | Name () |
gcu::Object * | GetSource (void) const |
gcu::Object * | GetSourceAux (void) const |
gcu::Object * | GetTarget (void) const |
bool | GetShowControls (void) const |
bool | GetPair (void) const |
bool | GetEndAtNewBondCenter (void) const |
Curved arrows used to represent electrons movements during a mechanim step.
Definition at line 45 of file mechanism-arrow.h.
gcp::MechanismArrow::MechanismArrow | ( | ) |
Constructs a new MechanismArrow.
virtual gcp::MechanismArrow::~MechanismArrow | ( | ) | [virtual] |
The destructor.
void gcp::MechanismArrow::AddItem | ( | ) | [virtual] |
Used to add a representation of the mechanism arrow in the view.
Reimplemented from gccv::ItemClient.
gcp::MechanismArrow::GetEndAtNewBondCenter | ( | void | ) | const [inline] |
Definition at line 192 of file mechanism-arrow.h.
gcp::MechanismArrow::GetPair | ( | void | ) | const [inline] |
Definition at line 187 of file mechanism-arrow.h.
gcp::MechanismArrow::GetShowControls | ( | void | ) | const [inline] |
gcp::MechanismArrow::GetSource | ( | void | ) | const [inline] |
Definition at line 171 of file mechanism-arrow.h.
gcp::MechanismArrow::GetSourceAux | ( | void | ) | const [inline] |
Definition at line 175 of file mechanism-arrow.h.
gcp::MechanismArrow::GetTarget | ( | void | ) | const [inline] |
bool gcp::MechanismArrow::Load | ( | xmlNodePtr | node | ) | [virtual] |
node | a pointer to the xmlNode containing the serialized arrow. |
Reimplemented from gcu::Object.
std::string gcp::MechanismArrow::Name | ( | ) | [virtual] |
void gcp::MechanismArrow::OnLoaded | ( | ) | [virtual] |
Ensure that links are correctly set.
Reimplemented from gcu::Object.
void gcp::MechanismArrow::OnUnlink | ( | Object * | object | ) |
object | the object just unlinked by Object::Unlink. |
xmlNodePtr gcp::MechanismArrow::Save | ( | xmlDocPtr | xml | ) | const [virtual] |
xml | the xmlDoc used to save the document. |
Reimplemented from gcu::Object.
void gcp::MechanismArrow::SetControlPoint | ( | int | num, | |
double | dx, | |||
double | dy | |||
) |
num | the control point numbre, should be 1 or 2. | |
dx | the x coordinate of the vector. | |
dy | the y coordinate of the vector. |
void gcp::MechanismArrow::SetEndAtNewBondCenter | ( | bool | end_at_new_bond_center | ) |
end_at_new_bond_center | the position of the arrow end for new bonds. |
void gcp::MechanismArrow::SetPair | ( | bool | is_pair | ) |
is_pair | whether the arrow represents an electrons pair move or a single electron move. |
void gcp::MechanismArrow::SetSelected | ( | int | state | ) | [virtual] |
state | the selection state of the text. |
Reimplemented from gccv::ItemClient.
void gcp::MechanismArrow::SetShowControls | ( | bool | show | ) |
show | whether to show the control points. |
void gcp::MechanismArrow::SetSource | ( | gcu::Object * | source | ) |
source | the source of the electrons. |
void gcp::MechanismArrow::SetSourceAux | ( | gcu::Object * | aux | ) |
aux | an object. |
void gcp::MechanismArrow::SetTarget | ( | gcu::Object * | target | ) |
target | the target of the electron move. |
void gcp::MechanismArrow::Transform2D | ( | gcu::Matrix2D & | m, | |
double | x, | |||
double | y | |||
) | [virtual] |
m | the Matrix2D of the transformation. | |
x | the x component of the center of the transformation. | |
y | the y component of the center of the transformation. |
Reimplemented from gcu::Object.