spiegel-keyman/web/docs/engine/reference/util/isTouchDevice.md
Marc Durdin 6c145cb775 refactor(web): move web engine help to app repo
Note: build.sh updated to make sure that test:help build action:target
doesn't also call test.sh by adding `:_all` meta-target.

Note: CI will need a new help-keyman-com.sh build step to deploy web
engine help.

Fixes: #12347
2024-10-31 11:00:06 +07:00

29 lines
543 B
Markdown

---
title: isTouchDevice
---
## Summary
Allow external callers (such as UIs) to detect if the active device is considered touch sensitive by KeymanWeb.
## Syntax
```c
keyman.util.isTouchDevice();
```
### Parameters
None.
### Return Value
`boolean`
: `true` if KMW is targetting touch-sensitivity for the device, otherwise `false`.
```
isTouchDevice ...
```
> [!Note]
> In current versions of KeymanWeb this function will return `false` for touchscreen laptops; current touch support is specialized for mobile phones and tablets.