summaryrefslogtreecommitdiff
path: root/gtk/gtkallocatedbitmaskprivate.h
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2012-02-09 01:44:59 +0100
committerBenjamin Otte <otte@redhat.com>2012-03-01 15:10:36 +0100
commit27eb83a4101adb608949cebebe59c307627d1e9e (patch)
treeb0a80be9a2225cef97ee039ca289660a7e8dd6fa /gtk/gtkallocatedbitmaskprivate.h
parent904cf36a5d75827265dbe7e65ab9f8871730be52 (diff)
downloadgtk+-27eb83a4101adb608949cebebe59c307627d1e9e.tar.gz
bitmask: Split bitmask code into two
This does nothing but turn all GtkBitmask functions into static inline functions that call the gtk_allocated_bitmask_*() equivalent. The implementation of the static functions has also been put into a private header, to not scare people who want to see how things are implemented.
Diffstat (limited to 'gtk/gtkallocatedbitmaskprivate.h')
-rw-r--r--gtk/gtkallocatedbitmaskprivate.h64
1 files changed, 64 insertions, 0 deletions
diff --git a/gtk/gtkallocatedbitmaskprivate.h b/gtk/gtkallocatedbitmaskprivate.h
new file mode 100644
index 0000000000..023b70d73c
--- /dev/null
+++ b/gtk/gtkallocatedbitmaskprivate.h
@@ -0,0 +1,64 @@
+/*
+ * Copyright © 2011 Red Hat Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ * Authors: Benjamin Otte <otte@gnome.org>
+ */
+
+#ifndef __GTK_ALLOCATED_BITMASK_PRIVATE_H__
+#define __GTK_ALLOCATED_BITMASK_PRIVATE_H__
+
+#include <glib.h>
+
+G_BEGIN_DECLS
+
+typedef struct _GtkBitmask GtkBitmask;
+
+
+GtkBitmask * _gtk_allocated_bitmask_new (void);
+GtkBitmask * _gtk_allocated_bitmask_copy (const GtkBitmask *mask);
+void _gtk_allocated_bitmask_free (GtkBitmask *mask);
+
+char * _gtk_allocated_bitmask_to_string (const GtkBitmask *mask);
+void _gtk_allocated_bitmask_print (const GtkBitmask *mask,
+ GString *string);
+
+GtkBitmask * _gtk_allocated_bitmask_intersect (GtkBitmask *mask,
+ const GtkBitmask *other) G_GNUC_WARN_UNUSED_RESULT;
+GtkBitmask * _gtk_allocated_bitmask_union (GtkBitmask *mask,
+ const GtkBitmask *other) G_GNUC_WARN_UNUSED_RESULT;
+GtkBitmask * _gtk_allocated_bitmask_subtract (GtkBitmask *mask,
+ const GtkBitmask *other) G_GNUC_WARN_UNUSED_RESULT;
+
+gboolean _gtk_allocated_bitmask_get (const GtkBitmask *mask,
+ guint index_);
+GtkBitmask * _gtk_allocated_bitmask_set (GtkBitmask *mask,
+ guint index_,
+ gboolean value) G_GNUC_WARN_UNUSED_RESULT;
+
+GtkBitmask * _gtk_allocated_bitmask_invert_range (GtkBitmask *mask,
+ guint start,
+ guint end) G_GNUC_WARN_UNUSED_RESULT;
+
+gboolean _gtk_allocated_bitmask_is_empty (const GtkBitmask *mask);
+gboolean _gtk_allocated_bitmask_equals (const GtkBitmask *mask,
+ const GtkBitmask *other);
+gboolean _gtk_allocated_bitmask_intersects (const GtkBitmask *mask,
+ const GtkBitmask *other);
+
+G_END_DECLS
+
+#endif /* __GTK_ALLOCATED_BITMASK_PRIVATE_H__ */