StylusButton.Guid 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
Guid获取表示触笔按钮的键。
public:
property Guid Guid { Guid get(); };
public Guid Guid { get; }
member this.Guid : Guid
Public ReadOnly Property Guid As Guid
属性值
表示 Guid 触笔按钮的属性。
示例
以下检查用户是否按下触笔上的桶按钮。
void OnStylusButtonDown(object sender, StylusButtonEventArgs e)
{
StylusButton myStylusButton = e.StylusButton;
if (myStylusButton.Guid == StylusPointProperties.BarrelButton.Id)
{
// the barrel button on the stylus has been pressed
}
}
Private Sub OnStylusButtonDown(ByVal sender As Object, ByVal e As StylusButtonEventArgs)
Dim myStylusButton As StylusButton = e.StylusButton
If myStylusButton.Guid = StylusPointProperties.BarrelButton.Id Then
' the barrel button on the stylus has been pressed
End If
End Sub
注解
保证此属性的值在系统上的触笔按钮中是唯一的。