wxArt2D
Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members

a command processor specially designed to work with a a2dCanvasDocument More...

#include <drawing.h>

Inheritance diagram for a2dCanvasCommandProcessor:
Inheritance graph
[legend]
Collaboration diagram for a2dCanvasCommandProcessor:
Collaboration graph
[legend]

Public Member Functions

 a2dCanvasCommandProcessor (a2dDrawing *drawing, int maxCommands=-1)
 
void OnUpdateMenu (wxUpdateUIEvent &event)
 
void OnPushToolUpdateMenu (wxUpdateUIEvent &event)
 
void OnBusyBegin (a2dCommandProcessorEvent &event)
 do this at command start
 
void OnBusyEnd (a2dCommandProcessorEvent &event)
 do this at command end
 
void OnMenu (wxCommandEvent &event)
 All menu's a2dMenuIdItem used can be intercepted here.
 
void OnPushToolMenu (wxCommandEvent &event)
 All menu's a2dMenuIdItem used can be intercepted here.
 
bool Print (wxUint16 printWhat)
 
bool Preview (wxUint16 printWhat)
 
wxString AskFile (const wxString &message, const wxString &default_path="", const wxString &default_filename="", const wxString &default_extension="", const wxString &wildcard="*.*", int flags=0, int x=-1, int y=-1)
 ask for a file using a file selector. More...
 
void SetUndo (bool withUndo)
 set undo storage or not
 
bool GetUndo ()
 get undo storage setting
 
virtual bool Submit (a2dCommand *command, bool storeIt=true)
 
virtual bool Undo ()
 Undo one command or command group.
 
virtual bool Redo ()
 Redo one command or command group.
 
virtual bool SubmitMultiple (a2dCommand *command, a2dCanvasObjectList *objects, bool storeIt=true)
 submit a command template with multiple objects
 
wxPageSetupDialogData * GetPageSetupData (void) const
 
void SetPageSetupData (const wxPageSetupDialogData &pageSetupData)
 
void SetPageSetupData (wxPageSetupDialogData *pageSetupData)
 
void Refresh ()
 full update of drawing
 
void DeselectAll ()
 
a2dDrawingPartGetActiveDrawingPart ()
 
bool IsShownToolDlg ()
 
bool IsShowna2dStyleDialog ()
 
bool IsShownLayerPropertiesDialog ()
 
bool IsShownLayerOrderDialog ()
 
bool IsShownIdentifyDialog ()
 
bool IsShowna2dSnapSettings ()
 
bool IsShowna2dCoordinateEntry ()
 
bool IsShowna2dMeasureDlg ()
 
bool IsShowna2dPathSettings ()
 
bool IsShowna2dSettings ()
 
bool IsShowna2dTransDlg ()
 
bool IsShownStructureDlg ()
 
bool ShowDlgStyle (bool onOff)
 show style dialog or not, return true of changed from previous state
 
bool SaveLayers (const wxFileName &fileName)
 
bool LoadLayers (const wxFileName &fileName)
 
virtual bool PushToolDragNew (a2dCanvasObject *newObject, const a2dMenuIdItem &initiatingMenuId, bool dragCenter=true)
 
virtual bool PushTool (const a2dCommandId &whichTool, bool shiftadd=false, bool oneshot=false)
 
a2dBaseToolPopTool ()
 
bool SetParentObject (a2dCanvasObject *obj=0)
 set top object available in the a2dCanvasDocument to be used for adding other objects More...
 
a2dCanvasObjectGetParentObject ()
 
a2dCanvasObjectGetCurrentCanvasObject ()
 get the current canvas object to add to parent as child
 
void SetCurrentCanvasObject (a2dCanvasObject *currentcanvasobject, bool takeOverProperties=true)
 set the current canvas object, which gets the change in style etc More...
 
a2dCanvasObjectAddCurrent (a2dCanvasObject *objectToAdd, bool withUndo=false, a2dPropertyIdList *setStyles=NULL, a2dCanvasObject *parentObject=NULL)
 add the current canvas object to parent as child More...
 
