How to use stylus to "click" GUI Button

0 votes
asked Mar 23 by shannon williams (13 points)
Has anyone have an example of how to "click" a Canvas button using the stylus? or at least simulate it? I also mean having the canvas as a screen overlay.

1 Answer

0 votes
answered Jul 4 by AlexShorey (30 points)
Hi Shannon,

Are you still looking for ways of clicking Unity UI elements with the stylus?

The currently provided way of interfacing with UI involves enabling Mouse Emulation through the zSpace plugin.

.SetMouseEmulationEnabled( bool );

A distance threshold can also be set so emulation only occurs when emulation is enabled and the stylus tip is a maximum specified distance from the screen.

.SetMouseEmulationMaxDistance(float number in meter scale);

The oval shaped stylus button will emulate a mouse left click when the emulation is enabled.

More detailed information regarding this feature can be found on pages 32 and 33 of the zSpace Unity3D Programming Guide.

Feel free to let us know if you still have questions regarding this.
...