Table of Contents

Class ConstructAction.PlaneInput

Namespace
CADability.Actions
Assembly
CADability.dll

Defines an input object for an action derived from ConstructAction. This input object expects the input of a plane. The value may be either entered on the keyboard or by moving the mouse. There is always a base plane which is by default the drawing plane. The mouse input is defines a plane which is parallel to the base plane and contains the mouse point (snapping is applied) Pressing enter or TAB or clicking the mouse proceeds to the next input object.

public class ConstructAction.PlaneInput : ConstructAction.InputObject, ICommandHandler
Inheritance
ConstructAction.PlaneInput
Implements
Inherited Members

Constructors

PlaneInput(string)

Constructs a PlaneInput object.

public PlaneInput(string resourceId)

Parameters

resourceId string

the resource id to specify a string from the StringTable.

PlaneInput(string, Plane)

Constructs a PlaneInput object with a initial value.

public PlaneInput(string resourceId, Plane basePlane)

Parameters

resourceId string

the resource id to specify a string from the StringTable.

basePlane Plane

the base plane

Properties

ForwardMouseInputTo

Mouse input should be forwarded to another input object and only processed by this input, when the other input object is fixed.

public object ForwardMouseInputTo { get; set; }

Property Value

object

ReadOnly

true: this input field does not accept user input, false: normal input field that requires user input

public override bool ReadOnly { get; set; }

Property Value

bool

Methods

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 override void AdjustHighlight()

ForceValue(Plane)

Forces the input object to the specified value. The input filed is updated accordingly.

public void ForceValue(Plane val)

Parameters

val Plane

the value to set

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 override void SetError(string errorMessage)

Parameters

errorMessage string

The text to display, or an empty string to clear the error

Events

GetPlaneEvent

Provide a method here, if the length not only depends from this input, but is also modified by other means.

public event ConstructAction.PlaneInput.GetPlaneDelegate GetPlaneEvent

Event Type

ConstructAction.PlaneInput.GetPlaneDelegate

MouseClickEvent

Event that is fired when a mousclick happens and this input has the focus.

public event ConstructAction.MouseClickDelegate MouseClickEvent

Event Type

ConstructAction.MouseClickDelegate

SetPlaneEvent

Provide a method here to get the result of this input (and modify your object)

public event ConstructAction.PlaneInput.SetPlaneDelegate SetPlaneEvent

Event Type

ConstructAction.PlaneInput.SetPlaneDelegate