diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/events.lua | 4 | ||||
-rw-r--r-- | core/keys.lua | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/core/events.lua b/core/events.lua index 7c3c34f1..25467025 100644 --- a/core/events.lua +++ b/core/events.lua @@ -36,7 +36,7 @@ module('events')]] -- -- * `APPLEEVENT_ODOC` -- Called when Mac OSX tells Textadept to open a document. --- * `uri`: The URI to open. +-- * `uri`: The URI to open encoded in UTF-8. -- * `AUTO_C_CHAR_DELETED` -- Called when the user deleted a character while the autocompletion list was -- active. @@ -202,7 +202,7 @@ module('events')]] -- * `URI_DROPPED` -- Called when the user has dragged a URI such as a file name onto the view. -- Arguments: --- * `text`: The URI text. +-- * `text`: The URI text encoded in UTF-8. -- * `USER_LIST_SELECTION` -- Called when the user has selected an item in a user list. -- Arguments: diff --git a/core/keys.lua b/core/keys.lua index 28beb536..de4ff0e2 100644 --- a/core/keys.lua +++ b/core/keys.lua @@ -58,7 +58,7 @@ module('keys')]] -- The default value is 'c'. -- + `ALT` [string] -- The string representing the Alt/option key. --- The default value is 'a' +-- The default value is 'a'. -- + `META` [string] -- The string representing the Command key on Mac OSX. -- The default value is 'm'. @@ -268,8 +268,8 @@ local function get_gdk_key(key_seq) local mods, key = key_seq:match('^([cams]*)(.+)$') if not mods or not key then return nil end local modifiers = ((mods:find('s') or key:lower() ~= key) and 1 or 0) + - (mods:find('c') and (not OSX and 4 or 128) or 0) + - (mods:find('a') and 8 or 0) + (mods:find('m') and 4 or 0) + (mods:find('c') and 4 or 0) + (mods:find('a') and 8 or 0) + + (mods:find('m') and 268435456 or 0) local byte = string_byte(key) if #key > 1 or byte < 32 then for i, s in pairs(M.KEYSYMS) do |