Re: Knowing whether a tablet is connected and switching modes
Re: Knowing whether a tablet is connected and switching modes
- Subject: Re: Knowing whether a tablet is connected and switching modes
- From: Gideon King <email@hidden>
- Date: Thu, 26 Jan 2006 20:10:38 +0800
Thanks Ricky, this gave me a bit of a clue - so far I know:
- if InkUserWritingMode returns kInkWriteNowhere, the ink recognition is off completely.
- if it returns kInkWriteAnywhere, the application will be in writing mode unless we have overridden this for the application
- if it returns kInkWriteInInkAwareAppsOnly, the events will be interpreted as mouse moves etc. unless we have overridden it for the application
So I know what state the system is in.
Then it appears that I can switch my application to writing recognition by using:
InkSetApplicationWritingMode (kInkWriteAnywhereInApp);
InkSetApplicationRecognitionMode (kInkRecognitionDefault);
and switch it to mouse mode by using:
InkSetApplicationWritingMode (kInkWriteInInkAwareAppsOnly);
InkSetApplicationRecognitionMode (kInkRecognitionNone);
However this appears to be something that affects only my application (the ink window doesn't change state), so it makes my application independent of the system settings, or so you would think. So I could read the system settings on startup, and explicitly set the editing mode in my application, and manage it myself from there - not what I wanted to do, but it would suffice.
But it only works until the user switches modes in the ink window or system prefs or ink menu - then my application settings are thrown away, and replaced with the system setting. So I now have no idea what state we are in because I can only query the system setting and not my own application's drawing mode, as far as I can see.
I really would have thought that swapping from recognition to mousing and back would have been trivial, but this is not so as far as I can see.
Am I missing something obvious (or not so obvious) here?
Gideon King
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden