GuidEditBox Class
Represents an Guid
edit box.
public class GuidEditBox : PartEditBoxBase<Guid?>
- Inheritance:
- object Visual UIElement FrameworkElement Control PartEditBoxBase<Guid?> object
Constructors
GuidEditBox()
Initializes an instance of the GuidEditBox
class.
public GuidEditBox()
Properties
Format
Gets or sets the GUID format string.
public string Format { get; set; }
Property Value
- string:
The GUID format string. The default value is
"D"
.
NewGuidButtonToolTip
Gets or sets the tooltip for the new GUID button.
public object NewGuidButtonToolTip { get; set; }
Property Value
- object:
The tooltip for the new GUID button.
NewGuidCommand
Gets the ICommand that can be used to generate a new GUID.
public ICommand NewGuidCommand { get; }
Property Value
ResolvedFormat
Gets the resolved GUID format string.
Methods
ConvertToString(Guid?)
Converts the specified value to a string representation.
protected override string ConvertToString(Guid? valueToConvert)
Parameter | Type | Description |
---|---|---|
valueToConvert | Guid? | The value. |
Returns
- string:
The string representation of the specified value.
CreateIncrementalChangeRequest(IncrementalChangeRequestKind)
Creates an incremental change (spin) request.
protected override IncrementalChangeRequest<Guid?> CreateIncrementalChangeRequest(IncrementalChangeRequestKind kind)
Parameter | Type | Description |
---|---|---|
kind | IncrementalChangeRequestKind | The kind of request. |
Returns
- IncrementalChangeRequest<Guid?>:
The incremental change (spin) request that was created.
GenerateParts()
Generates the parts for the edit box.
protected override IList<IPart> GenerateParts()
Returns
IsValidValue(Guid?)
Returns whether the specified value is valid.
protected override bool IsValidValue(Guid? value)
Parameter | Type | Description |
---|---|---|
value | Guid? | The value to examine. |
Returns
- bool:
true
if the value is valid; otherwise,false
.
OnKeyDown(KeyEventArgs)
Occurs when a key is pressed.
protected override void OnKeyDown(KeyEventArgs e)
Parameter | Type | Description |
---|---|---|
e | KeyEventArgs | The KeyEventArgs that contains the event data. |
RaiseValueChangedEvent()
Raises the ValueChanged event.
protected override void RaiseValueChangedEvent()
ResetValue()
Resets the value to a default value.
protected override void ResetValue()
TryConvertFromString(string, bool, out Guid?)
Tries to convert the specified text to a value.
protected override bool TryConvertFromString(string textToConvert, bool canCoerce, out Guid? value)
Parameter | Type | Description |
---|---|---|
textToConvert | string | The text. |
canCoerce | bool | Whether the returned value should be coerced to fall within the allowed value range. |
value | Guid? | Returns the value for the specified text. |
Returns
- bool:
true
if the text was converted to a value successfully; otherwise,false
.
Events
ValueChanged
Occurs after the Value
property value changes.
Fields
FormatProperty
Identifies the Format dependency property. This field is read-only.
public static readonly DependencyProperty FormatProperty
NewGuidButtonToolTipProperty
Identifies the NewGuidButtonToolTip dependency property. This field is read-only.
public static readonly DependencyProperty NewGuidButtonToolTipProperty
ResolvedFormatProperty
Identifies the ResolvedFormat dependency property. This field is read-only.
public static readonly DependencyProperty ResolvedFormatProperty
Inherited Members
- PartEditBoxBase<Guid?>.ActivePartIndexProperty
- PartEditBoxBase<Guid?>.CommitTriggersProperty
- PartEditBoxBase<Guid?>.HasPopupProperty
- PartEditBoxBase<Guid?>.InlinesProperty
- PartEditBoxBase<Guid?>.InputScopeNameValueProperty
- PartEditBoxBase<Guid?>.IntermediateValueProperty
- PartEditBoxBase<Guid?>.IsArrowKeyPartNavigationEnabledProperty
- PartEditBoxBase<Guid?>.IsEditableProperty
- PartEditBoxBase<Guid?>.IsNullAllowedProperty
- PartEditBoxBase<Guid?>.IsPopupButtonVisibleProperty
- PartEditBoxBase<Guid?>.IsPopupOpenProperty
- PartEditBoxBase<Guid?>.IsReadOnlyProperty
- PartEditBoxBase<Guid?>.IsSpinnerVisibleProperty
- PartEditBoxBase<Guid?>.IsUndoEnabledProperty
- PartEditBoxBase<Guid?>.PlaceholderTextProperty
- PartEditBoxBase<Guid?>.PopupBackgroundProperty
- PartEditBoxBase<Guid?>.PopupBorderBrushProperty
- PartEditBoxBase<Guid?>.PopupPickerStyleProperty
- PartEditBoxBase<Guid?>.SpinWrappingProperty
- PartEditBoxBase<Guid?>.TextAlignmentProperty
- PartEditBoxBase<Guid?>.ValueProperty
- PartEditBoxBase<Guid?>.IsNonDefaultUsageContextProperty
- PartEditBoxBase<Guid?>.SpinnerVisibilityProperty
- PartEditBoxBase<Guid?>.UsageContextProperty
- PartEditBoxBase<Guid?>.CoerceValidValue(Guid?)
- PartEditBoxBase<Guid?>.Commit()
- PartEditBoxBase<Guid?>.Commit(bool)
- PartEditBoxBase<Guid?>.InvalidateParts()
- PartEditBoxBase<Guid?>.OnApplyTemplate()
- PartEditBoxBase<Guid?>.OnCreateAutomationPeer()
- PartEditBoxBase<Guid?>.OnGotFocus(RoutedEventArgs)
- PartEditBoxBase<Guid?>.OnIntermediateValueChanged(Guid?, Guid?)
- PartEditBoxBase<Guid?>.OnIsNullAllowedChanged(bool, bool)
- PartEditBoxBase<Guid?>.OnLostFocus(RoutedEventArgs)
- PartEditBoxBase<Guid?>.OnPopupOpened()
- PartEditBoxBase<Guid?>.OnValueChanged(Guid?, Guid?)
- PartEditBoxBase<Guid?>.ProcessTextInput(string)
- PartEditBoxBase<Guid?>.SelectAll()
- PartEditBoxBase<Guid?>.UpdateIntermediateValueAndTextFromValue()
- PartEditBoxBase<Guid?>.OnIsKeyboardFocusWithinChanged(DependencyPropertyChangedEventArgs)
- PartEditBoxBase<Guid?>.OnLostMouseCapture(MouseEventArgs)
- PartEditBoxBase<Guid?>.OnMouseLeftButtonDown(MouseButtonEventArgs)
- PartEditBoxBase<Guid?>.OnPreviewMouseUp(MouseButtonEventArgs)
- PartEditBoxBase<Guid?>.OnPreviewTextInput(TextCompositionEventArgs)
- PartEditBoxBase<Guid?>.ActivePartIndex
- PartEditBoxBase<Guid?>.CommitTriggers
- PartEditBoxBase<Guid?>.CurrentSelectionLength
- PartEditBoxBase<Guid?>.CurrentSelectionStartOffset
- PartEditBoxBase<Guid?>.CurrentText
- PartEditBoxBase<Guid?>.HasPopupButtonWhenReadOnly
- PartEditBoxBase<Guid?>.HasPopup
- PartEditBoxBase<Guid?>.Inlines
- PartEditBoxBase<Guid?>.InputScopeNameValue
- PartEditBoxBase<Guid?>.IntermediateValue
- PartEditBoxBase<Guid?>.IsArrowKeyPartNavigationEnabled
- PartEditBoxBase<Guid?>.IsEditable
- PartEditBoxBase<Guid?>.IsNullAllowed
- PartEditBoxBase<Guid?>.IsPopupButtonVisible
- PartEditBoxBase<Guid?>.IsPopupOpen
- PartEditBoxBase<Guid?>.IsReadOnly
- PartEditBoxBase<Guid?>.IsSpinnerVisible
- PartEditBoxBase<Guid?>.IsUndoEnabled
- PartEditBoxBase<Guid?>.Parts
- PartEditBoxBase<Guid?>.PlaceholderText
- PartEditBoxBase<Guid?>.PopupBackground
- PartEditBoxBase<Guid?>.PopupBorderBrush
- PartEditBoxBase<Guid?>.PopupPickerStyle
- PartEditBoxBase<Guid?>.ResetValueCommand
- PartEditBoxBase<Guid?>.SmallDecrementValueCommand
- PartEditBoxBase<Guid?>.SmallIncrementValueCommand
- PartEditBoxBase<Guid?>.SpinWrapping
- PartEditBoxBase<Guid?>.TextAlignment
- PartEditBoxBase<Guid?>.Value
- PartEditBoxBase<Guid?>.IsNonDefaultUsageContext
- PartEditBoxBase<Guid?>.SpinnerVisibility
- PartEditBoxBase<Guid?>.UsageContext