patch 8.1.2274: newlines in 'balloonexpr' result only work in the GUI

Problem:    Newlines in 'balloonexpr' result only work in the GUI.
Solution:   Also recognize newlines in the terminal. (closes #5193)
diff --git a/src/popupmenu.c b/src/popupmenu.c
index 005adb2..55845cf 100644
--- a/src/popupmenu.c
+++ b/src/popupmenu.c
@@ -1130,7 +1130,7 @@
     int		item_idx;
     int		indent = 0;
     int		max_cells = 0;
-    int		max_height = Rows / 2 - 2;
+    int		max_height = Rows / 2 - 1;
     int		long_item_count = 0;
     int		split_long_items = FALSE;
 
@@ -1150,6 +1150,8 @@
 	{
 	    if (*p == '"')
 		quoted = !quoted;
+	    else if (*p == '\n')
+		break;
 	    else if (*p == '\\' && p[1] != NUL)
 		++p;
 	    else if (!quoted)
@@ -1170,6 +1172,8 @@
 	    p += mb_ptr2len(p);
 	}
 	item->bytelen = p - item->start;
+	if (*p == '\n')
+	    ++p;
 	if (item->cells > max_cells)
 	    max_cells = item->cells;
 	long_item_count += (item->cells - 1) / BALLOON_MIN_WIDTH;