[gtk/wip/baedert/for-master: 18/22] node editor: Show some default node data
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/baedert/for-master: 18/22] node editor: Show some default node data
- Date: Fri, 29 Jan 2021 11:12:31 +0000 (UTC)
commit aba14e6a434f2f196ee5df9350614846f3ac31f2
Author: Timm Bäder <mail baedert org>
Date: Thu Jan 28 16:40:11 2021 +0100
node editor: Show some default node data
Show case the icon and the render node format this way.
demos/node-editor/node-editor-window.c | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
---
diff --git a/demos/node-editor/node-editor-window.c b/demos/node-editor/node-editor-window.c
index bf1660d6f8..995349b2cb 100644
--- a/demos/node-editor/node-editor-window.c
+++ b/demos/node-editor/node-editor-window.c
@@ -910,6 +910,26 @@ node_editor_window_init (NodeEditorWindow *self)
self->text_buffer = gtk_text_buffer_new (self->tag_table);
g_signal_connect (self->text_buffer, "changed", G_CALLBACK (text_changed), self);
gtk_text_view_set_buffer (GTK_TEXT_VIEW (self->text_view), self->text_buffer);
+
+ /* Default */
+ gtk_text_buffer_set_text (self->text_buffer,
+ "shadow {\n"
+ " child: texture {\n"
+ " bounds: 0 0 128 128;\n"
+ " texture:
url(\"resource:///org/gtk/gtk4/node-editor/icons/apps/org.gtk.gtk4.NodeEditor.Devel.svg\");\n"
+ " }\n"
+ " shadows: rgba(0,0,0,0.5) 0 1 12;\n"
+ "}\n"
+ "\n"
+ "transform {\n"
+ " child: text {\n"
+ " color: rgb(46,52,54);\n"
+ " font: \"Cantarell Bold 11\";\n"
+ " glyphs: \"GTK Node Editor\";\n"
+ " offset: 8 14.418;\n"
+ " }\n"
+ " transform: translate(0, 140);\n"
+ "}", -1);
}
NodeEditorWindow *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]