|
bool | ProcessEvent (wxEvent &event) |
| events recieved from controller processed here More...
|
|
void | SetEvtHandler (a2dObject *handler) |
| to reroute events to this event handler
|
|
a2dObject * | GetEventHandler () |
|
| a2dBaseTool (a2dToolContr *controller, const a2dMenuIdItem &initiatingMenuId=CmdMenu_NoMenu()) |
| construct a new tool for the given controller.
|
|
| a2dBaseTool (const a2dBaseTool &other, CloneOptions options, a2dRefMap *refs) |
| constructor initializing partly from other tool
|
|
virtual | ~a2dBaseTool () |
| destructor
|
|
a2dBaseTool * | TClone (CloneOptions options, a2dRefMap *refs=NULL) |
|
virtual wxString | GetToolString () const |
|
virtual bool | StartTool (a2dBaseTool *currenttool) |
| called to initiate while pushing tool to toolcontroller More...
|
|
void | SetOneShot () |
| Only one action of the tool, after that it will ask the controller to stop this tool.
|
|
virtual bool | ZoomSave ()=0 |
| Is Zooming while the tool is busy Save. More...
|
|
virtual bool | AllowPop () |
| tells if a tool can be poped from the stack. More...
|
|
void | StopTool (bool abort=false) |
| call to stop a tool, internal and external. More...
|
|
bool | GetStopTool () |
| checked by controller to see if the tool needs to be stopped e.g. after a oneshot. More...
|
|
bool | GetActive () |
| is the tool active? More...
|
|
virtual void | SetActive (bool active=true) |
| set the tool active or inactive. More...
|
|
bool | GetBusy () |
| Check if the tool is busy editing a distinct object */. More...
|
|
virtual bool | EnterBusyMode () |
| Called when the user selects a distinct object for editing */. More...
|
|
virtual bool | EnterBusyModeNoGroup () |
|
virtual void | FinishBusyMode (bool closeCommandGroup=true) |
| Called when the user finishes editing a distinct object */. More...
|
|
virtual void | AbortBusyMode () |
| Called when the user aborts editing a distinct object */. More...
|
|
void | SetFill (const a2dFill &fill) |
| set fill if used inside a tool
|
|
const a2dFill & | GetFill () const |
| get the current fill More...
|
|
void | SetStroke (const a2dStroke &stroke) |
| set stroke if used inside a tool
|
|
const a2dStroke & | GetStroke () const |
| get the current stroke More...
|
|
void | SetLayer (wxUint16 layer) |
| layer set for the object that is drawn using a tool
|
|
wxUint16 | GetLayer () |
| layer set for new objects.
|
|
void | SetShowAnotation (bool show) |
| when true anotation will be shown, if used inside a tool More...
|
|
void | SetAnotationFont (const wxFont &font) |
| font to use for anotation
|
|
void | SetCursorType (const wxCursor &cursor) |
| Sets cursor which the tool should use when started. More...
|
|
void | SetBusyCursorType (const wxCursor &cursor) |
| Sets cursor which the tool should use when busy. More...
|
|
wxCursor | GetCursorType () |
| what cursor is used when tool is started
|
|
wxCursor | GetBusyCursorType () |
| what cursor is used when tool is busy
|
|
virtual void | SetMode (int mode) |
| general integer to set operation modes for a tool (e.g the way it draws) More...
|
|
int | GetMode () |
| can be used to modify the behaviour of the derived tool. More...
|
|
void | SetPending (bool pending=true) |
| a tool is set pending when it needs to be redrawn.
|
|
bool | GetPending () |
| return if the tool is set pending for redraw.
|
|
virtual void | Render () |
| render the tool chain More...
|
|
a2dToolContr * | GetToolController () |
| to get the tool controller to which this tool is attached.
|
|
a2dDrawingPart * | GetDrawingPart () |
| Access to the tool controllers drawer.
|
|
a2dDrawer2D * | GetDrawer2D () |
| Access to the tool controllers drawers drawer2d.
|
|
wxWindow * | GetDisplayWindow () |
| Access to the tool controllers drawers canvas.
|
|
a2dDrawing * | GetDrawing () |
| Returns a pointer to the drawing.
|
|
a2dCanvasCommandProcessor * | GetCanvasCommandProcessor () |
| Returns a pointer to the command processor associated with this document.
|
|
double | GetHitMargin () |
|
virtual void | OpenCommandGroup (bool restart) |
| called when starting an editing operation (e.g. on mouse down) More...
|
|
virtual void | OpenCommandGroupNamed (const wxString &name) |
| called when starting an editing operation with another than the default name
|
|
virtual void | CloseCommandGroup () |
| called when ending an editing operation (e.g. mouse up)
|
|
virtual wxString | GetCommandGroupName () |
| return the command group name for commands of a derived class More...
|
|
a2dCommandGroup * | GetCommandgroup () |
| return the command group that is open else NULL.
|
|
wxMenu * | GetMousePopupMenu () |
| to get the current mouse menu of the tool More...
|
|
void | SetMousePopupMenu (wxMenu *mousemenu) |
| to set the current mouse menu of the tool More...
|
|
a2dCanvasObject * | GetParentObject () |
| parent object relative to which the actions take place. More...
|
|
void | AddEditobject (a2dCanvasObject *object) |
| Add an editcopy object to the tool/document.
|
|
void | RemoveEditobject (a2dCanvasObject *object) |
| Remove an editcopy object to the tool/document.
|
|
void | AddDecorationObject (a2dCanvasObject *object) |
| Add a decoration object to be rendered by the tool. More...
|
|
void | RemoveAllDecorations () |
| remove all object that were added as decorations.
|
|
void | SetIgnorePendingObjects (bool onoff) |
| Switches ignorance of pending objects on and off. More...
|
|
bool | GetIgnorePendingObjects () |
| get setting of ignore pending objects /sa GetUpdatesPending()
|
|
a2dCorridor & | GetCorridor () |
| get reference to the corridor list
|
|
void | SetCorridor (const a2dCorridor &corridor) |
| set a corridor from a list of objects
|
|
void | SetContourWidth (double width) |
|
double | GetContourWidth () const |
| get the Contour width of the shape
|
|
void | ResetContext () |
| context like corridor and parentobject are reset
|
|
virtual bool | RotateObject90LeftRight (bool right) |
| rotate object of first tool on the stack, when appropriate.
|
|
void | SetIsEditTool (bool isEditTool) |
|
bool | GetIsEditTool () |
|
void | SetInitiatingMenuId (const a2dMenuIdItem &initiatingMenuId) |
|
const a2dMenuIdItem & | GetInitiatingMenuId () |
|
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 a2dObject * | SetNonDynamic () |
| 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...
|
|
a2dObject * | Clone (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 () |
|
a2dNamedProperty * | GetProperty (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 a2dNamedProperty * | FindProperty (const a2dPropertyId *id, a2dPropertyId::Flags flags=a2dPropertyId::flag_none) |
| Find a dynamic property with given id in the property list. More...
|
|
virtual const a2dNamedProperty * | FindProperty (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 a2dNamedPropertyList & | GetPropertyList () 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...
|
|
The a2dBaseTool is used to derive tools from that are controlled by.
a a2dToolContr derived class.
The basetool does not implement default behaviour for events in many cases, instead it is possible to set m_eventHandler to take care of action which are the same for a set of tools. a2dBaseTool::ProcessEvent() first redirect incoming events to m_eventHandler, and if not handled there it goes to the tools its own event handler.
- wxEventType sig_toolPushed sent from controller just after this tool is pushed, the tool is the first on the stack. This event can be used to have a master tool push extra tools.
- a2dComEvent( GetFirstTool(), poped, &sig_toolPoped ) sent from controller to tool when some other tool is poped from the tool stack. This can be used to control style settings for this tool, based on the last active tool on the top of the tool stack. E.g When style is changed when editing a primitive, the tool that was used to draw this primitive and started the editing tool, normally wants to take over this style. This function is called just after a tool was poped from the stack.
- a2dComEvent( GetFirstTool(), poped, &sig_toolBeforePoped ) sent from controller when a new tool is pushed, while the current tool is on the stack. This can be used to control halting or stopping of the current tool. E.g. When a tool allows Zooming while busy, you halt the tool here, but while the new tool is totataly independent, one may terminate the current tool action and close its command group. This function is called just before the new tool is indeed pushed on the stack.
- See Also
- a2dToolContr
Definition at line 379 of file tools.h.