Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | Related Pages

RS_Entity Class Reference

Base class for an entity (line, arc, circle, . More...

#include <rs_entity.h>

Inheritance diagram for RS_Entity:

RS_Undoable RS_Flags RS_AtomicEntity RS_EntityContainer RS_Arc RS_Circle RS_ConstructionLine RS_Ellipse RS_Image RS_Line RS_Point RS_Solid RS_Dimension RS_Document RS_Hatch RS_Insert RS_Leader RS_Pattern RS_Polyline RS_Preview RS_Spline RS_Text List of all members.

Public Member Functions

 RS_Entity (RS_EntityContainer *parent=NULL)
 Default constructor.
virtual ~RS_Entity ()
 Destructor.
void init ()
 Initialisation.
virtual void initId ()
 Gives this entity a new unique id.
virtual RS_Entityclone ()=0
virtual void copyPropertiesFrom (RS_Entity *e)
virtual void reparent (RS_EntityContainer *parent)
void resetBorders ()
 Resets the borders of this element.
virtual RS2::EntityType rtti () const
 Must be overwritten to return the rtti of this entity (e.g.
virtual RS2::UndoableType undoRtti () const
 Identify all entities as undoable entities.
unsigned long int getId () const
virtual int count ()=0
 This method must be overwritten in subclasses and return the number of atomic entities in this entity.
virtual int countDeep ()=0
 This method must be overwritten in subclasses and return the number of atomic entities in this entity including sub containers.
virtual double getLength ()
 Implementations must return the total length of the entity or a negative number if the entity has no length (e.g.
RS_EntityContainergetParent () const
void setParent (RS_EntityContainer *p)
 Reparents this entity.
RS_GraphicgetGraphic ()
RS_BlockgetBlock ()
RS_InsertgetInsert ()
RS_EntitygetBlockOrInsert ()
RS_DocumentgetDocument ()
void setLayer (const RS_String &name)
 Sets the layer of this entity to the layer with the given name.
void setLayer (RS_Layer *l)
 Sets the layer of this entity to the layer given.
void setLayerToActive ()
 Sets the layer of this entity to the current layer of the graphic this entity is in.
RS_LayergetLayer (bool resolve=true) const
 Returns a pointer to the layer this entity is on or NULL.
void setPen (const RS_Pen &pen)
 Sets the explicit pen for this entity or a pen with special attributes such as BY_LAYER, .
void setPenToActive ()
 Sets the pen of this entity to the current pen of the graphic this entity is in.
RS_Pen getPen (bool resolve=true) const
 Gets the pen needed to draw this entity.
virtual bool isContainer () const =0
 Must be overwritten to return true if an entity type is a container for other entities (e.g.
virtual bool isAtomic () const =0
 Must be overwritten to return true if an entity type is an atomic entity.
virtual bool isEdge () const
 Must be overwritten to return true if an entity type is a potential edge entity of a contour.
virtual bool isDocument () const
virtual bool setSelected (bool select)
 Selects or deselects this entity.
virtual bool toggleSelected ()
 Toggles select on this entity.
virtual bool isSelected () const
virtual bool isParentSelected ()
virtual bool isProcessed () const
virtual void setProcessed (bool on)
 Sets or resets the processed flag of this entity.
virtual bool isInWindow (const RS_Vector &v1, const RS_Vector &v2)
virtual bool hasEndpointsWithinWindow (const RS_Vector &, const RS_Vector &)
virtual bool isVisible ()
 Is this entity visible?
virtual void setVisible (bool v)
virtual void setHighlighted (bool on)
 Sets the highlight status of the entity.
virtual bool isHighlighted ()
virtual bool isLocked ()
virtual void undoStateChanged (bool undone)
 Called when the undo state changed.
virtual bool isUndone () const
virtual void update ()
 Can be implemented by child classes to update the entities temporary subentities.
virtual void setUpdateEnabled (bool on)
RS_Vector getMin () const
 This method doesn't do any calculations.
RS_Vector getMax () const
 This method doesn't do any calculations.
RS_Vector getSize () const
 This method returns the difference of max and min returned by the above functions.
void addGraphicVariable (const RS_String &key, double val, int code)
 Sets a variable value for the parent graphic object.
void addGraphicVariable (const RS_String &key, int val, int code)
 Sets a variable value for the parent graphic object.
void addGraphicVariable (const RS_String &key, const RS_String &val, int code)
 Sets a variable value for the parent graphic object.
double getGraphicVariableDouble (const RS_String &key, double def)
 A safe member function to return the given variable.
int getGraphicVariableInt (const RS_String &key, int def)
 A safe member function to return the given variable.
RS_String getGraphicVariableString (const RS_String &key, const RS_String &def)
 A safe member function to return the given variable.
RS2::Unit getGraphicUnit ()
virtual RS_VectorSolutions getRefPoints ()
 Must be overwritten to get all reference points of the entity.
virtual RS_Vector getNearestEndpoint (const RS_Vector &coord, double *dist=NULL)=0
 Must be overwritten to get the closest endpoint to the given coordinate for this entity.
virtual RS_Vector getNearestPointOnEntity (const RS_Vector &, bool onEntity=true, double *dist=NULL, RS_Entity **entity=NULL)=0
 Must be overwritten to get the closest coordinate to the given coordinate which is on this entity.
virtual RS_Vector getNearestCenter (const RS_Vector &coord, double *dist=NULL)=0
 Must be overwritten to get the (nearest) center point to the given coordinate for this entity.
virtual RS_Vector getNearestMiddle (const RS_Vector &coord, double *dist=NULL)=0
 Must be overwritten to get the (nearest) middle point to the given coordinate for this entity.
virtual RS_Vector getNearestDist (double distance, const RS_Vector &coord, double *dist=NULL)=0
 Must be overwritten to get the nearest point with a given distance to the endpoint to the given coordinate for this entity.
virtual RS_Vector getNearestDist (double, bool)
 Must be overwritten to get the point with a given distance to the start- or endpoint to the given coordinate for this entity.
virtual RS_Vector getNearestRef (const RS_Vector &coord, double *dist=NULL)
 Must be overwritten to get the nearest reference point for this entity.
virtual RS_Vector getNearestSelectedRef (const RS_Vector &coord, double *dist=NULL)
 Gets the nearest reference point of this entity if it is selected.
virtual double getDistanceToPoint (const RS_Vector &coord, RS_Entity **entity=NULL, RS2::ResolveLevel level=RS2::ResolveNone, double solidDist=RS_MAXDOUBLE)=0
 Must be overwritten to get the shortest distance between this entity and a coordinate.
virtual bool isPointOnEntity (const RS_Vector &coord, double tolerance=RS_TOLERANCE)
virtual RS2::Side getSideOfPoint (const RS_Vector &coord)=0
 Implementations must return RS2::RightHand if coord is on the right hand side of this entity, RS2::LeftHand if it is on the left hand side and RS2::NoSide otherwise (on entity, entity has no side, .
virtual void move (const RS_Vector &offset)=0
 Implementations must move the entity by the given vector.
virtual void rotate (const RS_Vector &center, double angle)=0
 Implementations must rotate the entity by the given angle around the given center.
virtual void scale (const RS_Vector &center, const RS_Vector &factor)=0
 Implementations must scale the entity by the given factors.
virtual void scale (const RS_Vector &center, double factor)
 Acts like scale(RS_Vector) but with equal factors.
virtual void mirror (const RS_Vector &axisPoint1, const RS_Vector &axisPoint2)=0
 Implementations must mirror the entity by the given axis.
virtual void stretch (const RS_Vector &firstCorner, const RS_Vector &secondCorner, const RS_Vector &offset)
 Implementations must stretch the given range of the entity by the given offset.
virtual void moveRef (const RS_Vector &, const RS_Vector &)
 Implementations must drag the reference point(s) of all (sub-)entities that are very close to ref by offset.
virtual void moveSelectedRef (const RS_Vector &, const RS_Vector &)
 Implementations must drag the reference point(s) of selected (sub-)entities that are very close to ref by offset.
virtual void draw (RS_Painter *painter, RS_GraphicView *view, double patternOffset=0.0)=0
 Implementations must draw the entity on the given device.
double getStyleFactor (RS_GraphicView *view)
virtual RS_Variant getVariable (const RS_String &name, const RS_Variant &def=RS_Variant())
 Returns the variable with the given name or 'def'.
virtual RS_StringList getAllVariableNames ()
virtual void setVariable (const RS_String &name, const RS_Variant &value)
 Sets the variable with the given name to the given value.
virtual void deleteVariable (const RS_String &name)
 Deletes the variable with the given name.
virtual void calculateBorders ()=0
 Recalculates the borders of this entity.

Protected Attributes

RS_EntityContainerparent
 Entity's parent entity or NULL is this entity has no parent.
RS_Vector minV
 minimum coordinates
RS_Vector maxV
 maximum coordinates
RS_Layerlayer
 Pointer to layer.
unsigned long int id
 Entity id.
RS_Pen pen
 pen (attributes) for this entity
bool updateEnabled
 auto updating enabled?

Detailed Description

Base class for an entity (line, arc, circle, .

..)

Author:
Andrew Mustun


Constructor & Destructor Documentation

RS_Entity::RS_Entity RS_EntityContainer parent = NULL  ) 
 

Default constructor.

Parameters:
parent The parent entity of this entity. E.g. a line might have a graphic entity or a polyline entity as parent.


Member Function Documentation

void RS_Entity::addGraphicVariable const RS_String &  key,
const RS_String &  val,
int  code
 

Sets a variable value for the parent graphic object.

Parameters:
key Variable name (e.g. "$DIMASZ")
val Default value

void RS_Entity::addGraphicVariable const RS_String &  key,
int  val,
int  code
 

Sets a variable value for the parent graphic object.

Parameters:
key Variable name (e.g. "$DIMASZ")
val Default value

void RS_Entity::addGraphicVariable const RS_String &  key,
double  val,
int  code
 

Sets a variable value for the parent graphic object.

Parameters:
key Variable name (e.g. "$DIMASZ")
val Default value

RS_StringList RS_Entity::getAllVariableNames  )  [virtual]
 

Returns:
Names of all known variables that are defined for this entity.

RS_Block * RS_Entity::getBlock  ) 
 

Returns:
The parent block in which this entity is stored or the parent's parent block or NULL if none of the parents are stored in a block.

RS_Entity * RS_Entity::getBlockOrInsert  ) 
 

Returns:
The parent block or insert in which this entity is stored or the parent's parent block or insert or NULL if none of the parents are stored in a block or insert.

virtual double RS_Entity::getDistanceToPoint const RS_Vector coord,
RS_Entity **  entity = NULL,
RS2::ResolveLevel  level = RS2::ResolveNone,
double  solidDist = RS_MAXDOUBLE
[pure virtual]
 

Must be overwritten to get the shortest distance between this entity and a coordinate.

Parameters:
coord Coordinate (typically a mouse coordinate)
entity Pointer which will contain the (sub-)entity which is closest to the given point or NULL if the caller is not interested in this information.
level The resolve level.
See also:
RS2::ResolveLevel
Returns:
The measured distance between coord and the entity.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Hatch, RS_Image, RS_Line, RS_Point, and RS_Solid.

RS_Document * RS_Entity::getDocument  ) 
 

