To: vim_dev@googlegroups.com Subject: Patch 8.1.1299 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.1.1299 Problem: "extends" from 'listchars' is used when 'list' is off. (Hiroyuki Yoshinaga) Solution: Only use the "extends" character when 'list' is on. (Hirohito Higashi, closes #4360) Files: src/screen.c, src/testdir/test_listchars.vim *** ../vim-8.1.1298/src/screen.c 2019-05-05 15:47:37.825923529 +0200 --- src/screen.c 2019-05-08 20:20:27.436236341 +0200 *************** *** 5594,5601 **** break; } ! /* line continues beyond line end */ ! if (lcs_ext && !wp->w_p_wrap #ifdef FEAT_DIFF && filler_todo <= 0 --- 5594,5603 ---- break; } ! // Show "extends" character from 'listchars' if beyond the line end and ! // 'list' is set. ! if (lcs_ext != NUL ! && wp->w_p_list && !wp->w_p_wrap #ifdef FEAT_DIFF && filler_todo <= 0 *** ../vim-8.1.1298/src/testdir/test_listchars.vim 2019-04-04 13:28:41.201589932 +0200 --- src/testdir/test_listchars.vim 2019-05-08 20:14:19.686543989 +0200 *************** *** 110,115 **** --- 110,134 ---- call cursor(1, 1) call assert_equal([expected], ScreenLines(1, virtcol('$'))) + " test extends + normal ggdG + set listchars=extends:Z + set nowrap + set nolist + call append(0, [ repeat('A', &columns + 1) ]) + + let expected = repeat('A', &columns) + + redraw! + call cursor(1, 1) + call assert_equal([expected], ScreenLines(1, &columns)) + + set list + let expected = expected[:-2] . 'Z' + redraw! + call cursor(1, 1) + call assert_equal([expected], ScreenLines(1, &columns)) + enew! set listchars& ff& endfunc *** ../vim-8.1.1298/src/version.c 2019-05-08 18:36:40.060562551 +0200 --- src/version.c 2019-05-08 20:18:13.965070043 +0200 *************** *** 769,770 **** --- 769,772 ---- { /* Add new patch number below this line */ + /**/ + 1299, /**/ -- Living on Earth includes an annual free trip around the Sun. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///