patch 9.0.0464: with virtual text "above" indenting doesn't work well
Problem: With virtual text "above" indenting doesn't work well.
Solution: Ignore text properties while adjusting indent. (issue #11084)
diff --git a/src/testdir/test_textprop.vim b/src/testdir/test_textprop.vim
index 5167e8e..0a4037b 100644
--- a/src/testdir/test_textprop.vim
+++ b/src/testdir/test_textprop.vim
@@ -2892,6 +2892,22 @@
call StopVimInTerminal(buf)
endfunc
+func Test_prop_above_with_indent()
+ new
+ call setline(1, ['first line', ' second line', ' line below'])
+ setlocal cindent
+ call prop_type_add('indented', #{highlight: 'Search'})
+ call prop_add(3, 0, #{type: 'indented', text: 'here', text_align: 'above', text_padding_left: 4})
+ call assert_equal(' line below', getline(3))
+
+ exe "normal 3G2|a\<CR>"
+ call assert_equal(' ', getline(3))
+ call assert_equal(' line below', getline(4))
+
+ bwipe!
+ call prop_type_delete('indented')
+endfunc
+
func Test_props_with_text_override()
CheckRunVimInTerminal