StylusPoint.Explicit(StylusPoint to Point) Operador

Definição

Converte o StylusPoint especificado em um Point.Casts the specified StylusPoint to a Point.

public:
 static explicit operator System::Windows::Point(System::Windows::Input::StylusPoint stylusPoint);
public static explicit operator System.Windows.Point (System.Windows.Input.StylusPoint stylusPoint);
static member op_Explicit : System.Windows.Input.StylusPoint -> System.Windows.Point

Parâmetros

stylusPoint
StylusPoint

O StylusPoint a ser convertido em um Point.The StylusPoint to cast to a Point.

Retornos

Um Point que contém as mesmas coordenadas (x, y) que stylusPoint.A Point that contains the same (x,y) coordinates as stylusPoint.

Comentários

O exemplo a seguir demonstra como converter um StylusPoint em um objeto Point para desenhar um círculo no início de cada traço.The following example demonstrates how to cast a StylusPoint to a Point object to draw a circle at the beginning of every stroke. Este exemplo pressupõe que haja um objeto InkCanvas chamado inkcanvas1 e que o evento StylusDown esteja conectado ao manipulador de eventos no exemplo.This example assumes that there is an InkCanvas object called inkcanvas1 and that the StylusDown event is connected to the event handler in the example.

       [!code-csharp[PacketSpy#13](~/samples/snippets/csharp/VS_Snippets_Wpf/PacketSpy/CSharp/Window1.xaml.cs#13)]
       [!code-vb[PacketSpy#13](~/samples/snippets/visualbasic/VS_Snippets_Wpf/PacketSpy/VisualBasic/Window1.xaml.vb#13)]

Aplica-se a