aboutsummaryrefslogtreecommitdiff
path: root/docs/libdbusmenu-gtk/reference/xml/parser.xml
blob: 75de002873979a766d071e766414449f699e27a2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
               "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
[
  <!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
]>
<refentry id="libdbusmenu-gtk-parser">
<refmeta>
<refentrytitle role="top_of_page" id="libdbusmenu-gtk-parser.top_of_page">parser</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>
  LIBDBUSMENU-GTK Library
</refmiscinfo>
</refmeta>
<refnamediv>
<refname>parser</refname>
<refpurpose>A parser of in-memory GTK menu trees</refpurpose>
</refnamediv>
<refsect1 id="libdbusmenu-gtk-parser.stability-level">
<title>Stability Level</title>
Unstable, unless otherwise indicated
</refsect1>

<refsynopsisdiv id="libdbusmenu-gtk-parser.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>
#include &lt;libdbusmenu-gtk/parser.h&gt;

<link linkend="DbusmenuMenuitem"><returnvalue>DbusmenuMenuitem</returnvalue></link> *  <link linkend="dbusmenu-gtk-parse-menu-structure">dbusmenu_gtk_parse_menu_structure</link>   (<parameter><link linkend="GtkWidget"><type>GtkWidget</type></link> *widget</parameter>);
</synopsis>
</refsynopsisdiv>

<refsect1 id="libdbusmenu-gtk-parser.description" role="desc">
<title role="desc.title">Description</title>
<para>
The parser will take a GTK menu tree and attach it to a Dbusmenu menu
	tree.  Along with setting up all the signals for updates and destruction.
	The returned item would be the root item of the given tree.
</para>
</refsect1>
<refsect1 id="libdbusmenu-gtk-parser.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="dbusmenu-gtk-parse-menu-structure" role="function">
<title>dbusmenu_gtk_parse_menu_structure ()</title>
<indexterm zone="dbusmenu-gtk-parse-menu-structure"><primary>dbusmenu_gtk_parse_menu_structure</primary></indexterm>
<programlisting><link linkend="DbusmenuMenuitem"><returnvalue>DbusmenuMenuitem</returnvalue></link> *  dbusmenu_gtk_parse_menu_structure   (<parameter><link linkend="GtkWidget"><type>GtkWidget</type></link> *widget</parameter>);</programlisting>
<para>
Goes through the GTK structures and turns them into the appropraite
Dbusmenu structures along with setting up all the relationships
between the objects.  It also stores the dbusmenu items as a cache
on the GTK items so that they'll be reused if necissary.
</para><variablelist role="params">
<varlistentry><term><parameter>widget</parameter>&#160;:</term>
<listitem><simpara>A <link linkend="GtkMenuItem"><type>GtkMenuItem</type></link> or <link linkend="GtkMenuShell"><type>GtkMenuShell</type></link> to turn into a <link linkend="DbusmenuMenuitem"><type>DbusmenuMenuitem</type></link></simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>A dbusmenu item representing the menu structure. <emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>

</refentry>