aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/term.c
Commit message (Collapse)AuthorAge
* refactor: Remove term modules and termcap optionsThiago de Arruda2015-02-21
| | | | | | | | | | | | | | | - Removed term.c, term.h and term_defs.h - Tests for T_* values were removed. screen.c was simplified as a consequence(the best strategy for drawing is implemented in the UI layer) - Redraw functions now call ui.c functions directly. Updates are flushed with `ui_flush()` - Removed all termcap options(they now return empty strings for compatibility) - &term/&ttybuiltin options return a constant value(nvim) - &t_Co is still available, but it mirrors t_colors directly - Remove cursor tracking from screen.c and the `screen_start` function. Now the UI is expected to maintain cursor state across any call, and reset it when resized. - Remove unused code
* Enable -Wconversion: Passing-by: Remove dead code (MACOS_CONVERT).Eliseo Martínez2015-02-18
| | | | MacOS (pre Mac OS X) is not supported anymore.
* Enable -Wconversion: ui.c.Eliseo Martínez2015-02-18
| | | | | | | | | | | | | | | Refactoring summary: - ui_write(): len: int --> size_t * parse_abstract_ui_codes(): len: int --> size_t * string_convert(): lenp: int * --> size_t * - string_convert_ext(): lenp : int * --> size_t * unconvlenp: int * --> size_t * * utf8len_tab_zero: char[] --> uint8_t[] * iconv_string(): slen : int --> size_t unconvlenp: int * --> size_t * resultlenp: int * --> size_t * - mch_print_text_out(): len: int --> size_t * out_pos: int --> size_t
* cleanup: Remove unused functions and builtin termcapsThiago de Arruda2015-02-16
|
* ui: Remove/adapt some old code for a big UI refactorThiago de Arruda2015-02-16
| | | | | | | | | | | | | - Remove abstract_ui global, now it is always active - Remove some terminal handling code - Remove unused functions - Remove HAVE_TGETENT/TERMINFO/TERMIOS/IOCTL #ifdefs - Remove tgetent/terminfo from version.c - Remove curses/terminfo dependencies - Only start/stop termcap when starting/exiting the program - msg_use_printf will return true if there are no attached UIs( messages will be written to stdout) - Remove `ex_winpos`(implement `:winpos` with `ex_ni`)
* fix #1839: decrement mouse row and colglebtv2015-01-26
| | | | - regression by 04c0658024a98a0586997f0ea8af1e3f774cc83e
* Merge pull request #1816 from Pyrohh/macro_cleanupJustin M. Keyes2015-01-15
|\ | | | | Macro cleanup
| * Macro cleanup: PROTOMichael Reed2015-01-14
| | | | | | | | | | | | Regarding dict_lookup() in eval.c: both definitions are the same, the only difference being the spacing between the indirection operator and the indentation level.
* | term: Fix shell_resized for abstract_uiThiago de Arruda2015-01-13
| |
* | ui: Fix redraw bug caused by race conditions with remote clientsThiago de Arruda2015-01-13
| | | | | | | | | | Before sending a resize command to the UIs, flush the current output buffer to ensure no redraw commands for a screen with invalid size are processed.
* | ui: Fix out_flush/ui_write behavior to always flush for abstract_uiThiago de Arruda2015-01-13
| |
* | ui: Add mising T_CSV code to abstract_ui termcapThiago de Arruda2015-01-13
|/ | | | | This code is required for screen.c to set a vertical scroll region, which is a great optimization when scrolling vertically split windows.
* Remove QNX/pterm remnantsMichael Reed2015-01-11
| | | | | The function qnx_init() (wrapped in an ifdef in main.c) doesn't even exist.
* Cleanup: Rename getdigits() family functions.Eliseo Martínez2015-01-11
|
* Cleanup: Refactor variables: long --> int.Eliseo Martínez2015-01-11
| | | | | | | | | At 31c8440fee0bd694093d83af5dee20e3c3dc876c, some variables were changed from int to long, to avoid -Wconversion errors. Long type was the appropiate one because getdigits() was returning a long. Now that we have get_int_digits() and get_long_digits(), we can revert mentioned variables to int, and use get_int_digits() without having -Wconversion warnings.
* Cleanup: Refactor getdigits().Eliseo Martínez2015-01-11
| | | | | | | | | | | | | | | | Problem : getdigits() currently returns a long, but at most places, return value is casted (unsafely) into an int. Making casts safe would introduce a lot of fuss in the form of assertions checking for limits. Note : We cannot just change return type to int, because, at some places, legitimate long values are used. For example, in diff.c, for line numbers. Solution : Introduce new functions: - get_digits() : Gets an intmax_t from a string. - get_int_digits() : Wrapper for ints. - get_long_digits() : Wrapper for longs. And replace getdigits() invocations by the appropiate wrapper invocations.
* Remove long_u: term: Remove dead code using long_u.Eliseo Martínez2015-01-10
| | | | | get_long_from_buf() seems not to be used anywhere, and is the only place where instances of long_u remain at term.c.
* Remove long_u: term: Enable -Wconversion.Eliseo Martínez2015-01-10
|
* globals.h: Remove unused global variableSteven Oliver2015-01-02
|
* Remove Amiga remnantsMichael Reed2014-12-19
| | | | | | | | | Notes regarding the removal of specific items: - Aztec C: only on the Amiga. - mch_check_win(): doesn't exist anymore. - Comment in ex_cmds.c: It seems the context for this comment was removed, but the comment was inadvertantly left alone.
* docs: Remove BeOS/Haiku remnantsMichael Reed2014-12-09
|
* ui: Add abstract_ui termcap and split UI layerThiago de Arruda2014-12-08
| | | | | | | | | | | | | | | | | | This is how Nvim behaves when the "abstract_ui" termcap is activated: - No data is written/read to stdout/stdin by default. - Instead of sending data to stdout, ui_write will parse the termcap codes and invoke dispatch functions in the ui.c module. - The dispatch functions will forward the calls to all attached UI instances(each UI instance is an implementation of the UI layer and is registered with ui_attach). - Like with the "builtin_gui" termcap, "abstract_ui" does not contain any key sequences. Instead, vim key strings(<cr>, <esc>, etc) are parsed directly by input_enqueue and the translated strings are pushed to the input buffer. With this new input model, its not possible to send mouse events yet. Thats because mouse sequence parsing happens in term.c/check_termcodes which must return early when "abstract_ui" is activated.
* mouse: Remove CHECK_DOUBLE_CLICK conditionalsThiago de Arruda2014-12-02
| | | | This is now always defined.
* term: Move more mouse functions to mouse.cThiago de Arruda2014-12-02
|
* term: Remove most calls to settmodeThiago de Arruda2014-12-02
| | | | | | Nvim now relies much less on setting terminal mode to cooked mode, remove most calls to settmode, except for those that happen on startup or when suspending. Eventually even those will be handled by the UI layer.
* term: Move "set_shellsize" to screen.c as "screen_resize"Thiago de Arruda2014-12-02
|
* Merge pull request #1491 from Pyrohh/os2-and-misc-cleanupJustin M. Keyes2014-11-28
|\ | | | | Remove MiNT, NeXTSTEP, OS/2 References
| * Remove Atari MiNT referencesMichael Reed2014-11-27
| |
* | mch_init -> term_initScott Prager2014-11-28
| |
* | mch_write -> term_writeScott Prager2014-11-28
|/ | | | | | Switch from POSIX's write() to fwrite(stdout,...) and disable buffering since vim buffers output explicitly and flushes when needed, like when a key is typed.
* ui: Remove ui_delay, ui_breakcheck and ui_set_shellsizeThiago de Arruda2014-11-27
| | | | | These functions only used to call another os_* function, so remove them and replace all occurences in the project.
* vim-patch:7.4.359Scott Prager2014-09-19
| | | | | | | | | Problem: When 'ttymouse' is set to 'uxterm' the xterm version is not requested. (Tomas Janousek) Solution: Do not mark uxterm as a conflict mouse and add resume_get_esc_sequence(). https://code.google.com/p/vim/source/detail?r=v7-4-359
* vim-patch:7.4.305Scott Prager2014-09-19
| | | | | | | | | | Problem: Making 'ttymouse' empty after the xterm version was requested causes problems. (Elijah Griffin) Solution: Do not check for DEC mouse sequences when the xterm version was requested. Also don't request the xterm version when DEC mouse was enabled. https://code.google.com/p/vim/source/detail?r=v7-4-305
* api: Implement '--embedded-mode' command-line optionThiago de Arruda2014-08-28
| | | | | This option makes nvim run in "embedded mode", which creates an API channel via stdin/stdout and disables all terminal-related code
* Make ttyfast default to true on all terminals #1051Fredrik Fornwall2014-08-18
|
* Merge #814 'Remove dead #ifdefed code'Justin M. Keyes2014-08-07
|\
| * Remove EBCDIC: Remove IF_EB macrosPavel Platto2014-08-02
| |
| * Remove BEOS_PR_OR_BETTERPavel Platto2014-08-02
| |
| * Remove BeOS DR8 specific hackPavel Platto2014-08-02
| | | | | | | | It is already partially removed from screen.c
* | Remove unused USE_TERM_CONSOLE ifdefs #1015Fredrik Fornwall2014-08-07
| | | | | | | | This is unused after dropped amiga and msdos support.
* | Drop SGI IRIS support. #1006Fredrik Fornwall2014-08-07
|/
* Partial C99 cleanup of term.c #1020Fredrik Fornwall2014-08-01
|
* Remove FEAT_MOUSE_JSBFredrik Fornwall2014-07-29
| | | | This is never built and references some obscure jsb terminal
* term: replace gettimeofday()Nicolas Hillegeer2014-07-21
| | | | | | | | gettimeofday() is not portable, replace with os_hrtime() wherever possible. The new code should behave equivalently to the old implementation. Because of this, HAVE_GETTIMEOFDAY is no longer necessary To be able to handle double clicks.
* Use strict function prototypes #945Pavel Platto2014-07-14
| | | | | | | | | | | | | | | | | | | `-Wstrict-prototypes` warn if a function is declared or defined without specifying the argument types. This warning disallow function prototypes with empty parameter list. In C, a function declared with an empty parameter list accepts an arbitrary number of arguments when being called. This is for historic reasons; originally, C functions didn't have prototypes, as C evolved from B, a typeless language. When prototypes were added, the original typeless declarations were left in the language for backwards compatibility. Instead we should provide `void` in argument list to state that function doesn't have arguments. Also this warning disallow declaring type of the parameters after the parentheses because Neovim header generator produce no declarations for old-stlyle prototypes: it expects to find `{` after prototype.
* Include stdbool.h in some files which use itPavel Platto2014-07-11
| | | | | | | Done by manual inspection of the output of this script: grep -r -l -w "bool\|true\|false" * | grep 'c$\|h$' > has_bool grep -r -l "stdbool.h" * | grep 'c$\|h$' > has_include grep -F -x -v -f has_include has_bool
* move errno.h include out of vim.hBrandon Coleman2014-07-09
|
* move <inttypes.h> include out of vim.hBrandon Coleman2014-07-09
|
* move ascii.h include out of vim.hBrandon Coleman2014-07-09
|
* Replaced most TRUE/FALSE macros in arabic, mbyte and spell. #645Klemen Košir2014-07-08
|