mirror of
https://github.com/brl/mutter.git
synced 2025-08-04 07:34:53 +00:00
util: Add paint debug flags
Analogous to `ClutterDrawDebugFlag` but intended for concepts that are not present in Clutter, such as Wayland/X11 opaque regions. Also add the first flag for the later. To set the flag, run: `Meta.add_debug_paint_flag(Meta.DebugPaintFlag.OPAQUE_REGION)` https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1372
This commit is contained in:
@@ -53,6 +53,7 @@ static gboolean is_debugging = FALSE;
|
||||
static gboolean replace_current = FALSE;
|
||||
static int no_prefix = 0;
|
||||
static gboolean is_wayland_compositor = FALSE;
|
||||
static int debug_paint_flags = 0;
|
||||
|
||||
#ifdef WITH_VERBOSE_MODE
|
||||
static FILE* logfile = NULL;
|
||||
@@ -753,3 +754,21 @@ meta_remove_clutter_debug_flags (ClutterDebugFlag debug_flags,
|
||||
{
|
||||
clutter_remove_debug_flags (debug_flags, draw_flags, pick_flags);
|
||||
}
|
||||
|
||||
void
|
||||
meta_add_debug_paint_flag (MetaDebugPaintFlag flag)
|
||||
{
|
||||
debug_paint_flags |= flag;
|
||||
}
|
||||
|
||||
void
|
||||
meta_remove_debug_paint_flag (MetaDebugPaintFlag flag)
|
||||
{
|
||||
debug_paint_flags &= ~flag;
|
||||
}
|
||||
|
||||
MetaDebugPaintFlag
|
||||
meta_get_debug_paint_flags (void)
|
||||
{
|
||||
return debug_paint_flags;
|
||||
}
|
||||
|
Reference in New Issue
Block a user