Returns:
The parent document in which this entity is stored or the parent's parent document or NULL if none of the parents are stored in a document. Note that a document is usually either a Graphic or a Block.

RS_Graphic * RS_Entity::getGraphic  ) 
 

Returns:
The parent graphic in which this entity is stored or the parent's parent graphic or NULL if none of the parents are stored in a graphic.

RS2::Unit RS_Entity::getGraphicUnit  ) 
 

Returns:
The unit the parent graphic works on or None if there's no parent graphic.

double RS_Entity::getGraphicVariableDouble const RS_String &  key,
double  def
 

A safe member function to return the given variable.

Parameters:
key Variable name (e.g. "$DIMASZ")
def Default value
Returns:
value of variable or default value if the given variable doesn't exist.

int RS_Entity::getGraphicVariableInt const RS_String &  key,
int  def
 

A safe member function to return the given variable.

Parameters:
key Variable name (e.g. "$DIMASZ")
def Default value
Returns:
value of variable or default value if the given variable doesn't exist.

RS_String RS_Entity::getGraphicVariableString const RS_String &  key,
const RS_String &  def
 

A safe member function to return the given variable.

Parameters:
key Variable name (e.g. "$DIMASZ")
def Default value
Returns:
value of variable or default value if the given variable doesn't exist.

