Table of Contents

Class MultiGeoPointProperty

Namespace
CADability.UserInterface
Assembly
CADability.dll

A IShowProperty implementation that displays a list of GeoPoints. The communication with the object that owns that list is performed via a IIndexedGeoPoint interface, which must be provided in the constructor. This show property lets the user add and remove GeoPoints to or from the list or modify existing GeoPoints in the list.

public class MultiGeoPointProperty : PropertyEntryImpl, IPropertyEntry, IShowProperty
Inheritance
MultiGeoPointProperty
Implements
Inherited Members

Constructors

MultiGeoPointProperty(IIndexedGeoPoint, string, IFrame)

Creates a MultiGeoPointProperty. The parameter "controlledObject" provides the owner of the list.

public MultiGeoPointProperty(IIndexedGeoPoint controlledObject, string resourceId, IFrame frame)

Parameters

controlledObject IIndexedGeoPoint

owner of the list

resourceId string

the resource id to specify a string from the StringTable. ResourceId+".Label": the Label left of the edit box. ResourceId+".ShortInfo": a short tooltip text ResourceId+"DetailedInfo": a longer tooltip text.

frame IFrame

The IFrame this property belongs to, used to access the project

Fields

GetInsertionPointEvent

When a point is about to be inserted this property needs some initial value. The default initial value is the same point as the first/last point, when inserted before the first or after the last point, and the middle point of the interval where the point is to be inserted. If you wish another behavior add a handler to this event and return the appropriate point.

public MultiGeoPointProperty.GetInsertionPointDelegate GetInsertionPointEvent

Field Value

MultiGeoPointProperty.GetInsertionPointDelegate

Properties

DisplayZComponent

Whether the z coordinate of the points is displayed. Initialized from the setting "Formatting.Coordinate.ZValue" and passed on to the GeoPointProperty sub entries when they are created.

public bool DisplayZComponent { get; set; }

Property Value

bool

Flags

Implementation of Flags: the derived class states what the entry is and what the user can do with it. The flags must match the overridden members, e.g. HasSubEntries requires SubItems, ValueEditable requires Value and EndEdit(bool, bool, string), DropDown requires GetDropDownList() and ListBoxSelected(int).

public override PropertyEntryType Flags { get; }

Property Value

PropertyEntryType

PrependContextMenue

Additional menu items which are inserted at the beginning of the context menu of each point entry (passed on as PrependContextMenu to the sub entries when they are created), or null.

public MenuWithHandler[] PrependContextMenue { get; set; }

Property Value

MenuWithHandler[]

SubItems

Must be overridden, when Flags contains PropertyEntryType.HasSubEntries. See SubItems

public override IPropertyEntry[] SubItems { get; }

Property Value

IPropertyEntry[]

Methods

Added(IPropertyPage)

Implementation of Added(IPropertyPage): memorizes the page in propertyPage and reports Added. Override it to subscribe to events while the entry is displayed, and call the base implementation.

public override void Added(IPropertyPage propertyPage)

Parameters

propertyPage IPropertyPage

Append(GeoPoint)

Appends a point to the list of points

public void Append(GeoPoint initialValue)

Parameters

initialValue GeoPoint

initial value of the new point

Refresh()

Asks the property page to redisplay this entry (see Refresh(IPropertyEntry)); call it after the label, the value or the sub entries changed. Does nothing while the entry is not shown.

public override void Refresh()

Refresh(int)

Refreshes the display of the point with the given index.

public void Refresh(int index)

Parameters

index int

index of point to refresh

SetFocusToIndex(int)

Selects the sub entry of the point with the given index in the property page, provided this entry is displayed and expanded. The construction actions use it to move the focus to the point currently being entered.

public void SetFocusToIndex(int index)

Parameters

index int

Index of the point

ShowOpen(bool)

Opens the subentries in the treeview.

public void ShowOpen(bool open)

Parameters

open bool

true: open, false: close

Events

GeoPointSelectionChangedEvent

Provide a method here if you need to be notified about when the selection of the points in the subtree changed

public event GeoPointProperty.SelectionChangedDelegate GeoPointSelectionChangedEvent

Event Type

GeoPointProperty.SelectionChangedDelegate

ModifyWithMouseEvent

Provide a method here if you need to notified about modification of any point in this list with the mouse

public event MultiGeoPointProperty.ModifyWithMouseIndexDelegate ModifyWithMouseEvent

Event Type

MultiGeoPointProperty.ModifyWithMouseIndexDelegate