History
← Older revision
Revision as of 12:58, 12 October 2016
(6 intermediate revisions by the same user not shown)
Line 128:
Line 128:
====Hotkeys====
====Hotkeys====
−
command_id can be: str(int_command_code) or "module,method" or "module,method,param".
+
Notes:
+
+
*
command_id can be: str(int_command_code) or "module,method" or "module,method,param".
+
+
Actions:
−
* PROC_GET_ESCAPE: Gets
escape flag
(bool). This flag is set when user presses Esc key (each Esc press is counted since app start). Note: to allow app to handle key press in long loop, call msg_status('text', True).
+
* PROC_GET_ESCAPE: Gets
Esc-key state
(bool). This flag is set when user presses Esc key (each Esc press is counted since app start). Note: to allow app to handle key press in long loop, call msg_status('text', True).
−
* PROC_SET_ESCAPE: Sets
escape
flag. Text must be "0"/"1".
+
* PROC_SET_ESCAPE: Sets
Esc-key
flag. Text must be "0"/"1".
* PROC_GET_HOTKEY: Gets hotkeys strings for given command_id. Examples of result: "F1", "Ctrl+B * B", "Ctrl+B * B * C|Ctrl+B * D" (two hotkeys for one command). Gets empty str for unknown command_id.
* PROC_GET_HOTKEY: Gets hotkeys strings for given command_id. Examples of result: "F1", "Ctrl+B * B", "Ctrl+B * B * C|Ctrl+B * D" (two hotkeys for one command). Gets empty str for unknown command_id.
* PROC_SET_HOTKEY: Sets hotkeys for given command_id from strings. Text must be "command_id|hotkey1|hotkey2", where hotkey1/hotkey2 examples: "F1", "Ctrl+B * B", "Ctrl+B * B * C". Symbol "*" can be without near spaces. Gets bool: command_id exists, changed.
* PROC_SET_HOTKEY: Sets hotkeys for given command_id from strings. Text must be "command_id|hotkey1|hotkey2", where hotkey1/hotkey2 examples: "F1", "Ctrl+B * B", "Ctrl+B * B * C". Symbol "*" can be without near spaces. Gets bool: command_id exists, changed.
* PROC_GET_KEYSTATE: Gets state of pressed special keys. String has "c" for Ctrl pressed, "a" for Alt, "s" for Shift, "m" for Meta (Windows key).
* PROC_GET_KEYSTATE: Gets state of pressed special keys. String has "c" for Ctrl pressed, "a" for Alt, "s" for Shift, "m" for Meta (Windows key).
+
* PROC_HOTKEY_INT_TO_STR: Converts given int hotkey to string. Gets empty str for unknown code.
+
* PROC_HOTKEY_STR_TO_INT: Converts given string hotkey to int. Gets 0 for incorrect string. Example: converts "alt+shift+z" to "41050", which is then converted to "Shift+Alt+Z".
====Python====
====Python====
Line 552:
Line 558:
====Result====
====Result====
−
Dialog is closed by clicking any button or by changing
in
any control which has "act=1". Gets 2-tuple: (control_index, state_text), gets None if cancelled.
+
Dialog is closed by clicking any button or by changing
of
any control which has "act=1". Gets 2-tuple: (control_index, state_text), gets None if cancelled.
* control_index: index of control which closed dialog (0-based).
* control_index: index of control which closed dialog (0-based).
−
* state_text: "\n"-separated values of controls
(same
count of items as in text).
+
* state_text: "\n"-separated values of controls
. Same
count of items as in text
, plus optional additional lines in the form "key=value":
+
** focused=N: index of last focused control (0-based
)
or -1
.
====Notes====
====Notes====
Line 1,169:
Line 1,176:
1.0.156
1.0.156
* add: ed.complete: added param alt_order
* add: ed.complete: added param alt_order
+
* add: app_proc: PROC_HOTKEY_INT_TO_STR, PROC_HOTKEY_STR_TO_INT
* add: dlg_custom: "type=colorpanel"
* add: dlg_custom: "type=colorpanel"
+
* add: dlg_custom: result has additional line "focused=N"
* add: file_open can install addons, where files are not in root, but in subdir
* add: file_open can install addons, where files are not in root, but in subdir
* add: install.inf: can write lexers list in [info] $var=Name1,Name2,Name3 ; use it like "lexers=$var"
* add: install.inf: can write lexers list in [info] $var=Name1,Name2,Name3 ; use it like "lexers=$var"