aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/grid_defs.h
diff options
context:
space:
mode:
authorBjörn Linse <bjorn.linse@gmail.com>2021-05-01 13:29:34 +0200
committerBjörn Linse <bjorn.linse@gmail.com>2021-05-15 13:56:27 +0200
commitedb5864a29ec0d1049c4674afb75c8279301446c (patch)
tree2ced0985bb7d20d64a42d927323c1e4878f6cdd1 /src/nvim/grid_defs.h
parent7d82ea01025b6981e0233ca9a5e7ee62c8b5bcad (diff)
downloadrneovim-edb5864a29ec0d1049c4674afb75c8279301446c.tar.gz
rneovim-edb5864a29ec0d1049c4674afb75c8279301446c.tar.bz2
rneovim-edb5864a29ec0d1049c4674afb75c8279301446c.zip
floats: z-index
Diffstat (limited to 'src/nvim/grid_defs.h')
-rw-r--r--src/nvim/grid_defs.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/nvim/grid_defs.h b/src/nvim/grid_defs.h
index 3b34af46e4..724363674c 100644
--- a/src/nvim/grid_defs.h
+++ b/src/nvim/grid_defs.h
@@ -13,6 +13,15 @@
typedef char_u schar_T[(MAX_MCO+1) * 4 + 1];
typedef int sattr_T;
+enum {
+ kZIndexDefaultGrid = 0,
+ kZIndexFloatDefault = 50,
+ kZIndexPopupMenu = 100,
+ kZIndexMessages = 200,
+ kZIndexCmdlinePopupMenu = 250,
+};
+
+
/// ScreenGrid represents a resizable rectuangular grid displayed by UI clients.
///
/// chars[] contains the UTF-8 text that is currently displayed on the grid.
@@ -73,6 +82,9 @@ struct ScreenGrid {
// whether the grid can be focused with mouse clicks.
bool focusable;
+ // z-index: the order in the stack of grids.
+ int zindex;
+
// Below is state owned by the compositor. Should generally not be set/read
// outside this module, except for specific compatibilty hacks
@@ -96,7 +108,7 @@ struct ScreenGrid {
};
#define SCREEN_GRID_INIT { 0, NULL, NULL, NULL, NULL, NULL, 0, 0, false, \
- false, 0, 0, NULL, false, true, \
+ false, 0, 0, NULL, false, true, 0, \
0, 0, 0, 0, 0, false }
#endif // NVIM_GRID_DEFS_H