diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2008-12-05 16:24:57 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-01-12 12:55:27 +1000 |
commit | a48c81dcdf569a3f634ac23e08d2491354de6a36 (patch) | |
tree | 3c7c5a82f99513d000e0b731e0d93dbb9e37b092 /include | |
parent | 669f6810af9a89187d6149841925fe765f3988ff (diff) |
Xi: add XATOM_FLOAT to server-defined properties.
This property is used to denote type float for input properties. Such
properties can be accessed easily through the XIPropToFloat() function.
Code originally written by Simon Thum.
Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/exevents.h | 6 | ||||
-rw-r--r-- | include/xserver-properties.h | 4 |
2 files changed, 10 insertions, 0 deletions
diff --git a/include/exevents.h b/include/exevents.h index 485347be2..2504baf04 100644 --- a/include/exevents.h +++ b/include/exevents.h @@ -257,4 +257,10 @@ extern _X_EXPORT int XIPropToInt( int **buf_return ); +extern _X_EXPORT int XIPropToFloat( + XIPropertyValuePtr val, + int *nelem_return, + float **buf_return +); + #endif /* EXEVENTS_H */ diff --git a/include/xserver-properties.h b/include/xserver-properties.h index 4d602b5ab..f8aeab65d 100644 --- a/include/xserver-properties.h +++ b/include/xserver-properties.h @@ -26,6 +26,10 @@ #ifndef _XSERVER_PROPERTIES_H_ #define _XSERVER_PROPERTIES_H_ +/* Type for a 4 byte float. Storage format IEEE 754 in client's default + * byte-ordering. */ +#define XATOM_FLOAT "FLOAT" + /* BOOL. 0 - device disabled, 1 - device enabled */ #define XI_PROP_ENABLED "Device Enabled" |