StrokeCollection.Clip 메서드

정의

지정한 범위 밖에 있는 StrokeCollection의 모든 스트로크를 제거합니다.

오버로드

Clip(IEnumerable<Point>)

지정한 StrokeCollection 배열의 범위 밖에 있는 Point의 모든 스트로크를 제거합니다.

Clip(Rect)

지정한 사각형으로 클리핑된 모든 스트로크를 지정한 사각형을 벗어나지 않는 새 스트로크로 바꿉니다.

Clip(IEnumerable<Point>)

지정한 StrokeCollection 배열의 범위 밖에 있는 Point의 모든 스트로크를 제거합니다.

public:
 void Clip(System::Collections::Generic::IEnumerable<System::Windows::Point> ^ lassoPoints);
public void Clip (System.Collections.Generic.IEnumerable<System.Windows.Point> lassoPoints);
member this.Clip : seq<System.Windows.Point> -> unit
Public Sub Clip (lassoPoints As IEnumerable(Of Point))

매개 변수

lassoPoints
IEnumerable<Point>

클리핑할 영역을 지정하는 Point 형식의 배열입니다.

예제

다음 예제에서는의 스트로크를 클리핑 하는 방법에 설명 된 StrokeCollection합니다. 이 예제에서는 있다고 가정를 InkPresenter 호출 presenter합니다.

// Clip the selected strokes.
public void ClipStrokes(Stroke lasso)
{
    Point[] strokePoints = (Point[])lasso.StylusPoints;
    presenter.Strokes.Clip(strokePoints);
}
' Clip the selected strokes.
Public Overloads Sub ClipStrokes(ByVal lasso As Stroke)

    If lasso Is Nothing Then
        Return
    End If

    Dim strokePoints() As Point = CType(lasso.StylusPoints, Point())
    presenter.Strokes.Clip(strokePoints)

End Sub

설명

합니다 Clip 메서드는 연결의 첫 번째 지점과 마지막 lassoPoints 올가미를 만들려고 합니다.

합니다 Clip 메서드를 발생 시킵니다 합니다 StrokesChanged 각각에 대 한 이벤트 Stroke 자르는 것입니다.

적용 대상

Clip(Rect)

지정한 사각형으로 클리핑된 모든 스트로크를 지정한 사각형을 벗어나지 않는 새 스트로크로 바꿉니다.

public:
 void Clip(System::Windows::Rect bounds);
public void Clip (System.Windows.Rect bounds);
member this.Clip : System.Windows.Rect -> unit
Public Sub Clip (bounds As Rect)

매개 변수

bounds
Rect

클리핑할 영역을 지정하는 Rect입니다.

예제

다음 예제에서는 범위 외부에 있는 잉크를 지우는 방법은 Rect합니다. 이 예제에서는 있다고 가정를 InkPresenter 호출 presenter합니다.

Rect rect = new Rect(100, 100, 200, 200);
presenter.Strokes.Clip(rect);
Dim rect As Rect = New Rect(100, 100, 200, 200)
presenter.Strokes.Clip(rect)

설명

완전히 지정된 된 사각형 외부에 있는 모든 스트로크를 제거 됩니다.

적용 대상