I have an app in Windows 8 which is a hand writing based. Im trying to port it to Windows Phone 8. But there are only 3 Inking classes available for WP8 and no Inkmanager class. Can we use a canvas instead of InkPresenter. Are all functions of stroke available for it. I tried the following code
private void MouseLeftButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
InkCanvas.CaptureMouse();
StylusPointCollection MyStylusPointCollection = new StylusPointCollection();
MyStylusPointCollection.Add(e.StylusDevice.GetStylusPoints(InkCanvas));
NewStroke = new Stroke(MyStylusPointCollection);
//InkCanvas.Strokes.Add(NewStroke);
NewStroke.DrawingAttributes = SetAttributes(draw);
}
There is an error in the second last line it says, canvas does not contain the definition for strokes. InkPresenter does not suit my needs. If not canvas is there any other element which can capture the touch input?
Thanks for your answer, The Inkpresenter does not meet my needs. So I have used the canvas and touch input.
For those of you who are looking for clues…
I have made use
Touch_FrameReportedand basic line drawing like this