|
C-Menu 0.2.9
A User Interface Toolkit
|
NotCurses UI backend — input handling. More...
#include "ui_backend.h"#include "ui_notcurses_internal.h"#include <notcurses/notcurses.h>#include <string.h>#include <termios.h>Go to the source code of this file.
Functions | |
| uint | get_plane_idx (UiSurface *s, struct ncplane *plane) |
| NcPlane * | ncplane_clicked (UiSurface *s, uint w, ncinput *ni) |
| int | ui_get_event (UiSurface *s, uint w, UiEvent *ev, int timeout_ms) |
| Wait for an input event from the NotCurses context. | |
| int | ui_get_event_multi (UiSurface *s, uint w, UiEvent *ev, int timeout_ms) |
| int | ui_get_event_multix (UiSurface *s, uint w, UiEvent *ev, int timeout_ms) |
| int | ui_get_event_no_mouse (UiSurface *target, uint w, UiEvent *ev) |
| int | ui_getch () |
NotCurses UI backend — input handling.
Translates NotCurses ncinput events into the portable UiEvent representation defined in ui_backend.h.
Definition in file ui_notcurses_input.c.
| uint get_plane_idx | ( | UiSurface * | s, |
| struct ncplane * | plane ) |
Definition at line 249 of file ui_notcurses_input.c.
References SUB_SFC_MAX.
Referenced by ui_get_event_multi().
Definition at line 259 of file ui_notcurses_input.c.
Wait for an input event from the NotCurses context.
Wait for an input event on target (or stdscr if NULL).
| ui | UI runtime context. |
| target | Unused for NotCurses (events are global to the context). |
| ev | Output UiEvent structure. |
| timeout_ms | Milliseconds to wait; -1 = block indefinitely. |
ui or ev is NULL. Definition at line 104 of file ui_notcurses_input.c.
References UiEvent::alt, UiEvent::bstate, UiEvent::ch, UiEvent::ctrl, UiEvent::key, UiEvent::mouse_action, UiEvent::mouse_inside, UiRuntime::nc, UiEvent::shift, ui, UI_KEY_CHAR, UI_KEY_MOUSE, UI_MOUSE_PRESS, UI_MOUSE_RELEASE, UI_MOUSE_SCROLL_DOWN, UI_MOUSE_SCROLL_UP, UiEvent::x, and UiEvent::y.
Referenced by action_disposition(), answer_yn(), cf_accept(), display_error(), menu_cmd_processor(), notcurses_input(), and Perror().
Definition at line 181 of file ui_notcurses_input.c.
References UiEvent::alt, UiEvent::bstate, UiEvent::ch, UiEvent::chyron, UiEvent::ctrl, get_plane_idx(), UiEvent::in_win, UiEvent::key, UiEvent::mouse_action, UiRuntime::nc, ncplane_clicked(), UiEvent::shift, SUB_SFC_MAX, ui, UI_KEY_CHAR, UI_KEY_MOUSE, UI_MOUSE_NONE, UI_MOUSE_PRESS, UI_MOUSE_RELEASE, UI_MOUSE_SCROLL_DOWN, UI_MOUSE_SCROLL_UP, WIN, UiEvent::x, and UiEvent::y.
Referenced by field_editor(), form_post(), form_process(), and picker().
Definition at line 164 of file ui_notcurses_input.c.
References UiRuntime::nc, and ui.
Definition at line 229 of file ui_notcurses_input.c.
References UiEvent::alt, UiEvent::ch, UiEvent::ctrl, UiEvent::key, UiRuntime::nc, UiEvent::shift, ui, and UI_KEY_CHAR.
Referenced by get_cmd_char().
| int ui_getch | ( | ) |
Definition at line 151 of file ui_notcurses_input.c.
References nc, UiRuntime::nc, and ui.
Referenced by ui_notcurses_init().