height
height
This page has been flagged with the following issues:
High-level issues:
Content:
W3C Working Draft
Summary
The height (magnitude on the Y axis), in CSS pixels, of the contact geometry of the pointer.
Property of dom/PointerEvent
Syntax
Note: This property is read-only.
var result = event.height;
Return Value
Returns an object of type unsigned long.
Examples
Resizing an element to match the contact geometry
JavaScript
<script> window.addEventListener("pointerdown", checkPointerSize, false); function checkPointerSize(event) { event.target.style.width = event.width + "px"; event.target.style.height = event.height + "px"; } </script>
Usage
This value may be updated on each event for a given pointer. For devices which have a contact geometry but the actual geometry is not reported by the hardware, a default value may be provided by the user agent to approximate the geometry typical of that pointer type. Otherwise, the value must be 0.
Compatibility
Desktop
| Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
|---|---|---|---|---|---|
| Basic Support | ? | ? | IE10 | ? |
? |
Mobile
| Feature | Android | BlackBerry | Chrome for mobile | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Opera Mini | Safari Mobile |
|---|---|---|---|---|---|---|---|---|
| Basic support | ? | ? | ? | ? | ? | ? | ? | ? |
Compatibility notes
| Browser | Version | Note |
|---|---|---|
| Internet Explorer | 10 | Pointer events are supported with the MS prefix. In the example above, IE10 would require 'MSPointerDown rather than pointerdown. |
This tool helps to make and review comments inline.
How to Use
insert instructions, with images, here