Class
RegularKeyViewModel

Represents the class for virtual keyboard regular key view models.

Definition

Namespace:Telerik.Windows.Controls.VirtualKeyboard

Assembly:Telerik.Windows.Controls.Navigation.dll

Syntax:

cs-api-definition
public class RegularKeyViewModel : BaseKeyViewModel, INotifyPropertyChanged, IDisposable

Inheritance: objectViewModelBaseBaseKeyViewModelRegularKeyViewModel

Implements: IDisposableINotifyPropertyChanged

Inherited Members BaseKeyViewModel.GetModifiers()BaseKeyViewModel.KeyCommandBaseKeyViewModel.KeySoundPlayerBaseKeyViewModel.VirtualKeyBaseKeyViewModel.KeyTypeBaseKeyViewModel.KeyWidthBaseKeyViewModel.KeyHeightBaseKeyViewModel.ModifierKeysBaseKeyViewModel.DisplayTextViewModelBase.VerifyPropertyName(string)ViewModelBase.InvokeOnUIThread(Action)ViewModelBase.Dispose()ViewModelBase.RaisePropertyChanged(string)ViewModelBase.OnPropertyChanged(string)ViewModelBase.OnPropertyChanged<T>(Expression<Func<T>>)ViewModelBase.Dispose(bool)ViewModelBase.PropertyChanged

Constructors

RegularKeyViewModel(int, double, double, bool, string)

Initializes a new instance of the RegularKeyViewModel class.

Declaration

cs-api-definition
public RegularKeyViewModel(int virtualKey, double keyWidth, double keyHeight, bool showSecondaryText, string displayText = null)

Parameters

virtualKey

int

The virtual key.

keyWidth

double

The width of the key.

keyHeight

double

The height of the key.

showSecondaryText

bool

Indicates whether to show the secondary text.

displayText

string

The display text of the key.

Properties

AltText

Gets or sets the display text shown when Alt key is pressed.

Declaration

cs-api-definition
public string AltText { get; set; }

Property Value

string

CapsLockText

Gets or sets the display text shown when CapsLock is toggled.

Declaration

cs-api-definition
public string CapsLockText { get; set; }

Property Value

string

LowerText

Gets or sets the display text shown when no modifier key is pressed.

Declaration

cs-api-definition
public string LowerText { get; set; }

Property Value

string

ShiftText

Gets or sets the display text shown when Shift key is pressed.

Declaration

cs-api-definition
public string ShiftText { get; set; }

Property Value

string

ShowSecondaryText

Gets or sets the an additional text shown next to the primary display text.

Declaration

cs-api-definition
public bool ShowSecondaryText { get; set; }

Property Value

bool

Methods

OnKeyCommandExecuted(object)

The method called by the default command assigned to the key.

Declaration

cs-api-definition
protected override void OnKeyCommandExecuted(object commandParameter)

Parameters

commandParameter

object

Overrides BaseKeyViewModel.OnKeyCommandExecuted(object)

Update(IKeyUpdateContext)

Updates the state of the regular key view model based on the provided key update context.

Declaration

cs-api-definition
public override void Update(IKeyUpdateContext context)

Parameters

context

IKeyUpdateContext

An instance of IKeyUpdateContext that supplies the necessary information for the update.

Overrides BaseKeyViewModel.Update(IKeyUpdateContext)