ToggleKey
Definition
Namespace:Telerik.WinControls.VirtualKeyboard
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class ToggleKey : LightVisualToggleButtonElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider, IKey
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementLightVisualButtonElementLightVisualToggleButtonElementToggleKey...
Implements:
Inherited Members
Constructors
Initializes a new instance of the ToggleKey class.
public ToggleKey(int keyCode, KeyType keyType, double width, double height, bool sharpStyle = false)
The virtual key code.
keyTypeKeyTypeThe type of the key.
widthdoubleThe logical width of key.
heightdoubleThe logical height of key.
sharpStyleboolIndicates whether the key has more noticeable(sharp) style.
Initializes a new instance of the ToggleKey class.
public ToggleKey(int keyCode, string displayText, KeyType keyType, double width, double height, bool sharpStyle = false, Font font = null)
The virtual key code.
displayTextstringThe display text.
keyTypeKeyTypeThe type of the key.
widthdoubleThe logical width of key.
heightdoubleThe logical height of key.
sharpStyleboolIndicates whether the key has more noticeable(sharp) style.
fontFontThe font specified to the key element.
Fields
Dependency property that indicates whether the key should have more noticeable/sharp style.
public static RadProperty IsSharpStyleProperty
Properties
Gets or sets the name of the control for use by accessibility client applications.
public override string AccessibleName { get; set; }
Overrides:
Gets or sets the display text.
public string DisplayText { get; set; }
Gets or sets the font scale coefficient, used when key is larger or smaller than the KeyDefaultSize.
public float FontScale { get; set; }
Implements:
Gets or sets a value indicating whether the key will have more noticeable/sharp style.
public bool IsSharpStyle { get; set; }
Gets or sets the logical key height.
public float KeyHeight { get; set; }
Implements:
Gets or sets the associated key info object.
public KeyInfo KeyInfo { get; set; }
Implements:
Gets or sets the logical key bounds.
public RectangleF KeyRectangle { get; set; }
Implements:
Gets the owner element used to send the keys.
public IVirtualKeyboardKeyInputSender Owner { get; }
Implements:
Gets the type by which this instance is being themed.
protected override Type ThemeEffectiveType { get; }
Overrides:
Gets the virtual key code.
public int VirtualKey { get; set; }
Implements:
Methods
Arranges the key in the specified rectangle.
public void ArrangeKey(RectangleF rectangle)
The layout rectangle.
Implements:
Initializes member fields to their default values. This method is called prior the CreateChildItems one and allows for initialization of members on which child elements depend.
protected override void InitializeFields()
Overrides:
Called when the element has been successfully loaded. That includes loading of all its children as well.
protected override void OnLoaded()
Overrides:
Raises the StateChanged event.
protected override void OnToggleStateChanged(StateChangedEventArgs e)
Overrides:
Sends a virtual key code or string.
public void SendKey()
Implements:
Updates key text and other necessary styles.
public void UpdateKey()
Implements: