To: vim_dev@googlegroups.com Subject: Patch 8.2.4800 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.2.4800 (after 8.2.4798) Problem: Missing test update for adjusted t_8u behavior. Solution: Update and extend the test. Files: src/testdir/test_termcodes.vim *** ../vim-8.2.4799/src/testdir/test_termcodes.vim 2022-03-18 15:41:13.366489671 +0000 --- src/testdir/test_termcodes.vim 2022-04-20 19:53:25.527749356 +0100 *************** *** 1783,1788 **** --- 1783,1810 ---- call test_override('term_props', 0) endfunc + func Do_check_t_8u_set_reset(set_by_user) + set ttymouse=xterm + call test_option_not_set('ttymouse') + let default_value = "\[58;2;%lu;%lu;%lum" + let &t_8u = default_value + if !a:set_by_user + call test_option_not_set('t_8u') + endif + let seq = "\[>0;279;0c" + call feedkeys(seq, 'Lx!') + call assert_equal(seq, v:termresponse) + call assert_equal('sgr', &ttymouse) + + call assert_equal(#{ + \ cursor_style: 'u', + \ cursor_blink_mode: 'u', + \ underline_rgb: 'u', + \ mouse: 's' + \ }, terminalprops()) + call assert_equal(a:set_by_user ? default_value : '', &t_8u) + endfunc + " This checks the xterm version response. " This must be after other tests, because it has side effects to xterm " properties. *************** *** 1847,1868 **** \ mouse: 's' \ }, terminalprops()) ! " xterm >= 279: "sgr" and cursor_style not reset; also check t_8u reset ! set ttymouse=xterm ! call test_option_not_set('ttymouse') ! let &t_8u = "\[58;2;%lu;%lu;%lum" ! let seq = "\[>0;279;0c" ! call feedkeys(seq, 'Lx!') ! call assert_equal(seq, v:termresponse) ! call assert_equal('sgr', &ttymouse) ! ! call assert_equal(#{ ! \ cursor_style: 'u', ! \ cursor_blink_mode: 'u', ! \ underline_rgb: 'u', ! \ mouse: 's' ! \ }, terminalprops()) ! call assert_equal('', &t_8u) set t_RV= call test_override('term_props', 0) --- 1869,1878 ---- \ mouse: 's' \ }, terminalprops()) ! " xterm >= 279: "sgr" and cursor_style not reset; also check t_8u reset, ! " except when it was set by the user ! call Do_check_t_8u_set_reset(0) ! call Do_check_t_8u_set_reset(1) set t_RV= call test_override('term_props', 0) *** ../vim-8.2.4799/src/version.c 2022-04-20 19:47:31.699946601 +0100 --- src/version.c 2022-04-20 19:54:26.339715915 +0100 *************** *** 748,749 **** --- 748,751 ---- { /* Add new patch number below this line */ + /**/ + 4800, /**/ -- The History of every major Galactic Civilization tends to pass through three distinct and recognizable phases, those of Survival, Inquiry and Sophistication, otherwise known as the How, Why and Where phases. For instance, the first phase is characterized by the question 'How can we eat?' the second by the question 'Why do we eat?' and the third by the question 'Where shall we have lunch?' -- Douglas Adams, "The Hitchhiker's Guide to the Galaxy" /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///