RectangleStylusShape Classe

Definição

Representa uma ponta retangular de agulha.

public ref class RectangleStylusShape sealed : System::Windows::Ink::StylusShape
public sealed class RectangleStylusShape : System.Windows.Ink.StylusShape
type RectangleStylusShape = class
    inherit StylusShape
Public NotInheritable Class RectangleStylusShape
Inherits StylusShape
Herança
RectangleStylusShape

Exemplos

O exemplo seguinte demonstra como usar um RectangleStylusShape para realizar testes de acerto num StrokeCollection. Este exemplo assume que existe um InkPresenter chamado presenter.

private void HitTestWithEraser(Point[] points)
{
    RectangleStylusShape eraser = new RectangleStylusShape(3, 3, 0);

    StrokeCollection strokes = presenter.Strokes.HitTest(points, eraser);

    foreach (Stroke s in strokes)
    {
        s.DrawingAttributes.Color = Colors.Purple;
    }
}
Private Sub HitTestWithEraser(ByVal points() As Point)
    Dim eraser As RectangleStylusShape = New RectangleStylusShape(3, 3, 0)

    Dim strokes As StrokeCollection = presenter.Strokes.HitTest(points, eraser)

    Dim s As Stroke
    For Each s In strokes
        s.DrawingAttributes.Color = Colors.Purple
    Next
End Sub

Construtores

Name Description
RectangleStylusShape(Double, Double, Double)

Inicializa uma nova instância da RectangleStylusShape classe com a largura, altura e ângulo especificados.

RectangleStylusShape(Double, Double)

Inicializa uma nova instância da RectangleStylusShape classe com a largura e altura especificadas.

Propriedades

Name Description
Height

Fica com a altura da caneta.

(Herdado de StylusShape)
Rotation

Percebe o ângulo da caneta.

(Herdado de StylusShape)
Width

Fica com a largura da caneta.

(Herdado de StylusShape)

Métodos

Name Description
Equals(Object)

Determina se o objeto especificado é igual ao objeto atual.

(Herdado de Object)
GetHashCode()

Serve como função de hash predefinida.

(Herdado de Object)
GetType()

Obtém o Type da instância atual.

(Herdado de Object)
MemberwiseClone()

Cria uma cópia superficial do atual Object.

(Herdado de Object)
ToString()

Devolve uma cadeia que representa o objeto atual.

(Herdado de Object)

Aplica-se a