From b902838344ce242e8d7fd6e01414f434667e531c Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Fri, 12 May 2023 17:16:22 +0200 Subject: [PATCH] node-editor: Print default renderer in title If there is a value passed to GSK_RENDERER, display it in the window title. This is mostly so that when I show off screenshots, people know what renderer I'm using. --- demos/node-editor/node-editor-window.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/demos/node-editor/node-editor-window.c b/demos/node-editor/node-editor-window.c index 9eb5fcfac6..4be1adadd2 100644 --- a/demos/node-editor/node-editor-window.c +++ b/demos/node-editor/node-editor-window.c @@ -1309,6 +1309,13 @@ node_editor_window_init (NodeEditorWindow *self) " }\n" " transform: translate(0, 140);\n" "}", -1); + + if (g_getenv ("GSK_RENDERER")) + { + char *new_title = g_strdup_printf ("GTK Node Editor - %s", g_getenv ("GSK_RENDERER")); + gtk_window_set_title (GTK_WINDOW (self), new_title); + g_free (new_title); + } } NodeEditorWindow * -- 2.30.2