Class ConstructAction.InputObject
- Namespace
- CADability.Actions
- Assembly
- CADability.dll
Common base class for input objects for the ConstructAction (see SetInput(params object[])
public abstract class ConstructAction.InputObject
- Inheritance
-
ConstructAction.InputObject
- Derived
- Inherited Members
Constructors
InputObject(string)
Constructor to set the resourceId for that input field
protected InputObject(string resourceId)
Parameters
resourceIdstring
Fields
ResourceId
The string id for several text strings: ResourceId+".Label": the Label left of the edit box. ResourceId+".ShortInfo": a short tooltip text ResourceId+"DetailedInfo": a longer tooltip text.
public string ResourceId
Field Value
constructAction
Back reference to the ConstructAction this input is used for.
protected ConstructAction constructAction
Field Value
Properties
Fixed
If true, there already was an input either from the keyboard or by a mouse click.
public bool Fixed { get; set; }
Property Value
HasHotspot
Internal!
protected virtual bool HasHotspot { get; }
Property Value
HotspotPosition
Internal!
protected virtual GeoPoint HotspotPosition { get; }
Property Value
Optional
If set to true, the user cannot modify this intput with the mouse. Default: false;
public virtual bool Optional { get; set; }
Property Value
ReadOnly
If set to true, the user cannot type in a value for this input. Default: false;
public virtual bool ReadOnly { get; set; }
Property Value
Methods
AcceptInput(bool)
Internal!
protected virtual bool AcceptInput(bool acceptOptional)
Parameters
acceptOptionalbool
Returns
- bool
Internal!
AdjustHighlight()
Called whenever ReadOnly, Optional or Fixed changes, so that the input can update the highlight of its entry in the property page: an input is highlighted while it still expects a value, i.e. while it is neither optional, fixed nor read-only. The default implementation does nothing; the concrete input objects override it.
protected virtual void AdjustHighlight()
Init(ConstructAction)
Internal!
protected virtual void Init(ConstructAction a)
Parameters
aConstructActiona
MouseLeft()
Internal!
protected virtual void MouseLeft()
OnActionDone()
Internal!
protected virtual void OnActionDone()
Refresh()
Internal!
protected virtual void Refresh()
SetError(string)
Shows errorMessage as an error on the entry of this input in the property page, e.g. when
the value entered by the user is not acceptable for the action. The default implementation does nothing; inputs
with an edit field forward the message to their property entry, inputs without one ignore it.
public virtual void SetError(string errorMessage)
Parameters
errorMessagestringThe text to display, or an empty string to clear the error