Interface IShowProperty
- Namespace
- CADability.UserInterface
- Assembly
- CADability.dll
Objects that implement this interface can be displayed
public interface IShowProperty
Properties
EntryType
Returns the type of the entry, see ShowPropertyEntryType.
ShowPropertyEntryType EntryType { get; }
Property Value
HelpLink
Returns the help link for the help control.
string HelpLink { get; }
Property Value
Hidden
If an IShowProperty object is hidden, it will not appear in the TreeView of the control center. Most Properties are not hidden by default.
bool Hidden { get; set; }
Property Value
InfoText
Returns the text for the tooltip to display when the mouse cursor rests on the label.
string InfoText { get; }
Property Value
IsSelected
Whether this entry is the selected entry of its property page. Setting it to true selects the entry (it must be visible), setting it to false unselects it when it is the selected entry. The hotspots of the editable properties forward their selection state (IsSelected) to this property.
bool IsSelected { get; set; }
Property Value
LabelText
Returns the label text, which is usually displayed on the left side of the control.
string LabelText { get; }
Property Value
LabelType
Returns the type of the label, see ShowPropertyLabelFlags.
ShowPropertyLabelFlags LabelType { get; }
Property Value
OwnerDrawHeight
Returns the height of this entry if it is ownerdrawn.
int OwnerDrawHeight { get; }
Property Value
ReadOnly
If an IShowProperty object is read only, its value should be fixed. The subProperties should also be read only.
bool ReadOnly { get; set; }
Property Value
SubEntries
Returns the array of subentries to this entry.
IShowProperty[] SubEntries { get; }
Property Value
SubEntriesCount
Returns the number of subentries if any or 0 if none.
int SubEntriesCount { get; }
Property Value
Methods
Added(IPropertyTreeView)
Called when the entry was added to the control center or to a parent entry. The parameter represents the tree view object to which the entry was added. Each Added is later matched by a call to Removed(IPropertyTreeView).
void Added(IPropertyTreeView propertyTreeView)
Parameters
propertyTreeViewIPropertyTreeViewthe tree view
ChildSelected(IShowProperty)
Called when a child entry of this entry was selected.
void ChildSelected(IShowProperty theSelectedChild)
Parameters
theSelectedChildIShowProperty
LabelChanged(string)
Will be called when the text of a label changed because it was edited by the user. Will only be used if Editableis specified in the LabelType property.
void LabelChanged(string NewText)
Parameters
NewTextstringthe new text
OnEnterPressed()
Alt+Enter was pressed in the controlcenter while this entry was selected
void OnEnterPressed()
OnVisibilityChanged(bool)
Notification that the entry became visible or invisible in the control center, e.g. because its tab page was brought to the front or hidden. The current property page does not send this notification.
void OnVisibilityChanged(bool isVisible)
Parameters
isVisiblebooltrue: the entry is now visible, false: it is now hidden
Opened(bool)
Notifies the item that its subitems will be shown (IsOpen==true) or that the treeview collapses the subitems (IsOpen==false). The Item should fire the StateChangedEvent event with the appropriate parameters.
void Opened(bool IsOpen)
Parameters
IsOpenboolTreeview was opened or collpsed
Refresh()
Forces the entry to refresh its contents
void Refresh()
Removed(IPropertyTreeView)
Matches the calls to Added(IPropertyTreeView). A good place to disconnect events and free resources.
void Removed(IPropertyTreeView propertyTreeView)
Parameters
propertyTreeViewIPropertyTreeView
Select()
Forces this item to be selected in the treeview. The item must be visible.
void Select()
Selected()
Called whent the entry was selected.
void Selected()
SetFocus()
Will be called when the entry got the focus.
void SetFocus()
SetTabIndex(ref int)
Do not use anymore.
void SetTabIndex(ref int TabIndex)
Parameters
TabIndexint
ShowOpen(bool)
Opens this item to show the subentries of this item in the treeview, that contains this IShowProperty object. respectively closes or collapses this item to hide the subentries.
void ShowOpen(bool open)
Parameters
openbooltrue: open, false: collapse
UnSelected()
Called whent the entry was unselected.
void UnSelected()
Events
StateChangedEvent
Event that is fired when the state of this entry changed, e.g. the entry was selected.
event StateChangedDelegate StateChangedEvent