wintab: Incorrectly classifying cursor as stylus instead of eraser
eriks.dobelis at biti.lv
Fri Mar 21 01:21:12 CDT 2014
The alternative - just to switch order of checks in
X11DRV_LoadTabletInfo. There is a code fragment:
/* prefer finding TYPE_PEN(most capable) */
if (is_stylus(target->name, device_type))
cursor.TYPE = CSR_TYPE_PEN;
else if (is_eraser(target->name, device_type))
cursor.TYPE = CSR_TYPE_ERASER;
cursor.TYPE = CSR_TYPE_OTHER;
I would need to switch order and check for ERASER first. Problems would
arise if for some device name would be "Pen & Eraser", and type would be
"STYLUS" , and then it would be detected as eraser. In the proposed
patch this problem would not arise as only device is checked for ERASER.
For my specific case both approaches work. Which one you consider as better?
On 2014.03.20. 22:11, Alexandre Julliard wrote:
> Eriks Dobelis <eriks.dobelis at biti.lv> writes:
>> Did not attach the patch in my last email :(
>> For Wacom Pen & Touch Intuos tablet eraser cursor is incorrectly
>> detected as stylus.
>> The tablet returns its eraser cursor name as:
>> Wacom Intuos PT S Pen eraser
>> and type as:
>> Current code classifies this as STYLUS, because name of the cursor
>> contains the word 'Pen'. It is very unlikely that a cursor with type
>> ERASER is STYLUS.
> There is already a check for eraser type, you should be able to use that
More information about the wine-devel