Поделиться через


InkAnalyzer.RemoveStroke - метод

Обновлен: Ноябрь 2007

Removes a Stroke from the ink analyzer.

Пространство имен:  System.Windows.Ink
Сборка:  IAWinFX (в IAWinFX.dll)

Синтаксис

'Декларация
Public Sub RemoveStroke ( _
    strokeToRemove As Stroke _
)
'Применение
Dim instance As InkAnalyzer
Dim strokeToRemove As Stroke

instance.RemoveStroke(strokeToRemove)
public void RemoveStroke(
    Stroke strokeToRemove
)
public:
void RemoveStroke(
    Stroke^ strokeToRemove
)
public void RemoveStroke(
    Stroke strokeToRemove
)
public function RemoveStroke(
    strokeToRemove : Stroke
)

Параметры

Заметки

RemoveStroke removes strokeToRemove from the InkAnalyzer.

This method removes strokeToRemove from the leaf context node that references the stroke. If the context node no longer references any strokes, this method deletes the context node and any ancestor nodes that no longer have child nodes.

After this method removes the stroke from the context node, it updates the DirtyRegion to include the bounding box of the removed stroke.

If the stroke is not associated with the ink analyzer, this method returns without updating the ink analyzer.

This method throws a ArgumentNullException when strokeToRemove is nullссылка null (Nothing в Visual Basic).

Примеры

This example determines if a Stroke, theStroke, has a bounding box with a left bound lower than the 32-bit signed integer named leftBound. If so, it removes theStroke from the InkAnalyzer named theInkAnalyzer.

' Remove the stroke if its bounding box falls outside of the left bound.
If Not (theStroke Is Nothing) AndAlso theStroke.GetBounds().Left < leftBound Then
    Me.theInkAnalyzer.RemoveStroke(theStroke)
End If
// Remove the stroke if its bounding box falls outside of the left bound.
if (theStroke != null && theStroke.GetBounds().Left < leftBound)
{
    this.theInkAnalyzer.RemoveStroke(theStroke);
}

Платформы

Windows Vista

Среды .NET Framework и .NET Compact Framework поддерживают не все версии каждой платформы. Поддерживаемые версии перечислены в разделе Требования к системе для .NET Framework.

Сведения о версии

.NET Framework

Поддерживается в версии: 3.0

См. также

Ссылки

InkAnalyzer Класс

InkAnalyzer - члены

System.Windows.Ink - пространство имен

InkAnalyzer.AddStroke

InkAnalyzer.AddStrokes

InkAnalyzerRemoveStrokes()

InkAnalyzer.DirtyRegion