+++ /dev/null
-#ifndef __LEADER_H__
-#define __LEADER_H__
-
-#include "entity.h"
-#include "entitycontainer.h"
-
-/**
- * Holds the data that defines a leader.
- */
-class LeaderData
-{
- public:
- LeaderData() {}
- LeaderData(bool arrowHeadFlag)
- {
- arrowHead = arrowHeadFlag;
- }
-
- friend std::ostream & operator<<(std::ostream & os, const LeaderData & /*ld*/)
- {
- os << "(Leader)";
- return os;
- }
-
- /** true: leader has an arrow head. false: no arrow. */
- bool arrowHead;
-};
-
-/**
- * Class for a leader entity (kind of a polyline arrow).
- *
- * @author Andrew Mustun
- */
-class Leader: public EntityContainer
-{
- public:
- Leader(EntityContainer * parent = NULL);
- Leader(EntityContainer * parent, const LeaderData & d);
- virtual ~Leader();
-
- virtual Entity * clone();
- virtual RS2::EntityType rtti() const;
- virtual void update();
- LeaderData getData() const;
- bool hasArrowHead();
- virtual Entity * addVertex(const Vector & v);
- virtual void addEntity(Entity * entity);
- virtual double getLength();
- virtual void move(Vector offset);
- virtual void rotate(Vector center, double angle);
- virtual void scale(Vector center, Vector factor);
- virtual void mirror(Vector axisPoint1, Vector axisPoint2);
- virtual void stretch(Vector firstCorner, Vector secondCorner, Vector offset);
-
- friend std::ostream & operator<<(std::ostream & os, const Leader & l);
-
- protected:
- LeaderData data;
- bool empty;
-};
-
-#endif