a2dCanvasObjectAdd_a2dCanvasObject (double x=0, double y=0)
 add specific object
 
a2dCanvasObjectReferenceAdd_a2dCanvasObjectReference (double x, double y, a2dCanvasObject *obj)
 add specific object
 
a2dOriginAdd_a2dOrigin (double w, double h)
 add specific object
 
a2dHandleAdd_a2dHandle (double xc, double yc, int w, int h, double angle=0, int radius=0)
 add specific object
 
a2dRectCAdd_a2dRectC (double xc, double yc, double w, double h, double angle=0, double radius=0)
 add specific object
 
a2dArrowAdd_a2dArrow (double xt, double yt, double l1, double l2, double b, bool spline=false)
 add specific object
 
a2dRectAdd_a2dRect (double x, double y, double w, double h, double radius=0)
 add specific object
 
a2dCircleAdd_a2dCircle (double x, double y, double radius)
 add specific object
 
a2dEllipseAdd_a2dEllipse (double xc, double yc, double width, double height)
 add specific object
 
a2dEllipticArcAdd_a2dEllipticArc (double xc, double yc, double width, double height, double start, double end)
 add specific object
 
a2dArcAdd_a2dArc (double xc, double yc, double radius, double start, double end)
 add specific object
 
a2dSLineAdd_a2dSLine (double x1, double y1, double x2, double y2)
 add specific object
 
a2dEndsLineAdd_a2dEndsLine (double x1, double y1, double x2, double y2)
 add specific object
 
a2dImageAdd_a2dImage (const wxImage &image, double xc, double yc, double w, double h)
 add specific object
 
a2dImageAdd_a2dImage (const wxString &imagefile, wxBitmapType type, double xc, double yc, double w, double h)
 add specific object
 
a2dTextAdd_a2dText (const wxString &text, double x, double y, double angle, const a2dFont &font)
 add specific object
 
a2dPolygonLAdd_a2dPolygonL (a2dVertexList *points, bool spline=false)
 add specific object
 
a2dPolylineLAdd_a2dPolylineL (a2dVertexList *points, bool spline=false)
 add specific object
 
bool Add_Point (double x, double y)
 add a point to the current a2dCanvasObject
 
bool Move_Point (int index, double x, double y)
 add a point to the current a2dCanvasObject
 
void SetZoomFactor (double zoomfactor)
 
double GetZoomFactor ()
 
bool Zoom (double x1, double y1, double x2, double y2, bool upp)
 Zoom to this rectangle, or Upp at x1, y1.
 
bool ZoomRealSize (double scaleFromRealSize, bool selected)
 Zoom to a real size or a factor of it. More...
 
bool ZoomOut ()
 
bool Select (double x1, double y1, double x2, double y2)
 select this area
 
bool DeSelect (double x1, double y1, double x2, double y2)
 de select this area
 
void DeleteDlgs ()
 
void OnEditProperties (a2dPropertyEditEvent &event)
 
a2dCanvasObjectListConvertToPolygons (a2dCanvasObject *canvasobject, bool transform)
 
a2dCanvasObjectListConvertToVpath (a2dCanvasObject *canvasobject, bool transform)
 
void ClearMeasurements ()
 
void AddMeasurement (double x, double y)
 
void SetRelativeStart (double x, double y)
 
bool InsertGroupRef ()
 
- Public Member Functions inherited from a2dCommandProcessor
 a2dCommandProcessor (int maxCommands=-1)
 Constructor. More...
 
virtual ~a2dCommandProcessor ()
 destructor
 
virtual void Store (a2dCommand *command)
 just store the command without executing it
 
virtual bool CanUndo () const
 Are there commands to undo and can they be undone ?
 
virtual bool CanRedo () const
 Are there commands to redo and can they be redone ?
 
virtual void Initialize ()
 Initialises the current command and menu strings.
 
