KeyGesture.Key 属性

定义

获取与此 KeyGesture 关联的键。Gets the key associated with this KeyGesture.

public:
 property System::Windows::Input::Key Key { System::Windows::Input::Key get(); };
public System.Windows.Input.Key Key { get; }
member this.Key : System.Windows.Input.Key
Public ReadOnly Property Key As Key

属性值

Key

与笔势关联的键。The key associated with the gesture. 默认值为 NoneThe default value is None.

注解

在大多数情况下,KeyGesture 必须与一个或多个 ModifierKeys相关联。In most cases, a KeyGesture must be associated with one or more ModifierKeys. 此规则的例外情况是函数键和数字键盘键,它们本身可以是有效的 KeyGestureThe exceptions to this rule are the function keys and the numeric keypad keys, which can be a valid KeyGesture by themselves.

适用于

另请参阅