unsigned long int RS_Entity::getId  )  const [inline]
 

Returns:
Unique Id of this entity.

RS_Insert * RS_Entity::getInsert  ) 
 

Returns:
The parent insert in which this entity is stored or the parent's parent block or NULL if none of the parents are stored in a block.

RS_Layer * RS_Entity::getLayer bool  resolve = true  )  const
 

Returns a pointer to the layer this entity is on or NULL.

resolve true: if the layer is ByBlock, the layer of the block this entity is in is returned. false: the layer of the entity is returned.

Returns:
pointer to the layer this entity is on. If the layer is set to NULL the layer of the next parent that is not on layer NULL is returned. If all parents are on layer NULL, NULL is returned.

virtual double RS_Entity::getLength  )  [inline, virtual]
 

Implementations must return the total length of the entity or a negative number if the entity has no length (e.g.

a text or hatch).

Reimplemented in RS_Arc, RS_Circle, RS_Dimension, RS_EntityContainer, RS_Hatch, RS_Image, RS_Leader, RS_Line, and RS_Text.

RS_Vector RS_Entity::getMax  )  const [inline]
 

This method doesn't do any calculations.

Returns:
minimum coordinate of the entity.
See also:
calculateBorders()

RS_Vector RS_Entity::getMin  )  const [inline]
 

