Pen and Ink

Sign in to queue

Description

They said it couldn't be done ;) but we're back with another episode of 'Context' where this time we're looking at digital ink and digitised pens.

Inking has long been a focus of Microsoft and the modern platform built around DirectInk and the InkCanvas control provides a great experience for the user while being the most performant, most capable inking platform we've built and yet it also has a low barrier to entry for the developer.

In this show, we spend time on InkCanvas and what it can do for you having spent a little time reviewing how we used to do things and why InkCanvas is better. We'll also look at a couple of things coming in inking for the Windows 10 Anniversary Update.

Here's a breakdown of the show;

Show Notes;

 

 

Embed

Download

The Discussion

  • User profile image
    PungE3

    Great video.  Is there a way to erase by point, rather than stroke, in a C# UWP app or does this have to be done using DirectInk?

  • User profile image
    mtaulty

    Hi,

    Great question! I'm not 100% sure on whether there's a better way of doing this as ink shows up in the StrokeContainer as a collection of InkStroke objects which can then be manipulated (e.g. deleted).

    However, it is possible to get hold of the points that make up an InkStroke (via the GetInkPoints() method) but it gives you a read-only view.

    That said, it's then possible to manually build InkStroke objects using the InkStrokeBuilder class so I'd say it's possible to;

    1. Select the stroke that contains the points you don't want.
    2. Delete it.
    3. Get the points from it.
    4. Build a new stroke containing only the points that you want.
    5. Add that new stroke back into the StrokeContainer.

    That's perhaps one way of achieving what you want here, there may be a better way that I haven't yet come across.

    Mike

     

  • User profile image
    David

    Hi,

    Does Microsoft Word currently use the DirectInk platform?

    Thanks.

    David.

Add Your 2 Cents