Recent

Pen identity in UWP

When you are building apps for the Surface Hub you can use a real cool inking feature. The screen is already amazing with 84" and the pen support. But the pens also have an identity. This is a number and when you match this up with a credential you can do awesome things.

To get the pen identity you need few simple lines of code. I build an extension method for that:

public static class PointerPointPropertiesExtensions
{
    private const uint WirelessIdUsagePage = 0x0D;
    private const uint WirelessIdUsage = 0x5B;

    public static int? GetPenId(this PointerPointProperties pointerProperties)
    {
        var hasId = pointerProperties.HasUsage(WirelessIdUsagePage, WirelessIdUsage);
        return hasId ? pointerProperties.GetUsageValue(WirelessIdUsagePage, WirelessIdUsage) : default(int?);
    }
} 
  •   @JenMsft And the change of density in mail are great changes too!
  •   @ailon @JenMsft duhh.. <feeling stupid>
  •   @JenMsft @ailon Ctrl + F works in RS4? (it's not wirking for me)
  •   @tmobile_webcare Kamikaze?
  •   @DrGigabit @ExpertsLiveNL jeej! looking forward to see you again
  •   RT @ExpertsLiveNL: [HOLOLENS TRACK] Altijd al willen weten hoe je stap voor stap een #HoloLens #App moet bouwen? @davesmits vertelt het je…
  •   RT @panos_panay: Pumped to introduce Surface Hub 2! Created for a new culture of work, helping people move beyond simply sharing informatio…
  •   @Depechie tnx!
  •   @davidfowl ACR?
  •   @dougholland @surface love that picture on your pc