aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
Commit message (Collapse)AuthorAge
* vim-patch:8.0.0370: invalid memory access when setting wildchar emptyJan Edmund Lazo2018-09-23
| | | | | | | | Problem: Invalid memory access when setting wildchar empty. Solution: Avoid going over the end of the option value. (Dominique Pelle, closes vim/vim#1509) Make option test check all number options with empty value. https://github.com/vim/vim/commit/a12e40351d1357687e8b5dc3122fffef705bdc08
* vim-patch:8.1.0414: v:option_old is cleared when using :set in OptionSet autocmdJan Edmund Lazo2018-09-22
| | | | | | | Problem: v:option_old and v:option_new are cleared when using :set in OptionSet autocmd. (Gary Johnson) Solution: Don't trigger OptionSet recursively. https://github.com/vim/vim/commit/3f3fb0b14734272e7c817020c847aaa0fba5cea5
* style: fixing minor issues noted in code review.ZviRackover2018-08-06
|
* lint: clean-up after parent commitZviRackover2018-08-06
|
* Remove all occurences of the mb_ptr2char macroZviRackover2018-08-06
| | | | | | | First step towards implemening issue #7401. The same can be done for all deprecated mb_ functions in follow-up patches.
* vim-patch:8.0.0704: problems with autocommands when opening helpJan Edmund Lazo2018-06-25
| | | | | | | Problem: Problems with autocommands when opening help. Solution: Avoid using invalid "varp" value. Allow using :wincmd if buffer is locked. (closes vim/vim#1806, closes vim/vim#1804) https://github.com/vim/vim/commit/163095f088a7c29710a16c75bb56229dd3b4116a
* vim-patch:8.1.0107: getting buffer option clears message (#8637)Jacob Niehus2018-06-24
| | | | | | | | | | | | https://github.com/vim/vim/commit/defe6424aee6201241b7cb231b62db4bbb9f4a9f Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jun 24 15:14:07 2018 +0200 patch 8.1.0107: Python: getting buffer option clears message Problem: Python: getting buffer option clears message. (Jacob Niehus) Solution: Don't use aucmd_prepbuf(). (closes #3079)
* vim-patch:8.0.0616: not always setting 'background' correctly after :hi ↵Jan Edmund Lazo2018-06-21
| | | | | | | | | | | | | | Normal (#8606) Problem: When setting the cterm background with ":hi Normal" the value of 'background' may be set wrongly. Solution: Check that the color is less than 16. Don't set 'background' when it was set explicitly. (Lemonboy, closes vim/vim#1710) https://github.com/vim/vim/commit/1615b36b91b094263240d7b555283ddf33208f62 Restore reset_option_was_set(), removed in 419da839e0cbdf6251bc31dc218fa629ccc91b44 ref #8595 ref #8597
* vim-patch:8.0.0546: swap file exists briefly when opening the command window ↵Jan Edmund Lazo2018-06-19
| | | | | | | | (#8588) Problem: Swap file exists briefly when opening the command window. Solution: Set the noswapfile command modifier before splitting the window. (James McCoy, closes vim/vim#1620) https://github.com/vim/vim/commit/3bab93998d01a01b7f2a071fa3b8054bb0094625
* Merge #8526 from janlazo/vim-8.0.0451Justin M. Keyes2018-06-16
|\
| * vim-patch:8.0.0451: some macros are in lower caseJan Edmund Lazo2018-06-12
| | | | | | | | | | | | | | Problem: Some macros are in lower case. Solution: Make a few more macros upper case. Avoid lower case macros use an argument twice. https://github.com/vim/vim/commit/91acfffc1e6c0d8c2abfb186a0e79a5bf19c3f3f
* | fillchars: make checks more strict and improve testsBjörn Linse2018-06-14
| |
* | Add ‘eob’ option to fillcharsJack Bracewell2018-06-13
| | | | | | | | | | This option allows configuring what character is shown on the empty lines at the end of a buffer, previously hardcoded to ‘~’
* | options: remove 'maxcombine` option (always use 6)Björn Linse2018-06-13
|/
* vim-patch:8.0.0466: still macros that should be all-caps (#8510)Jan Edmund Lazo2018-06-10
| | | | | Problem: There are still a few macros that should be all-caps. Solution: Make a few more macros all-caps. https://github.com/vim/vim/commit/8820b48654b62472821d9b155fe03ab7ac13a05c
* vim-patch:8.0.1237: ":set scroll&" often gives an error (#8473)Jan Edmund Lazo2018-06-04
| | | | | | | Problem: ":set scroll&" often gives an error. Solution: Don't use a fixed default value, use half the window height. Add a test. (Ozaki Kiichi, closes vim/vim#2104) https://github.com/vim/vim/commit/af2d20c6285c1d2973e3d9b5e8f727e3ed180493
* vim-patch:8.0.0342: double free with EXITFREE and setting 'ttytype'Justin M. Keyes2018-05-19
| | | | | | | Problem: Double free when compiled with EXITFREE and setting 'ttytype'. Solution: Avoid setting P_ALLOCED on 'ttytype'. (Dominique Pelle, closes vim/vim#1461) https://github.com/vim/vim/commit/673911457d6745b6b779eb769c2f41965592d12c
* cleanupJustin M. Keyes2018-05-18
|
* do not pass NULL to os_getenvJustin M. Keyes2018-05-18
| | | | closes #8393
* Merge #8329 'API: Make nvim_set_option() update `:verbose set …`'Justin M. Keyes2018-05-11
|\
| * lintb-r-o-c-k2018-05-10
| |
| * api: Make nvim_set_option() update `:verbose set ...`b-r-o-c-k2018-05-03
| | | | | | | | | | | | Make `:verbose set ...` show when an option was last modified by an API client or Lua script/chunk. In the case of an API client, the channel ID is displayed.
* | Merge #4486 'refactor: Remove maxmem, maxmemtot options'Justin M. Keyes2018-05-02
|\ \ | |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | After this change we never release blocks from memory (in practice it never happened because the memory limits are never reached). Let the OS take care of that. --- On today's systems the 'maxmem' and 'maxmemtot' values are huge (4+ GB) so the limits are never reached in practice, but Vim wastes a lot of time checking if the limit was reached. If the limit is reached Vim starts saving pieces of the swap file that were in memory to the disk. Said in a different way: Vim implements its own memory-paging mechanism. This is unnecessary and inefficient since the operating system already has virtual memory and will swap to the disk if programs start using too much memory. This change does... 1. Reduce the number of config options and need for documentation. 2. Make the code more efficient as we don't have to keep track of memory usage nor check if the memory limits were reached to start swapping to disk every time we need memory for buffers. 3. Simplify the code. Once memfile.c is simple enough it could be replaced by actual operating system memory mapping (mmap, MemoryViewOfFile...). This change does not prevent Vim to recover changes from swap files since the swapping code is never triggered with the huge limits set by default.
| * Remove maxmem and maxmemtot optionsFelipe Oliveira Carvalho2017-04-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | > The option 'maxmem' ('mm') is used to set the maximum memory used for one > buffer (in kilobytes). 'maxmemtot' is used to set the maximum memory used for > all buffers (in kilobytes). The defaults depend on the system used. These > are not hard limits, but tell Vim when to move text into a swap file. If you > don't like Vim to swap to a file, set 'maxmem' and 'maxmemtot' to a very large > value. The swap file will then only be used for recovery. If you don't want > a swap file at all, set 'updatecount' to 0, or use the "-n" argument when > starting Vim. On today's systems these values are huge (4GB in my machine with 8GB of RAM since it's set as half the available memory by default) so the limits are never reached in practice, but Vim wastes a lot of time checking if the limit was reached. If the limit is reached Vim starts saving pieces of the swap file that were in memory to the disk. Said in a different way: Vim implements its own memory swapping mechanism. This is unnecessary and inefficient since the operating system already virtualized the memory and will swap to the disk if programs start using too much memory. This change does... 1. Reduce the number of config options and need for documentation. 2. Make the code more efficient as we don't have to keep track of memory usage nor check if the memory limits were reached to start swapping to disk every time we need memory for buffers. 3. Simplify the code. Once `memfile.c` is simple enough it could be replaced by actual operating system memory mapping (`mmap`, `MemoryViewOfFile`...). This change does not prevent Vim to recover changes from swap files since the swapping code is never triggered with the huge limits set by default.
* | option: Silence PVS/V547: expression is true on 64-bit systemsZyX2018-04-16
| |
* | option: Fix PVS/V547: var is always NULL at that pointZyX2018-04-16
| |
* | option: Fix PVS/V560: EXPAND_BOOL_SETTINGS already caused early returnZyX2018-04-16
| |
* | option: Fix PVS/V547: allocator never returns NULL nowZyX2018-04-16
| |
* | option: Fix PVS/V517: duplicate check for titlelenZyX2018-04-16
| |
* | option: Silence PVS/V594: GLOBAL_WO macros is not really necessaryZyX2018-04-16
| | | | | | | | In that case it is completely possible to just use w_allbuf_opt directly.
* | msg: do not scroll entire screen (#8088)Björn Linse2018-03-31
| |
* | Merge branch 'master' into yagebu/option-fixesJames McCoy2018-03-28
|\ \
| * | build/msvc: Workaround for compiler optimization bugb-r-o-c-k2018-03-04
| | |
| * | 'fillchars': fix defaults logic; handle ambiwidth=double #7986Matthieu Coudron2018-02-23
| | | | | | | | | | | | Update tests.
| * | vim-patch-8.0.0649 and vim-patch-8.0.0650: autocmd open help 2 timesNimit Bhardwaj2018-02-17
| | |
| * | lintJustin M. Keyes2018-02-11
| | |
| * | vim-patch:8.0.0975: using freed memory when setting 'backspace'Justin M. Keyes2018-02-11
| | | | | | | | | | | | | | | | | | | | | Problem: Using freed memory when setting 'backspace'. Solution: When changing oldval also change origval. https://github.com/vim/vim/commit/edbc0d46cffe1766d0b330dc2842212cff644f8e
| * | vim-patch:8.0.0974: resetting a string option does not trigger OptionSetJustin M. Keyes2018-02-11
| | | | | | | | | | | | | | | | | | | | | Problem: Resetting a string option does not trigger OptionSet. (Rick Howe) Solution: Set the origval. https://github.com/vim/vim/commit/8efa026a25b95de5598535ef62505282a8584a4b
| * | vim-patch:8.0.0703: illegal memory access with empty :doau commandJustin M. Keyes2018-02-11
| | | | | | | | | | | | | | | | | | | | | Problem: Illegal memory access with empty :doau command. Solution: Check the event for being out of range. (James McCoy) https://github.com/vim/vim/commit/faf29d7f91477c25c85d9d7165d90e8d8f1c512e
| * | vim-patch:8.0.0676: crash when closing quickfix window in autocmdJustin M. Keyes2018-02-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Crash when closing the quickfix window in a FileType autocommand that triggers when the quickfix window is opened. Solution: Save the new value before triggering the OptionSet autocommand. Add the "starting" flag to test_override() to make the text work. https://github.com/vim/vim/commit/182a17b1e80b92826204d967808df0d30eb2ef27
| * | vim-patch:8.0.0448: some macros are lower case (#7936)KunMing Xie2018-01-30
| | | | | | | | | | | | | | | | | | | | | Problem: Some macros are in lower case, which can be confusing. Solution: Make a few lower case macros upper case. https://github.com/vim/vim/commit/b5aedf3e228d35821591da9ae8501b61cf2e264c ref #6297
| * | Fix lint error in option.cGeorge Zhao2018-01-19
| | |
| * | Fix warning about conversion on mingw64George Zhao2018-01-18
| | |
| * | vim-patch:8.0.0420: text garbled when the system encoding differs from ↵James McCoy2017-12-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 'encoding' Problem: When running :make the output may be in the system encoding, different from 'encoding'. Solution: Add the 'makeencoding' option. (Ken Takata) https://github.com/vim/vim/commit/2c7292dc5bbf155fe2192d417363b8c085759cad
| * | vim-patch:8.0.0074Michael Schupikov2017-12-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Cannot make Vim fail on an internal error. Solution: Add IEMSG() and IEMSG2(). (Domenique Pelle) Avoid reporting an internal error without mentioning where. https://github.com/vim/vim/commit/95f096030ed1a8afea028f2ea295d6f6a70f466f Signed-off-by: Michael Schupikov <michael@schupikov.de>
| * | ui: forward relevant option updates to UIs (#7520)Björn Linse2017-12-12
| | | | | | | | | also make termguicolors mutable after startup
| * | mac: Set $LANG based on the system localeJames McCoy2017-12-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | Unix's typical locale-related environment variables aren't always set appropriately on a Mac. Instead of relying on them, query the locale information using Mac specific APIs and then set $LANG appropriately for the rest of nvim. Closes #5873
| * | tui: dump termcap info if -V3 ('verbose' >= 3)Justin M. Keyes2017-12-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | Get terminal debugging info by starting Nvim with 'verbose' level 3: nvim -V3log This is like Vim's `:set termcap`, which was removed in Nvim (and would be very awkward to restore because of the decoupled UI).
| * | lintJustin M. Keyes2017-11-27
| | |
| * | tui: expose terminal type in 'term' optionJustin M. Keyes2017-11-27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since "builtin" terminfo definitions were implemented (7cbf52db1bdf), the decisions made by tui.c and terminfo.c are more relevant. Exposing that decision in the 'term' option helps with troubleshooting. Also: remove code that allowed setting t_Co. `:set t_Co=…` has never worked; the highlight_spec test asserting that nvim_set_option('t_Co') _does_ work makes no sense, and should not have worked.