forked from aniani/vim
patch 9.0.1725: cursor pos wrong after concealed text with 'virtualedit'
Problem: Wrong cursor position when clicking after concealed text
with 'virtualedit'.
Solution: Store virtual columns in ScreenCols[] instead of text
columns, and always use coladvance() when clicking.
This also fixes incorrect curswant when clicking on a TAB, so now
Test_normal_click_on_ctrl_char() asserts the same results as the ones
before patch 9.0.0048.
closes: #12808
Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
This commit is contained in:
committed by
Christian Brabandt
parent
2261c89a49
commit
e500ae8e29
@@ -32,7 +32,7 @@ EXTERN long Columns INIT(= 80); // nr of columns in the screen
|
||||
* The characters that are currently on the screen are kept in ScreenLines[].
|
||||
* It is a single block of characters, the size of the screen plus one line.
|
||||
* The attributes for those characters are kept in ScreenAttrs[].
|
||||
* The byte offset in the line is kept in ScreenCols[].
|
||||
* The virtual column in the line is kept in ScreenCols[].
|
||||
*
|
||||
* "LineOffset[n]" is the offset from ScreenLines[] for the start of line 'n'.
|
||||
* The same value is used for ScreenLinesUC[], ScreenAttrs[] and ScreenCols[].
|
||||
|
||||
Reference in New Issue
Block a user