[gtk: 1/2] GtkApplicationWindow: Fix menubar example
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk: 1/2] GtkApplicationWindow: Fix menubar example
- Date: Fri, 4 Sep 2020 12:32:41 +0000 (UTC)
commit 62f7395c775a57e744c2f1a671018a80e852ddeb
Author: Emmanuel Gil Peyrot <linkmauve linkmauve fr>
Date: Fri Sep 4 13:49:28 2020 +0200
GtkApplicationWindow: Fix menubar example
This example was using invalid attribute syntax.
gtk/gtkapplicationwindow.c | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkapplicationwindow.c b/gtk/gtkapplicationwindow.c
index f8ab3d406a..b952b644c3 100644
--- a/gtk/gtkapplicationwindow.c
+++ b/gtk/gtkapplicationwindow.c
@@ -86,9 +86,16 @@
* GtkBuilder *builder = gtk_builder_new_from_string (
* "<interface>"
* " <menu id='menubar'>"
- * " <submenu label='_Edit'>"
- * " <item label='_Copy' action='win.copy'/>"
- * " <item label='_Paste' action='win.paste'/>"
+ * " <submenu>"
+ * " <attribute name='label' translatable='yes'>_Edit</attribute>"
+ * " <item>"
+ * " <attribute name='label' translatable='yes'>_Copy</attribute>"
+ * " <attribute name='action'>win.copy</attribute>"
+ * " </item>"
+ * " <item>"
+ * " <attribute name='label' translatable='yes'>_Paste</attribute>"
+ * " <attribute name='action'>win.paste</attribute>"
+ * " </item>"
* " </submenu>"
* " </menu>"
* "</interface>",
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]