[gtk+] recorder: show color information for color nodes
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] recorder: show color information for color nodes
- Date: Thu, 28 Sep 2017 19:54:55 +0000 (UTC)
commit 149dd1f558b7b586342c401a0af72338f7d14a60
Author: Matthias Clasen <mclasen redhat com>
Date: Thu Sep 28 15:08:08 2017 -0400
recorder: show color information for color nodes
A first step towards showing more information for render nodes.
gtk/inspector/recorder.c | 12 ++++++++++++
1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/gtk/inspector/recorder.c b/gtk/inspector/recorder.c
index 2ffbcdb..df710ae 100644
--- a/gtk/inspector/recorder.c
+++ b/gtk/inspector/recorder.c
@@ -224,6 +224,18 @@ populate_render_node_properties (GtkListStore *store,
0, "Has Texture",
1, gsk_render_node_get_node_type (node) == GSK_TEXTURE_NODE ? "TRUE" :
"FALSE",
-1);
+
+ if (gsk_render_node_get_node_type (node) == GSK_COLOR_NODE)
+ {
+ const GdkRGBA *color = gsk_color_node_peek_color (node);
+ char *text = gdk_rgba_to_string (color);
+
+ gtk_list_store_insert_with_values (store, NULL, -1,
+ 0, "Color",
+ 1, text,
+ -1);
+ g_free (text);
+ }
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]