Mercurial > vim
comparison src/testdir/test_cursor_func.vim @ 15492:126cdab63a83 v8.1.0754
patch 8.1.0754: preferred column is lost when setting 'cursorcolumn'
commit https://github.com/vim/vim/commit/177ab9e0262b1b3a6120bea655864ead487210e5
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Jan 15 21:12:57 2019 +0100
patch 8.1.0754: preferred column is lost when setting 'cursorcolumn'
Problem: Preferred column is lost when setting 'cursorcolumn'.
Solution: Change option flag to P_RWINONLY. (Takayuki Kurosawa,
closes #3806)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 15 Jan 2019 21:15:05 +0100 |
parents | 1c4ebbae41d2 |
children | 81be817c9d9a |
comparison
equal
deleted
inserted
replaced
15491:14431f051f9c | 15492:126cdab63a83 |
---|---|
44 call assert_equal('-X---', getline(4)) | 44 call assert_equal('-X---', getline(4)) |
45 autocmd! CursorMovedI * | 45 autocmd! CursorMovedI * |
46 quit! | 46 quit! |
47 endfunc | 47 endfunc |
48 | 48 |
49 " Tests for behavior of curswant with cursorcolumn/line | |
50 func Test_curswant_with_cursorcolumn() | |
51 new | |
52 call setline(1, ['01234567', '']) | |
53 exe "normal! ggf6j" | |
54 call assert_equal(6, winsaveview().curswant) | |
55 set cursorcolumn | |
56 call assert_equal(6, winsaveview().curswant) | |
57 quit! | |
58 endfunc | |
59 | |
60 func Test_curswant_with_cursorline() | |
61 new | |
62 call setline(1, ['01234567', '']) | |
63 exe "normal! ggf6j" | |
64 call assert_equal(6, winsaveview().curswant) | |
65 set cursorline | |
66 call assert_equal(6, winsaveview().curswant) | |
67 quit! | |
68 endfunc |