This method doesn't do any calculations.

Returns:
minimum coordinate of the entity.
See also:
calculateBorders()

virtual RS_Vector RS_Entity::getNearestCenter const RS_Vector coord,
double *  dist = NULL
[pure virtual]
 

Must be overwritten to get the (nearest) center point to the given coordinate for this entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest center point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest center point.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, RS_Solid, and RS_Spline.

virtual RS_Vector RS_Entity::getNearestDist double  ,
bool 
[inline, virtual]
 

Must be overwritten to get the point with a given distance to the start- or endpoint to the given coordinate for this entity.

Parameters:
distance Distance to endpoint.
startp true = measured from Startpoint, false = measured from Endpoint
Returns:
The point with the given distance to the start- or endpoint.

Reimplemented in RS_Arc, RS_Circle, and RS_Line.

virtual RS_Vector RS_Entity::getNearestDist double  distance,
const RS_Vector coord,
double *  dist = NULL
[pure virtual]
 

Must be overwritten to get the nearest point with a given distance to the endpoint to the given coordinate for this entity.

Parameters:
distance Distance to endpoint.
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest point with the given distance to the endpoint.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, RS_Solid, and RS_Spline.

virtual RS_Vector RS_Entity::getNearestEndpoint const RS_Vector coord,
double *  dist = NULL
[pure virtual]
 

Must be overwritten to get the closest endpoint to the given coordinate for this entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest endpoint. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest endpoint.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, RS_Solid, and RS_Spline.

virtual RS_Vector RS_Entity::getNearestMiddle const RS_Vector coord,
double *  dist = NULL
[pure virtual]
 

Must be overwritten to get the (nearest) middle point to the given coordinate for this entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest middle point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest middle point.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, RS_Solid, and RS_Spline.

virtual RS_Vector RS_Entity::getNearestPointOnEntity const RS_Vector ,
bool  onEntity = true,
double *  dist = NULL,
RS_Entity **  entity = NULL
[pure virtual]
 

Must be overwritten to get the closest coordinate to the given coordinate which is on this entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between coord and the point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest coordinate.

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, and RS_Solid.

virtual RS_Vector RS_Entity::getNearestRef const RS_Vector coord,
double *  dist = NULL
[inline, virtual]
 

Must be overwritten to get the nearest reference point for this entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest point with the given distance to the endpoint.

Reimplemented in RS_Dimension, RS_EntityContainer, RS_Insert, RS_Leader, RS_Polyline, RS_Spline, and RS_Text.

