Export (0) Print
Expand All

SurfaceInkCanvas Class

Surface 1.0 SP1
Represents a control that users draw on when they move their fingers over the control.

Namespace: Microsoft.Surface.Presentation.Controls
Assembly: Microsoft.Surface.Presentation (in microsoft.surface.presentation.dll)

'Usage
Dim instance As SurfaceInkCanvas

public class SurfaceInkCanvas : SurfaceFrameworkElement
public class SurfaceInkCanvas extends SurfaceFrameworkElement
public class SurfaceInkCanvas extends SurfaceFrameworkElement

In the following example, a SurfaceInkCanvas control is declared.

<UserControl 
    x:Class="Class_SurfaceInkCanvas.Controls.SurfaceInkCanvas0"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:s="http://schemas.microsoft.com/surface/2008">
    
    <s:SurfaceInkCanvas 
        Name="SurfaceInkCanvas"
        Background="WhiteSmoke"
        UsesContactShape="True"/>

</UserControl>

A SurfaceInkCanvas control provides functionality similar to an InkCanvas control. A SurfaceInkCanvas control receives and displays ink input as the user moves a contact or contacts over the control. During contact movement, the Microsoft Surface input system creates strokes, which are represented as Stroke Stroke objects and which can be manipulated either programmatically or based on user input. After a Stroke object is created, the SurfaceInkCanvas control enables users to modify or delete it.

The Photo Paint sample application demonstrates the use of the SurfaceInkCanvas control.


System.Object
   System.Windows.Threading.DispatcherObject
     System.Windows.DependencyObject
       System.Windows.Media.Visual
         System.Windows.UIElement
           System.Windows.FrameworkElement
             Microsoft.Surface.Presentation.Controls.SurfaceFrameworkElement
              Microsoft.Surface.Presentation.Controls.SurfaceInkCanvas

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Development Platforms

Microsoft Surface 1.0 SP1, Windows Vista Ultimate, Windows Vista Enterprise, Windows Vista Business

Target Platforms

Microsoft Surface 1.0 SP1
Show:
© 2014 Microsoft