[gtk+/native-layout-incubator-2] adding prototype for gtk_distribute_natural_allocation().
- From: Tristan Van Berkom <tvb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/native-layout-incubator-2] adding prototype for gtk_distribute_natural_allocation().
- Date: Wed, 30 Jun 2010 15:31:31 +0000 (UTC)
commit 4a2d067db39c8eccd53963e3eb8ce247e20fc2cd
Author: Tristan Van Berkom <tristan van berkom gmail com>
Date: Wed Jun 30 11:18:39 2010 -0400
adding prototype for gtk_distribute_natural_allocation().
gtk/gtksizerequest.h | 25 +++++++++++++++++++++++++
1 files changed, 25 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtksizerequest.h b/gtk/gtksizerequest.h
index c397585..2724589 100644
--- a/gtk/gtksizerequest.h
+++ b/gtk/gtksizerequest.h
@@ -36,6 +36,24 @@ G_BEGIN_DECLS
typedef struct _GtkSizeRequest GtkSizeRequest;
typedef struct _GtkSizeRequestIface GtkSizeRequestIface;
+typedef struct _GtkRequestedSize GtkRequestedSize;
+
+/**
+ * GtkRequestedSize:
+ * @data: A client pointer
+ * @minimum_size: The minimum size needed for allocation in a given orientation
+ * @natural_size: The natural size for allocation in a given orientation
+ *
+ * Represents a request of a screen object in a given orientation. These
+ * are primarily used in container implementations when allocating a natural
+ * size for children calling. See gtk_distribute_natural_allocation().
+ */
+struct _GtkRequestedSize
+{
+ gpointer data;
+ gint minimum_size;
+ gint natural_size;
+};
struct _GtkSizeRequestIface
@@ -82,6 +100,13 @@ void gtk_size_request_get_size (GtkSizeRequest *widge
GtkRequisition *minimum_size,
GtkRequisition *natural_size);
+
+/* General convenience function to aid in allocating natural sizes */
+gint gtk_distribute_natural_allocation (gint extra_space,
+ guint n_requested_sizes,
+ GtkRequestedSize *sizes);
+
+
G_END_DECLS
#endif /* __GTK_SIZE_REQUEST_H__ */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]