1 /*
2  * Copyright © 2014 Benjamin Otte <otte@gnome.org>
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library. If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef __GTK_CSS_NODE_DECLARATION_PRIVATE_H__
19 #define __GTK_CSS_NODE_DECLARATION_PRIVATE_H__
20 
21 #include "gtkcountingbloomfilterprivate.h"
22 #include "gtkcsstypesprivate.h"
23 #include "gtkenums.h"
24 
25 G_BEGIN_DECLS
26 
27 GtkCssNodeDeclaration * gtk_css_node_declaration_new                    (void);
28 GtkCssNodeDeclaration * gtk_css_node_declaration_ref                    (GtkCssNodeDeclaration         *decl);
29 void                    gtk_css_node_declaration_unref                  (GtkCssNodeDeclaration         *decl);
30 
31 gboolean                gtk_css_node_declaration_set_name               (GtkCssNodeDeclaration        **decl,
32                                                                          GQuark                         name);
33 GQuark                  gtk_css_node_declaration_get_name               (const GtkCssNodeDeclaration   *decl);
34 gboolean                gtk_css_node_declaration_set_id                 (GtkCssNodeDeclaration        **decl,
35                                                                          GQuark                         id);
36 GQuark                  gtk_css_node_declaration_get_id                 (const GtkCssNodeDeclaration   *decl);
37 gboolean                gtk_css_node_declaration_set_state              (GtkCssNodeDeclaration        **decl,
38                                                                          GtkStateFlags                  flags);
39 GtkStateFlags           gtk_css_node_declaration_get_state              (const GtkCssNodeDeclaration   *decl);
40 
41 gboolean                gtk_css_node_declaration_add_class              (GtkCssNodeDeclaration        **decl,
42                                                                          GQuark                         class_quark);
43 gboolean                gtk_css_node_declaration_remove_class           (GtkCssNodeDeclaration        **decl,
44                                                                          GQuark                         class_quark);
45 gboolean                gtk_css_node_declaration_clear_classes          (GtkCssNodeDeclaration        **decl);
46 gboolean                gtk_css_node_declaration_has_class              (const GtkCssNodeDeclaration   *decl,
47                                                                          GQuark                         class_quark);
48 const GQuark *          gtk_css_node_declaration_get_classes            (const GtkCssNodeDeclaration   *decl,
49                                                                          guint                         *n_classes);
50 
51 void                    gtk_css_node_declaration_add_bloom_hashes       (const GtkCssNodeDeclaration   *decl,
52                                                                          GtkCountingBloomFilter        *filter);
53 void                    gtk_css_node_declaration_remove_bloom_hashes    (const GtkCssNodeDeclaration   *decl,
54                                                                          GtkCountingBloomFilter        *filter);
55 
56 guint                   gtk_css_node_declaration_hash                   (gconstpointer                  elem);
57 gboolean                gtk_css_node_declaration_equal                  (gconstpointer                  elem1,
58                                                                          gconstpointer                  elem2);
59 
60 void                    gtk_css_node_declaration_print                  (const GtkCssNodeDeclaration   *decl,
61                                                                          GString                       *string);
62 
63 char *                  gtk_css_node_declaration_to_string              (const GtkCssNodeDeclaration   *decl);
64 
65 G_END_DECLS
66 
67 #endif /* __GTK_CSS_NODE_DECLARATION_PRIVATE_H__ */
68