Bagikan melalui


Stylus Class

Stylus Class

Provides access to general information about a tablet stylus.

Definition

Visual Basic .NET NotInheritable Public Class Stylus
Inherits Object
C# public sealed class Stylus : Object
Managed C++ public __gc __sealed class Stylus : public Object

Members Table

The following table lists the members exposed by the object.

Methods

Method Description
Equals Leave Site Determines whether two Object Leave Site instances are equal. Inherited from Object Leave Site.
Finalize Leave Site Allows an Object Leave Site to attempt to free resources and perform other cleanup operations before the Object Leave Site is reclaimed by garbage collection. Inherited from Object Leave Site.
GetHashCode Leave Site Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table. Inherited from Object Leave Site.
GetType Leave Site Gets the Type Leave Site of the current instance. Inherited from Object Leave Site.
MemberwiseClone Leave Site Creates a shallow copy of the current Object Leave Site. Inherited from Object Leave Site.
static (Shared in Visual Basic .NET)ReferenceEquals Leave Site Determines whether the specified Object Leave Site instances are the same instance. Inherited from Object Leave Site.
ToString Leave Site Returns a String Leave Site that represents the current Object Leave Site. Inherited from Object Leave Site.

Properties

Property Description
Buttons Gets the stylus buttons that are available on the stylus. The buttons may include the pen tip, the eraser end, and the barrel.
Id Gets the GUID of the stylus.
Inverted Gets a value that indicates whether the stylus is inverted or not.
Name Gets the name of the Stylus object.
TabletContextID Gets the context identifier for the tablet device to which the stylus belongs.

Inheritance Hierarchy

Object Leave Site

Stylus

Remarks

This object represents the physical stylus that the user holds. Physical stylii may have multiple tips (such as normal and eraser ends), with each stylus tip corresponding to a different Stylus object. Some Tablet PCs allow multiple stylii. Each Stylus object has an associated globally unique identifier (GUID) that is unique on a system. For more information about how stylii can be used with a Tablet PC, see Pen Overview.

Stylii exist within the scope of a RealTimeStylus object. When a RealTimeStylus object encounters a new Stylus object, the RealTimeStylus object calls the IStylusSyncPlugin.StylusInRange method of each of its synchronous plug-ins, and finally the IStylusAsyncPlugin.StylusInRange method of its asynchronous plug-ins. The RealTimeStylus object maintains a list of the Stylus objects it has encountered. This list can be accessed by calling the RealTimeStylus object's GetStyluses method.

Class Information

Namespace Microsoft.StylusInput
Assembly Microsoft.Ink (microsoft.ink.dll)
Strong Name Microsoft.Ink, Version=1.7.4009.0, Culture=neutral, PublicKeyToken=a2870d9cc4d021c8

See Also