virtual void SetMenuStrings ()
 does sent an event to update menu strings after a command
 
wxString GetUndoMenuLabel () const
 Gets the current Undo menu label.
 
wxString GetRedoMenuLabel () const
 Gets the current Undo menu label.
 
a2dCommandGetCurrentCommand () const
 command list access
 
int GetMaxCommands () const
 get the limit on number of commands to store
 
a2dCommandGroupGetRootGroup () const
 return top/startgroup
 
a2dCommandGroupGetCurrentGroup () const
 return current group
 
void SetCurrentGroup (a2dCommandGroup *group)
 set current group More...
 
virtual void ClearCommands ()
 remove all commands stored
 
const wxString & GetUndoAccelerator () const
 By default, the accelerators are "\tCtrl+Z" and "\tCtrl+Y".
 
const wxString & GetRedoAccelerator () const
 By default, the accelerators are "\tCtrl+Z" and "\tCtrl+Y".
 
void SetUndoAccelerator (const wxString &accel)
 By default, the accelerators are "\tCtrl+Z" and "\tCtrl+Y".
 
void SetRedoAccelerator (const wxString &accel)
 By default, the accelerators are "\tCtrl+Z" and "\tCtrl+Y".
 
virtual bool SetOrAddPropertyToObject (a2dObject *propRefObject, const wxString &name, const wxString &value=wxT(""), bool withUndo=true)
 set a named property to the given object More...
 
virtual bool SetOrAddPropertyToObject (a2dObject *propRefObject, a2dNamedProperty *property, bool withUndo=true)
 set a named property to the given object More...
 
a2dCommandGroupCommandGroupBegin (const wxString &name)
 Start a new command group. More...
 
void CommandGroupBegin (a2dCommandGroup *group)
 Start a new command group.
 
void CommandGroupEnd (a2dCommandGroup *group)
 End a command group.
 
bool SmrtPtrRelease ()
 
- Public Member Functions inherited from a2dObject
virtual bool ProcessEvent (wxEvent &event)
 
bool SearchDynamicEventTable (wxEvent &event)
 
void Connect (int winid, int lastId, int eventType, wxObjectEventFunction func, wxObject *userData=(wxObject *) NULL, wxEvtHandler *eventSink=(wxEvtHandler *) NULL)
 
bool Disconnect (int winid, int lastId, wxEventType eventType, wxObjectEventFunction func=NULL, wxObject *userData=(wxObject *) NULL, wxEvtHandler *eventSink=(wxEvtHandler *) NULL)
 
void ProcessConnectedEvent (wxEvent &event)
 wxCHECK_VERSION(2,9,0) More...
 
void ConnectEvent (wxEventType type, wxEvtHandler *eventSink)
 
bool DisconnectEvent (wxEventType type, wxEvtHandler *eventSink)
 
bool DisconnectEventAll (wxEvtHandler *eventSink)
 Remove all dynamic events in classA, going to classB (eventSink) More...
 
 a2dObject ()
 constructor
 
virtual ~a2dObject ()
 destructor
 
void operator= (const a2dObject &other)
 assignment operator
 
int GetOwnedBy ()
 like it to be protected, but this does not work with wxList macros More...
 
virtual a2dObjectSetNonDynamic ()
 Call to mark this object as non-dynamic (static/local/auto) More...
 
void CheckReferences ()
 Check zero reference count and delete if count is 0. More...
 
a2dObjectClone (CloneOptions options, a2dRefMap *refs=NULL) const
 create an exact copy of this property
 
 a2dObject (const a2dObject &other, CloneOptions options, a2dRefMap *refs)
 
virtual wxString GetName () const
 Returns the name of this object, if no name is given the internal id will be returned. More...
 
virtual void SetName (const wxString &name)
 Creates the a2dStringProperty PROPID_Name. More...
 
virtual bool IsTemporary_DontSave () const
 Check if this is a temporary object, which should not be saved.
 
void SaveAsDocument (a2dIOHandlerXmlSerOut &out)
 Save this object and all below as an XML document. More...
 
