]> git.sur5r.net Git - glabels/blob - src/text-node.h
Imported Upstream version 3.0.0
[glabels] / src / text-node.h
1 /*
2  *  text-node.h
3  *  Copyright (C) 2001-2009  Jim Evins <evins@snaught.com>.
4  *
5  *  This file is part of gLabels.
6  *
7  *  gLabels is free software: you can redistribute it and/or modify
8  *  it under the terms of the GNU General Public License as published by
9  *  the Free Software Foundation, either version 3 of the License, or
10  *  (at your option) any later version.
11  *
12  *  gLabels is distributed in the hope that it will be useful,
13  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  *  GNU General Public License for more details.
16  *
17  *  You should have received a copy of the GNU General Public License
18  *  along with gLabels.  If not, see <http://www.gnu.org/licenses/>.
19  */
20
21 #ifndef __TEXT_NODE_H__
22 #define __TEXT_NODE_H__
23
24 #include <glib.h>
25 #include "merge.h"
26
27 G_BEGIN_DECLS
28
29 typedef struct {
30         gboolean field_flag;
31         gchar *data;
32 } glTextNode;
33
34 gchar      *gl_text_node_expand              (const glTextNode    *text_node,
35                                               const glMergeRecord *record);
36 glTextNode *gl_text_node_new_from_text       (const gchar         *text);
37 glTextNode *gl_text_node_dup                 (const glTextNode    *text_node);
38 void        gl_text_node_free                (glTextNode         **text_node);
39
40 gboolean    gl_text_node_equal               (const glTextNode    *text_node1,
41                                               const glTextNode    *text_node2);
42
43 gchar      *gl_text_node_lines_expand        (GList               *lines,
44                                               const glMergeRecord *record);
45 GList      *gl_text_node_lines_new_from_text (const gchar         *text);
46 GList      *gl_text_node_lines_dup           (GList               *lines);
47 void        gl_text_node_lines_free          (GList              **lines);
48
49 /* debug function */
50 void        gl_text_node_lines_print         (GList               *lines);
51
52 G_END_DECLS
53
54 #endif
55
56
57
58 /*
59  * Local Variables:       -- emacs
60  * mode: C                -- emacs
61  * c-basic-offset: 8      -- emacs
62  * tab-width: 8           -- emacs
63  * indent-tabs-mode: nil  -- emacs
64  * End:                   -- emacs
65  */