virtual RS_Vector RS_Entity::getNearestSelectedRef const RS_Vector coord,
double *  dist = NULL
[inline, virtual]
 

Gets the nearest reference point of this entity if it is selected.

Containers re-implement this method to return the nearest reference point of a selected sub entity.

Parameters:
coord Coordinate (typically a mouse coordinate)
dist Pointer to a value which will contain the measured distance between 'coord' and the closest point. The passed pointer can also be NULL in which case the distance will be lost.
Returns:
The closest point with the given distance to the endpoint.

Reimplemented in RS_Dimension, RS_EntityContainer, RS_Leader, RS_Polyline, and RS_Spline.

RS_EntityContainer* RS_Entity::getParent  )  const [inline]
 

Returns:
Parent of this entity or NULL if this is a root entity.

RS_Pen RS_Entity::getPen bool  resolve = true  )  const
 

Gets the pen needed to draw this entity.

The attributes can also come from the layer this entity is on if the flags are set accordingly.

Parameters:
resolve true: Resolve the pen to a drawable pen (e.g. the pen from the layer or parent..) false: Don't resolve and return a pen or ByLayer, ByBlock, ...
Returns:
Pen for this entity.

virtual RS2::Side RS_Entity::getSideOfPoint const RS_Vector coord  )  [pure virtual]
 

Implementations must return RS2::RightHand if coord is on the right hand side of this entity, RS2::LeftHand if it is on the left hand side and RS2::NoSide otherwise (on entity, entity has no side, .

.).

Implemented in RS_Arc, RS_Circle, RS_ConstructionLine, RS_Ellipse, RS_EntityContainer, RS_Image, RS_Line, RS_Point, and RS_Solid.

RS_Vector RS_Entity::getSize  )  const [inline]
 

This method returns the difference of max and min returned by the above functions.

Returns:
size of the entity.
See also:
calculateBorders()

getMin()

getMax()

double RS_Entity::getStyleFactor RS_GraphicView view  ) 
 

Returns:
Factor for scaling the line styles considering the current paper scaling and the fact that styles are stored in Millimeter.

RS_Variant RS_Entity::getVariable const RS_String &  name,
const RS_Variant &  def = RS_Variant()
[virtual]
 

Returns the variable with the given name or 'def'.

Parameters:
name Variable name.
def Default value to return if the given variable is undefined.

void RS_Entity::init  ) 
 

Initialisation.

Called from all constructors.

virtual bool RS_Entity::isContainer  )  const [pure virtual]
 

Must be overwritten to return true if an entity type is a container for other entities (e.g.

polyline, group, ...).

Implemented in RS_AtomicEntity, RS_EntityContainer, and RS_Hatch.

virtual bool RS_Entity::isDocument  )  const [inline, virtual]
 

Returns:
true for all document entities (e.g. Graphics or Blocks). false otherwise.

Reimplemented in RS_Document.

virtual bool RS_Entity::isEdge  )  const [inline, virtual]
 

Must be overwritten to return true if an entity type is a potential edge entity of a contour.

By default this returns false.

Reimplemented in RS_Arc, RS_Circle, RS_Line, and RS_Spline.

bool RS_Entity::isHighlighted  )  [virtual]
 

Returns:
true if the entity is highlighted.

bool RS_Entity::isInWindow const RS_Vector v1,
const RS_Vector v2
[virtual]
 

Returns:
True if the entity is in the given range.

bool RS_Entity::isLocked  )  [virtual]
 

Returns:
true if the layer this entity is on is locked.

bool RS_Entity::isParentSelected  )  [virtual]
 

Returns:
true if a parent entity of this entity is selected.

bool RS_Entity::isPointOnEntity const RS_Vector coord,
double  tolerance = RS_TOLERANCE
[virtual]
 

Parameters:
tolerance Tolerance.
Return values:
true if the given point is on this entity.
false otherwise

Reimplemented in RS_Ellipse.

bool RS_Entity::isProcessed  )  const [virtual]
 

Returns:
True if the processed flag is set.

bool RS_Entity::isSelected  )  const [virtual]
 