virtual void Save (wxObject *parent, a2dIOHandlerXmlSerOut &out, a2dObjectList *towrite)
 write all needed to an XML type of file called the CVG format More...
 
void LoadFromDocument (a2dIOHandlerXmlSerIn &parser)
 Load this object and all below from an XML document. More...
 
virtual void Load (wxObject *parent, a2dIOHandlerXmlSerIn &parser)
 load object from CVG file More...
 
wxInt64 GetUniqueSerializationId () const
 return a unique id for this object More...
 
virtual bool AlwaysWriteSerializationId () const
 If true, always write an id. More...
 
virtual bool LinkReference (a2dObject *other)
 link a reference in the object to the given value More...
 
virtual void ResolveInform ()
 inform an object that reference resolution was done More...
 
void Walker (wxObject *parent, a2dWalkerIOHandler &handler)
 This is used to recursively walk through an object tree.
 
void SetCheck (bool check)
 general flag use at will. More...
 
bool GetCheck () const
 general flag use at will.
 
void SetRelease (bool value)
 set release flag More...
 
bool GetRelease () const
 get release flag More...
 
a2dAutoZeroPtr< a2dObject > ** GetAutoZeroPtrList ()
 return the list head pointer for autozero pointers to this object More...
 
 DECLARE_PROPERTIES ()
 
a2dNamedPropertyGetProperty (const a2dPropertyId *propertyId, a2dPropertyId::Flags flags=a2dPropertyId::flag_none) const
 get property on this object More...
 
void SetProperty (a2dNamedProperty *propertyHolder, a2dPropertyId::SetFlags flags=a2dPropertyId::set_none)
 Set the property to the this object. More...
 
void SetProperty (const a2dNamedProperty &propertyHolder, a2dPropertyId::SetFlags flags=a2dPropertyId::set_none)
 Set the property to the this object and if enabled, to all childs and object members. More...
 
virtual a2dNamedPropertyFindProperty (const a2dPropertyId *id, a2dPropertyId::Flags flags=a2dPropertyId::flag_none)
 Find a dynamic property with given id in the property list. More...
 
virtual const a2dNamedPropertyFindProperty (const a2dPropertyId *id, a2dPropertyId::Flags flags=a2dPropertyId::flag_none) const
 Find a dynamic property with given id in the property list. More...
 
virtual bool HasProperty (const a2dPropertyId *id, const wxString &stringvalue=wxEmptyString) const
 Check if the object has a property with given id and string representation. More...
 
virtual void OnPropertyChanged (const a2dPropertyId *id)
 This function is called after a property changed. More...
 
virtual bool EditProperties (const a2dPropertyId *id, bool withUndo=true)
 edit properties of the object More...
 
void TakeOverProperties (a2dObject *from, a2dPropertyIdList *listOfIds)
 Properties in the id list are taken from the given object, en set to this. More...
 
wxURI GetURI () const
 quick way to get to PROPID_URI property More...
 
void SetURI (const wxURI &url)
 quickly set a property PROPID_URI More...
 
const a2dNamedPropertyListGetPropertyList () const
 Get the Property List. More...
 
bool HasDynamicProperties () const
 test if there are dynamic properties in the m_propertylist
 
virtual bool RemoveProperty (const a2dPropertyId *id, bool all=true)
 This function is called by a2dPropertyId to remove a property from the list. More...
 
void RemoveTemporaryProperties ()
 remove all temporary properties
 
virtual bool AddProperty (a2dNamedProperty *property)
 This function is called by a2dPropertyId to add a property to the list. More...
 

Static Public Member Functions

static bool StaticProcessEvent (wxUpdateUIEvent &event)
 
static void DefaultOnUpdateMenu (wxUpdateUIEvent &event)
 

Public Attributes

a2dCanvasObjectm_parent
 sets current style object to current canvas object More...
 
a2dCanvasObjectm_currentobject
 last added object
 
