Home · All Classes · Main Classes · Grouped Classes · Modules · Functions

[Contents]

Pointer Handling

Pointer handling in Qtopia Core works for both mouse and mouse-like devices such as touch panels and trackballs. The various drivers can be enabled and disabled using the configure script. For example:

    configure -qt-mouse-tslib

Run ./configure -help to list the available drivers. In the default Qt configuration, only the "pc" mouse driver is enabled.

Available Drivers

Qtopia Core provides drivers for the MouseMan, IntelliMouse, Microsoft, NEC Vr41XX, Linux Touch Panel and Yopy protocols as well as the universal touch screen library, tslib.

Provided that the "pc" mouse driver is enabled, Qtopia Core will try to auto-detect the mouse device if it is one of the supported types on /dev/psaux or one of the /dev/ttyS? serial lines. If multiple mice are detected, all may be used simultaneously. Note that Qtopia Core does not support auto-detection of touch panels in which case the driver must be specified explicitly to determine which device to use.

Other drivers can be added by deriving from the QWSMouseHandler and QMouseDriverPlugin classes and using Qt's plugin mechanism.

Specifying a Driver

To specify which driver to use, set the QWS_MOUSE_PROTO environment variable. For example (if the current shell is bash, ksh, zsh or sh):

     export QWS_MOUSE_PROTO=<driver>:<device>

The <driver> argument is either MouseMan, IntelliMouse, Microsoft, VR41xx, LinuxTP, Yopy or Tslib, and the <device> argument is typically /dev/mouse for mouse devices and /dev/ts for touch panels. Note that the latter argument is optional.

[Contents]


Copyright © 2006 Trolltech Trademarks
Qt 4.1.3