summaryrefslogtreecommitdiff
path: root/src/beval.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-11-19 19:56:27 +0100
committerBram Moolenaar <Bram@vim.org>2017-11-19 19:56:27 +0100
commit246fe03d154c09070d5b7365b7f61716c4e0ddd4 (patch)
tree1d0ad5929d17f1af24ac22817bd9fe6c0d5d84f2 /src/beval.c
parente518226713784e628ae7ee077f1b66cb12b9ffd9 (diff)
downloadvim-git-246fe03d154c09070d5b7365b7f61716c4e0ddd4.tar.gz
patch 8.0.1318: terminal balloon only shows one linev8.0.1318
Problem: Terminal balloon only shows one line. Solution: Split into several lines in a clever way. Add balloon_split(). Make balloon_show() accept a list in the terminal.
Diffstat (limited to 'src/beval.c')
-rw-r--r--src/beval.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/beval.c b/src/beval.c
index d4705b8b9..f8bb6ba26 100644
--- a/src/beval.c
+++ b/src/beval.c
@@ -134,19 +134,20 @@ get_beval_info(
}
/*
- * Show a balloon with "mesg".
+ * Show a balloon with "mesg" or "list".
*/
void
-post_balloon(BalloonEval *beval UNUSED, char_u *mesg)
+post_balloon(BalloonEval *beval UNUSED, char_u *mesg, list_T *list)
{
# ifdef FEAT_BEVAL_TERM
# ifdef FEAT_GUI
if (!gui.in_use)
# endif
- ui_post_balloon(mesg);
+ ui_post_balloon(mesg, list);
# endif
# ifdef FEAT_BEVAL_GUI
if (gui.in_use)
+ /* GUI can't handle a list */
gui_mch_post_balloon(beval, mesg);
# endif
}
@@ -257,7 +258,7 @@ general_beval_cb(BalloonEval *beval, int state UNUSED)
set_vim_var_string(VV_BEVAL_TEXT, NULL, -1);
if (result != NULL && result[0] != NUL)
{
- post_balloon(beval, result);
+ post_balloon(beval, result, NULL);
recursive = FALSE;
return;
}