bool m_AppendOrPrepend
 add in front of parent childs or add end
 
a2dDrawingm_drawing
 
bool m_withUndo
 if set, for commands which can undo, will be submitted like that.
 
double m_meas_x
 
double m_meas_y
 
double m_zoomfactor
 
wxPageSetupDialogData * m_pageSetupData
 this is the global printer page setup data for printer
 

Static Public Attributes

static const a2dCommandId COMID_InsertGroupRef
 
static const a2dCommandId COMID_ShowDlgLayers
 
static const a2dCommandId COMID_ShowDlgLayersDocument
 
static const a2dCommandId COMID_ShowDlgLayersGlobal
 
static const a2dCommandId COMID_ShowDlgLayerOrderDocument
 
static const a2dCommandId COMID_ShowDlgLayerOrderGlobal
 
static const a2dCommandId COMID_ShowDlgTools
 
static const a2dCommandId COMID_ShowDlgStyle
 
static const a2dCommandId COMID_ShowDlgSnap
 
static const a2dCommandId COMID_ShowDlgGroups
 
static const a2dCommandId COMID_ShowDlgIdentify
 
static const a2dCommandId COMID_ShowDlgCoordEntry
 
static const a2dCommandId COMID_ShowDlgMeasure
 
static const a2dCommandId COMID_ShowDlgStructure
 
static const a2dCommandId COMID_ShowDlgPathSettings
 
static const a2dCommandId COMID_ShowDlgSettings
 
static const a2dCommandId COMID_ShowDlgTrans
 
static const a2dCommandId COMID_ShowDlgPropEdit
 
static const a2dCommandId COMID_PopTool
 
static const a2dSignal sig_ClearMeasurements = wxNewId()
 
static const a2dSignal sig_AddMeasurement = wxNewId()
 
static const a2dSignal sig_SetRelativeStart = wxNewId()
 
static ToolDlgm_tooldlg = NULL
 
static a2dStyleDialogm_styledlg = NULL
 
static LayerPropertiesDialogm_layersdlg = NULL
 
static a2dLayerOrderDlgm_layerOrderDlg = NULL
 
static IdentifyDialogm_identifyDlg = NULL
 
static a2dSnapSettingsm_snapSettings = NULL
 
static a2dCoordinateEntrym_coordEntry = NULL
 
static a2dMeasureDlgm_measure = NULL
 
static a2dPathSettingsm_pathsettings = NULL
 
static a2dSettingsm_settings = NULL
 
static a2dTransDlgm_transset = NULL
 
static a2dPropertyEditorDlgm_propEdit = NULL
 
static a2dCanvasObjectsDialogm_structDlg = NULL
 
static a2dLayerDlgm_layerChooseDlg = NULL
 
- Static Public Attributes inherited from a2dObject
static a2dPropertyIdBoolPROPID_Check = NULL
 used for linking multiple referenced objects when serializing
 
static a2dPropertyIdUriPROPID_URI = NULL
 attach an URL to the object
 
static a2dPropertyIdStringPROPID_Name = NULL
 Name property, to return name of this object.
 
static a2dPropertyIdVoidPtrPROPID_autozeroptrlist = NULL
 
static const a2dSignal sm_Edit_properties = wxNewId()
 edit properties event, see EditProperties()
 

Additional Inherited Members

- Public Types inherited from a2dObject
enum  CloneOptions {
  clone_members = 0x00000001, clone_properties = 0x00000002, clone_childs = 0x00000004, clone_unused = 0x00000008,
  clone_setoriginal = 0x00000010, clone_seteditcopy = 0x00000020, clone_noReference = 0x00000040, clone_noCameleonRef = 0x00000080,
  clone_toDrag = 0x00000100, clone_flat = 0x00000000, clone_deep = clone_members | clone_properties | clone_childs
}
 options for cloning More...
 
typedef a2dAutoZeroPtr< a2dObjectTAutoZeroPtrListClass
 this is needed inside the smart pointer template code
 
- Protected Types inherited from a2dObject
enum  { refcount_nondynamic = 0x76543210 }
 special refcount value for non-dynamic objects
 
- Protected Member Functions inherited from a2dCommandProcessor
void SentBusyEvent (bool start, a2dCommand *command)
 
a2dCommandGroupFindActiveGroup ()
 find the currently active command group
 
void SetCurrentToLastActive ()
 Set the current command to the last command in the active group.
 
virtual bool DoPreCommand (a2dCommand &cmd)
 Called before doing the actual command.
 
virtual bool DoPostCommand (a2dCommand &cmd)
 Called after doing the actual command.
 
virtual bool DoCommand (a2dCommand &cmd)
 sents a a2dCommandProcessorEvent with id ::wxEVT_DO
 
virtual bool UndoCommand (a2dCommand &cmd)
 sents a a2dCommandProcessorEvent with id ::wxEVT_UNDO
 
virtual bool RedoCommand (a2dCommand &cmd)
 sents a a2dCommandProcessorEvent with id ::wxEVT_REDO
 
- Protected Member Functions inherited from a2dObject
virtual bool DoIgnoreIfNotMember (const a2dPropertyId *id) const
 used to decide if a property shall be ignored, if it is not a member More...
 
virtual void DoWalker (wxObject *parent, a2dWalkerIOHandler &handler)
 iterate over this object and its children More...
 
virtual void DoSave (wxObject *parent, a2dIOHandlerXmlSerOut &out, a2dXmlSer_flag xmlparts, a2dObjectList *towrite)
 Save settings.
 
virtual void DoLoad (wxObject *parent, a2dIOHandlerXmlSerIn &parser, a2dXmlSer_flag xmlparts)
 Load settings.
 
- Protected Attributes inherited from a2dCommandProcessor
wxUint32 m_maxNoCommands
 maximum number of commands to store
 
a2dSmrtPtr< a2dCommandGroupm_rootGroup
 this is the root of the command group tree
 
a2dSmrtPtr< a2dCommandGroupm_currentGroup
 this is the parent group of the current command ( which may be a group itself )
 
a2dCommandPtr m_currentCommand
 this is the tree-trace to the currently active command
 
wxString m_undoAccelerator
 associated undo accelerator attached to menu
 
wxString m_redoAccelerator
 associated redo accelerator
 
- Protected Attributes inherited from a2dObject
a2dNamedPropertyList m_propertylist
 properties
 
int m_refcount
 how many references to this object do exist
 
bool m_check: 1
 used for linking multiple referenced objects when serializing
 
bool m_release: 1
 when set object is treated as being deleted, and wil be deleted in idle time.
 
bool m_recursion_active: 1
 this is used as a recursion stopper
 
bool m_pendingDisconnects: 1
 
unsigned int m_iteratorCount
 
a2dAutoZeroPtr< a2dObject > * m_autozeroptrlist
 this is a list of all a2dAutoZeroPtr object pointing to this object
 

Detailed Description

a command processor specially designed to work with a a2dCanvasDocument

This command processor allows you to add object to the document and takes care of undo redo.

Definition at line 1046 of file drawing.h.

Member Function Documentation

a2dCanvasObject * a2dCanvasCommandProcessor::AddCurrent ( a2dCanvasObject objectToAdd,
bool  withUndo = false,
a2dPropertyIdList setStyles = NULL,
a2dCanvasObject parentObject = NULL 
)

add the current canvas object to parent as child

First the current style is to the currentobject, and then it is added to the document.

Parameters
objectToAddthis is the object to add to the current parentobject
withUndoif true a a2dCommand_AddObject will be used to have undo information
setStylesthe object added will get these styles that are currently set in the command processor
parentObjectwhen not NULL, this will become the current parent object.

Definition at line 6290 of file drawing.cpp.

wxString a2dCanvasCommandProcessor::AskFile ( const wxString &  message,
const wxString &  default_path = "",
const wxString &  default_filename = "",
const wxString &  default_extension = "",
const wxString &  wildcard = "*.*",
int  flags = 0,
int  x = -1,
int  y = -1 
)

