From 06a75b7e1ff11a3bde914b1f1a1376f3c86a1098 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Wed, 14 Dec 2011 06:51:54 -0500 Subject: [PATCH] Some more menu-related docs --- gtk/gtkapplication.c | 6 ++++++ gtk/gtkbuilder.c | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/gtk/gtkapplication.c b/gtk/gtkapplication.c index ed14aa5840..7ff1ed0a4a 100644 --- a/gtk/gtkapplication.c +++ b/gtk/gtkapplication.c @@ -61,6 +61,12 @@ * While GtkApplication works fine with plain #GtkWindows, it is recommended * to use it together with #GtkApplicationWindow. * + * To set an app menu on a GtkApplication, use g_application_set_app_menu(). + * The #GMenuModel that this function expects is usually constructed using + * #GtkBuilder, as seen in the following example. To set a menubar that will + * be automatically picked up by #GApplicationWindows, use + * g_application_set_menubar(). + * * A simple application * * diff --git a/gtk/gtkbuilder.c b/gtk/gtkbuilder.c index de24427bb5..fc8d0f9196 100644 --- a/gtk/gtkbuilder.c +++ b/gtk/gtkbuilder.c @@ -240,6 +240,14 @@ * GtkTextTagTable. * * + * + * Embedding other XML + * + * Apart from the language for UI descriptions that has been explained + * in the previous section, GtkBuilder can also parse XML fragments + * of GMenu markup. The resulting + * #GMenu object and its named submenus are available via + * gtk_builder_get_object() like other constructed objects. */ #include "config.h"