2 * (LIBGLABELS) Template library for GLABELS
4 * xml.h: GLabels xml utilities header file
6 * Copyright (C) 2003, 2004 Jim Evins <evins@snaught.com>.
8 * This file is part of the LIBGLABELS library.
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Library General Public
12 * License as published by the Free Software Foundation; either
13 * version 2 of the License, or (at your option) any later version.
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 * Library General Public License for more details.
20 * You should have received a copy of the GNU Library General Public
21 * License along with this library; if not, write to the Free
22 * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
29 #include <glib/gtypes.h>
30 #include <libxml/tree.h>
34 #define LGL_XML_NAME_SPACE "http://snaught.com/glabels/2.2/"
39 * Get property functions
41 gchar * lgl_xml_get_prop_string (xmlNodePtr node,
42 const gchar *property,
43 const gchar *default_val);
45 gchar * lgl_xml_get_prop_i18n_string (xmlNodePtr node,
46 const gchar *property,
47 const gchar *default_val);
49 gdouble lgl_xml_get_prop_double (xmlNodePtr node,
50 const gchar *property,
53 gboolean lgl_xml_get_prop_boolean (xmlNodePtr node,
54 const gchar *property,
55 gboolean default_val);
57 gint lgl_xml_get_prop_int (xmlNodePtr node,
58 const gchar *property,
61 guint lgl_xml_get_prop_uint (xmlNodePtr node,
62 const gchar *property,
65 gdouble lgl_xml_get_prop_length (xmlNodePtr node,
66 const gchar *property,
71 * Set property functions
73 void lgl_xml_set_prop_string (xmlNodePtr node,
74 const gchar *property,
77 void lgl_xml_set_prop_double (xmlNodePtr node,
78 const gchar *property,
81 void lgl_xml_set_prop_boolean (xmlNodePtr node,
82 const gchar *property,
85 void lgl_xml_set_prop_int (xmlNodePtr node,
86 const gchar *property,
89 void lgl_xml_set_prop_uint_hex (xmlNodePtr node,
90 const gchar *property,
93 void lgl_xml_set_prop_length (xmlNodePtr node,
94 const gchar *property,
98 * Other node functions
100 gboolean lgl_xml_is_node (xmlNodePtr node,
103 gchar * lgl_xml_get_node_content (xmlNodePtr node);
108 void lgl_xml_set_default_units (lglUnitsType units);
113 #endif /* __XML_H__ */