ask for a file using a file selector.

If your path contains internal variables, they will be expanded.

Definition at line 6339 of file drawing.cpp.

a2dCanvasObjectList * a2dCanvasCommandProcessor::ConvertToPolygons ( a2dCanvasObject canvasobject,
bool  transform 
)

convert canvasobject to a list of polygons. But only for simple primitive objects. first a2dCanvasObject::GetAsCanvasVpaths() is used to convert to vector paths, and next the vector path is translated into polygons.

Definition at line 6226 of file drawing.cpp.

a2dCanvasObjectList * a2dCanvasCommandProcessor::ConvertToVpath ( a2dCanvasObject canvasobject,
bool  transform 
)

convert canvasobject to a list of Vpath. But only for simple primitive objects. first a2dCanvasObject::GetAsCanvasVpaths() is used to convert to vector paths,

Definition at line 6266 of file drawing.cpp.

a2dCanvasObject* a2dCanvasCommandProcessor::GetParentObject ( )
inline

return pointer of then current parent object

Returns
: pointer to the current object that is used for adding other objects to.

Definition at line 1195 of file drawing.h.

void a2dCanvasCommandProcessor::OnUpdateMenu ( wxUpdateUIEvent &  event)

todo when exactly depend on tools.

Definition at line 2291 of file drawing.cpp.

void a2dCanvasCommandProcessor::SetCurrentCanvasObject ( a2dCanvasObject currentcanvasobject,
bool  takeOverProperties = true 
)

set the current canvas object, which gets the change in style etc

The current object is the object that gets the settings made on the commandprocessor and that do influence a a2dCanvasObject. Normally this is already set when a new object is added via commands. You must use NULL to reset the current object to not in use.

When setting the current object, normally the object its properties are checked and the commandprocessor its internal chached properties or updated to that.

Parameters
currentcanvasobjectthe object to set current.
takeOverPropertieswhen true the internal chached properties are updated from the object.

Definition at line 6315 of file drawing.cpp.

bool a2dCanvasCommandProcessor::SetParentObject ( a2dCanvasObject obj = 0)

set top object available in the a2dCanvasDocument to be used for adding other objects

Parameters
obj,:pointer to object to set as new parent a2dCanvasObject
Remarks
the document will be searched to check if the object does exist, if not found, the rootobject of the document will be set as parent.
if obj is set to NULL, the rootobject of the document will be set.
Returns
if the object is found and set return is true

Definition at line 6434 of file drawing.cpp.

bool a2dCanvasCommandProcessor::Submit ( a2dCommand command,
bool  storeIt = true 
)
virtual

a2dDocumentCommand

Reimplemented from a2dCommandProcessor.

Definition at line 5966 of file drawing.cpp.

bool a2dCanvasCommandProcessor::ZoomRealSize ( double  scaleFromRealSize,
bool  selected 
)

Zoom to a real size or a factor of it.

Center of window is the fix point unless the slected flag is set, and there are selected objects, in which case it is the centre of the boundingbox of the selected objects.

Parameters
scaleFromRealSizeFactor from the real size the zoom will be.
selectedif set also look at selcted objects.

Definition at line 6139 of file drawing.cpp.

Member Data Documentation

a2dCanvasObject* a2dCanvasCommandProcessor::m_parent

sets current style object to current canvas object

For the property id's in the list, copy the current settings in the command processor to the current object.

Parameters
setStyleslit of property id which will be set if available in the command processor.current parent object to which new objects will be added as childs this is also the ShowObject of the Active a2dCanvasView when apropriate.

Definition at line 1344 of file drawing.h.


The documentation for this class was generated from the following files:
a2dCanvasCommandProcessor Class Reference -- Sun Oct 12 2014 17:04:29 -- Sun Oct 12 2014 -- 1.8.5 -- wxArt2D -- . -- Main Page Reference Documentation