Returns:
True if the entity is selected. Note that an entity might not be selected but one of its parents is selected. In that case this function returns false.

bool RS_Entity::isUndone  )  const [virtual]
 

Returns:
true if this entity or any parent entities are undone.

Reimplemented from RS_Undoable.

bool RS_Entity::isVisible  )  [virtual]
 

Is this entity visible?

Returns:
true Only if the entity and the layer it is on are visible. The Layer might also be NULL. In that case the layer visiblity is ignored.

Reimplemented in RS_Insert.

virtual RS2::EntityType RS_Entity::rtti  )  const [inline, virtual]
 

Must be overwritten to return the rtti of this entity (e.g.

RS2::EntityArc).

Reimplemented in RS_Arc, RS_Block, RS_Circle, RS_ConstructionLine, RS_DimAligned, RS_DimAngular, RS_DimDiametric, RS_DimLinear, RS_DimRadial, RS_Ellipse, RS_EntityContainer, RS_FontChar, RS_Graphic, RS_Hatch, RS_Image, RS_Insert, RS_Leader, RS_Line, RS_Point, RS_Polyline, RS_Solid, RS_Spline, and RS_Text.

virtual void RS_Entity::scale const RS_Vector center,
double  factor
[inline, virtual]
 

Acts like scale(RS_Vector) but with equal factors.

Equal to scale(center, RS_Vector(factor, factor)).

void RS_Entity::setHighlighted bool  on  )  [virtual]
 

Sets the highlight status of the entity.

Highlighted entities usually indicate a feedback to a user action.

void RS_Entity::setLayerToActive  ) 
 

Sets the layer of this entity to the current layer of the graphic this entity is in.

If this entity (and none of its parents) are in a graphic the layer is set to NULL.

void RS_Entity::setPen const RS_Pen pen  )  [inline]
 

Sets the explicit pen for this entity or a pen with special attributes such as BY_LAYER, .

void RS_Entity::setPenToActive  ) 
 

Sets the pen of this entity to the current pen of the graphic this entity is in.

If this entity (and none of its parents) are in a graphic the pen is not changed.

void RS_Entity::setProcessed bool  on  )  [virtual]
 

Sets or resets the processed flag of this entity.

Parameters:
on True to set, false to reset.

Reimplemented in RS_EntityContainer.

bool RS_Entity::setSelected bool  select  )  [virtual]
 

Selects or deselects this entity.

Parameters:
select True to select, false to deselect.

Reimplemented in RS_EntityContainer.

void RS_Entity::setVariable const RS_String &  name,
const RS_Variant &  value
[virtual]
 

Sets the variable with the given name to the given value.

A previously existing variable with the same name is overwritten.

Parameters:
name Name of the variable (unique for this entity).
value Initial value of the variable.

void RS_Entity::stretch const RS_Vector firstCorner,
const RS_Vector secondCorner,
const RS_Vector offset
[virtual]
 

Implementations must stretch the given range of the entity by the given offset.

This default implementation moves the whole entity if it is completely inside the given range.

Reimplemented in RS_Arc, RS_DimAligned, RS_DimLinear, RS_EntityContainer, RS_Hatch, RS_Leader, RS_Line, RS_Polyline, and RS_Text.

virtual RS2::UndoableType RS_Entity::undoRtti  )  const [inline, virtual]
 

Identify all entities as undoable entities.

Returns:
RS2::UndoableEntity

Reimplemented from RS_Undoable.

void RS_Entity::undoStateChanged bool  undone  )  [virtual]
 

Called when the undo state changed.

Parameters:
undone true: entity has become invisible. false: entity has become visible.

Reimplemented from RS_Undoable.

Reimplemented in RS_EntityContainer.

virtual void RS_Entity::update  )  [inline, virtual]
 

Can be implemented by child classes to update the entities temporary subentities.

update() is called if the entity's paramters or undo state changed.

Reimplemented in RS_EntityContainer, RS_Hatch, RS_Image, RS_Insert, RS_Leader, RS_Spline, and RS_Text.


The documentation for this class was generated from the following files:
Generated on Sat Jan 6 13:48:23 2007 for qcadlib by  doxygen 1.4.4