TinkerCell Core 1.0
TinkerCell's Core library providing all basic functionalities
Public Member Functions | Public Attributes
Tinkercell::AddCurveSegmentCommand Class Reference

An command that adds a new control point to a connection item; it has undo and redo functionality. More...

#include <UndoCommands.h>

Inheritance diagram for Tinkercell::AddCurveSegmentCommand:
Inheritance graph
[legend]
Collaboration diagram for Tinkercell::AddCurveSegmentCommand:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 AddCurveSegmentCommand (const QString &name, GraphicsScene *scene, ConnectionGraphicsItem *connection, ConnectionGraphicsItem::CurveSegment &item)
 constructor that makes the command. If added to history stack, also does redo
 AddCurveSegmentCommand (const QString &name, GraphicsScene *scene, ConnectionGraphicsItem *connection, QList< ConnectionGraphicsItem::CurveSegment > items)
 constructor that makes the command. If added to history stack, also does redo
virtual ~AddCurveSegmentCommand ()
 destructor. deletes all control points that do not belong a scene
void redo ()
 Adds a new control point. Control points were set in the constructor.
void undo ()
 Remove new control points. Control points were set in the constructor.

Public Attributes

GraphicsScenegraphicsScene
 graphics scene to which control points were added
ConnectionGraphicsItemconnectionItem
 graphics item to which control points were added
QList
< ConnectionGraphicsItem::CurveSegment
curveSegments
 vector of control points that were added
QList< int > listK1
 the poisition(s) at which the control point vectors were added

Detailed Description

An command that adds a new control point to a connection item; it has undo and redo functionality.

Definition at line 792 of file UndoCommands.h.


Constructor & Destructor Documentation

Tinkercell::AddCurveSegmentCommand::AddCurveSegmentCommand ( const QString &  name,
GraphicsScene scene,
ConnectionGraphicsItem connection,
ConnectionGraphicsItem::CurveSegment item 
)

constructor that makes the command. If added to history stack, also does redo

Parameters:
name
graphicsscene
controlpoint(s) that have been added
Returns:
void

Definition at line 3797 of file UndoCommands.cpp.

Tinkercell::AddCurveSegmentCommand::AddCurveSegmentCommand ( const QString &  name,
GraphicsScene scene,
ConnectionGraphicsItem connection,
QList< ConnectionGraphicsItem::CurveSegment items 
)

constructor that makes the command. If added to history stack, also does redo

Parameters:
name
graphicsscene
controlpoint(s) that have been added
Returns:
void

Definition at line 3811 of file UndoCommands.cpp.

Tinkercell::AddCurveSegmentCommand::~AddCurveSegmentCommand ( ) [virtual]

destructor. deletes all control points that do not belong a scene

Definition at line 3863 of file UndoCommands.cpp.


Member Function Documentation

void Tinkercell::AddCurveSegmentCommand::redo ( )

Adds a new control point. Control points were set in the constructor.

Parameters:
void
Returns:
void

Definition at line 3825 of file UndoCommands.cpp.

Here is the call graph for this function:

void Tinkercell::AddCurveSegmentCommand::undo ( )

Remove new control points. Control points were set in the constructor.

Parameters:
void
Returns:
void

Definition at line 3843 of file UndoCommands.cpp.

Here is the call graph for this function:


Member Data Documentation

graphics item to which control points were added

Definition at line 822 of file UndoCommands.h.

vector of control points that were added

Definition at line 824 of file UndoCommands.h.

graphics scene to which control points were added

Definition at line 820 of file UndoCommands.h.

the poisition(s) at which the control point vectors were added

Definition at line 826 of file UndoCommands.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines