patch 9.1.0854: cannot get terminal cell size
Problem: cannot get terminal cell size
Solution: add getcellpixels() function to return xpixel * ypixel
cell size on terminal Unix (mikoto2000)
closes: #16004
Signed-off-by: mikoto2000 <mikoto2000@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/evalfunc.c b/src/evalfunc.c
index 2d88668..04967ef 100644
--- a/src/evalfunc.c
+++ b/src/evalfunc.c
@@ -2077,6 +2077,14 @@
ret_string, f_getbufoneline},
{"getbufvar", 2, 3, FEARG_1, arg3_buffer_string_any,
ret_any, f_getbufvar},
+ {"getcellpixels", 0, 0, 0, NULL,
+ ret_list_any,
+#if (defined(UNIX) || defined(VMS)) && (defined(FEAT_EVAL) || defined(PROTO))
+ f_getcellpixels
+#else
+ NULL
+#endif
+ },
{"getcellwidths", 0, 0, 0, NULL,
ret_list_any, f_getcellwidths},
{"getchangelist", 0, 1, FEARG_1, arg1_buffer,