Portability | portable (depends on GHC) |
---|---|
Stability | provisional |
Maintainer | gtk2hs-users@lists.sourceforge.net |
A KeyVal
is a numeric value identifying a keyboard key. The defined
values can be found at <http:
The names of the keys are the names of the macros without the prefix.
- type KeyVal = Word32
- keyName :: KeyVal -> String
- keyFromName :: String -> KeyVal
- keyToChar :: KeyVal -> Maybe Char
- keyvalConvertCase :: KeyVal -> (KeyVal, KeyVal)
- keyvalToUpper :: KeyVal -> KeyVal
- keyvalToLower :: KeyVal -> KeyVal
- keyvalIsUpper :: KeyVal -> Bool
- keyvalIsLower :: KeyVal -> Bool
Documentation
Key values are the codes which are sent whenever a key is pressed or released.
keyFromName :: String -> KeyValSource
Converts a key name to a key value.
:: KeyVal |
|
-> Maybe Char | returns the corresponding unicode character, or Nothing if there is no corresponding character. |
Convert from a Gdk key symbol to the corresponding Unicode character.
:: KeyVal |
|
-> (KeyVal, KeyVal) |
|
Obtains the upper- and lower-case versions of the keyval symbol. Examples of keyvals are GDK_a,
Enter
, F1
, etc.
:: KeyVal |
|
-> KeyVal | returns the upper case form of keyval, or keyval itself if it is already in upper case or it is not subject to case |
Converts a key value to upper case, if applicable.
:: KeyVal |
|
-> KeyVal | returns the lower case form of keyval, or keyval itself if it is already in lower case or it is not subject to case |
Converts a key value to lower case, if applicable.