Stroke Class
Represents a single ink stroke.
Assembly: PresentationCore (in PresentationCore.dll)
| Name | Description | |
|---|---|---|
![]() | Stroke(StylusPointCollection^) | Initializes a new instance of the Stroke class. |
![]() | Stroke(StylusPointCollection^, DrawingAttributes^) | Initializes a new instance of the Stroke class. |
| Name | Description | |
|---|---|---|
![]() | DrawingAttributes | Gets or sets the DrawingAttributes for the Stroke object. |
![]() | StylusPoints | Returns the stylus points of the Stroke. |
| Name | Description | |
|---|---|---|
![]() | AddPropertyData(Guid, Object^) | Adds a custom property to the Stroke object. |
![]() | Clone() | Returns a deep copy of the existing Stroke object. |
![]() | ContainsPropertyData(Guid) | Returns a value that indicates whether the Stroke object contains the specified custom property. |
![]() | Draw(DrawingContext^) | Renders the Stroke object based upon the specified DrawingContext. |
![]() | Draw(DrawingContext^, DrawingAttributes^) | Renders the Stroke object based upon the specified DrawingContext and DrawingAttributes. |
![]() | DrawCore(DrawingContext^, DrawingAttributes^) | Renders the Stroke on the specified DrawingContext using the specified DrawingAttributes. |
![]() | Equals(Object^) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | Finalize() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) |
![]() | GetBezierStylusPoints() | Returns the stylus points the Stroke uses when FitToCurve is true. |
![]() | GetBounds() | Retrieves the bounding box for the Stroke object. |
![]() | GetClipResult(IEnumerable<Point>^) | Returns segments of the current Stroke that are within the specified bounds. |
![]() | GetClipResult(Rect) | Returns segments of the current Stroke that are within the specified rectangle. |
![]() | GetEraseResult(IEnumerable<Point>^) | Returns segments of the current Stroke that are outside the specified bounds. |
![]() | GetEraseResult(IEnumerable<Point>^, StylusShape^) | Returns the segments of the current Stroke after it is dissected by the designated path using the specified StylusShape. |
![]() | GetEraseResult(Rect) | Returns segments of the current Stroke that are outside the specified rectangle. |
![]() | GetGeometry() | Gets the Geometry of the current Stroke. |
![]() | GetGeometry(DrawingAttributes^) | Gets the Geometry of the current Stroke using the specified DrawingAttributes. |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetPropertyData(Guid) | Retrieves the property data for the specified GUID. |
![]() | GetPropertyDataIds() | Retrieves the GUIDs of any custom properties associated with the Stroke object. |
![]() | GetType() | |
![]() | HitTest(IEnumerable<Point>^, Int32) | Returns a value that indicates whether the current Stroke is within the specified bounds. |
![]() | HitTest(IEnumerable<Point>^, StylusShape^) | Returns whether the specified path intersects the Stroke using the specified StylusShape. |
![]() | HitTest(Point) | Returns a value that indicates whether current Stroke intersects the specified point. |
![]() | HitTest(Point, Double) | Returns a value that indicates whether current Stroke intersects the specified area. |
![]() | HitTest(Rect, Int32) | Returns a value that indicates whether the Stroke is within the bounds of the specified rectangle. |
![]() | MemberwiseClone() | |
![]() | OnDrawingAttributesChanged(PropertyDataChangedEventArgs^) | Allows derived classes to modify the default behavior of the DrawingAttributesChanged event. |
![]() | OnDrawingAttributesReplaced(DrawingAttributesReplacedEventArgs^) | Allows derived classes to modify the default behavior of the DrawingAttributesReplaced event. |
![]() | OnInvalidated(EventArgs^) | Raises the Invalidated event. |
![]() | OnPropertyChanged(PropertyChangedEventArgs^) | Occurs when any Stroke property changes. |
![]() | OnPropertyDataChanged(PropertyDataChangedEventArgs^) | Allows derived classes to modify the default behavior of the PropertyDataChanged event. |
![]() | OnStylusPointsChanged(EventArgs^) | Raises the StylusPointsChanged event. |
![]() | OnStylusPointsReplaced(StylusPointsReplacedEventArgs^) | Raises the StylusPointsReplaced event. |
![]() | RemovePropertyData(Guid) | Deletes a custom property from the Stroke object. |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
![]() | Transform(Matrix, Boolean) | Performs a transformation based upon the specified Matrix object. |
| Name | Description | |
|---|---|---|
![]() | DrawingAttributesChanged | Occurs when the DrawingAttributes associated with the Stroke object change. |
![]() | DrawingAttributesReplaced | Occurs when the drawing attributes of a Stroke object are replaced. |
![]() | Invalidated | Occurs when the appearance of the Stroke changes. |
![]() | PropertyDataChanged | Occurs when the custom properties on a Stroke object changes. |
![]() | StylusPointsChanged | Occurs when the StylusPoints property changes. |
![]() | StylusPointsReplaced | Occurs when the StylusPoints property is assigned a new StylusPointCollection. |
| Name | Description | |
|---|---|---|
![]() ![]() | INotifyPropertyChanged::PropertyChanged | This API supports the product infrastructure and is not intended to be used directly from your code. Occurs when the value of any Stroke property has changed. |
A Stroke is the data object that is collected from a pointing device, such as a tablet pen or a mouse. The Stroke can be created and manipulated programmatically, and can be represented visually on an ink-enabled element, such as the InkCanvas. A Stroke contains information about both its position and appearance. The StylusPoints property is a collection of StylusPoint objects that specifies the position of the Stroke. The DrawingAttributes property specifies a stroke's appearance.
Available since 3.0
Silverlight
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.





