summaryrefslogtreecommitdiffstats
path: root/src/testdir/test_balloon.vim
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-06-15 15:37:11 +0200
committerChristian Brabandt <cb@256bit.org>2024-06-15 15:37:11 +0200
commit883018feff43413813770dd1e13d4f950aa38524 (patch)
tree1a27b0c6f2b9c9312e595e04f28fce789ff415ab /src/testdir/test_balloon.vim
parent105f741fac1b3242909c3c69384f00e4dcd9356e (diff)
patch 9.1.0491: Cmdline pum doesn't work properly with 'rightleft'v9.1.0491
Problem: Cmdline pum doesn't work properly with 'rightleft'. Solution: Don't use curwin->w_p_rl in cmdline mode in pum_redraw(). Use a static variable since pum_may_redraw() may be called in any mode. Also correct position of other popups with 'rightleft'. (zeertzjq) closes: #15005 Signed-off-by: zeertzjq <zeertzjq@outlook.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
Diffstat (limited to 'src/testdir/test_balloon.vim')
-rw-r--r--src/testdir/test_balloon.vim25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/testdir/test_balloon.vim b/src/testdir/test_balloon.vim
index 5e84f9e675..80d5831968 100644
--- a/src/testdir/test_balloon.vim
+++ b/src/testdir/test_balloon.vim
@@ -64,4 +64,29 @@ func Test_balloon_eval_term_visual()
call StopVimInTerminal(buf)
endfunc
+func Test_balloon_eval_term_rightleft()
+ CheckFeature rightleft
+
+ " Use <Ignore> after <MouseMove> to return from vgetc() without removing
+ " the balloon.
+ let xtra_lines =<< trim [CODE]
+ set rightleft
+ func Trigger()
+ call test_setmouse(2, 50 + 1 - 6)
+ call feedkeys("\<MouseMove>\<Ignore>", "xt")
+ endfunc
+ [CODE]
+ call writefile(s:common_script + xtra_lines, 'XTest_beval_rl', 'D')
+
+ " Check that the balloon shows up after a mouse move
+ let buf = RunVimInTerminal('-S XTest_beval_rl', {'rows': 10, 'cols': 50})
+ call TermWait(buf, 50)
+ call term_sendkeys(buf, 'll')
+ call term_sendkeys(buf, ":call Trigger()\<CR>")
+ call VerifyScreenDump(buf, 'Test_balloon_eval_term_03', {})
+
+ " clean up
+ call StopVimInTerminal(buf)
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab