[gtkmm] Gtk::Grid: Add attach_next_to() without the 'sibling' parameter
- From: Kjell Ahlstedt <kjellahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtkmm] Gtk::Grid: Add attach_next_to() without the 'sibling' parameter
- Date: Wed, 5 Nov 2014 09:52:50 +0000 (UTC)
commit 20bb5125e33a874baefac2805be2e6f661358f9d
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date: Wed Nov 5 10:46:23 2014 +0100
Gtk::Grid: Add attach_next_to() without the 'sibling' parameter
* gtk/src/grid.hg: Add an overloaded attach_next_to() without the 'sibling'
parameter. Improve the documentation of attach_next_to(). Bug #739340.
gtk/src/grid.hg | 22 ++++++++++++++++++++--
1 files changed, 20 insertions(+), 2 deletions(-)
---
diff --git a/gtk/src/grid.hg b/gtk/src/grid.hg
index d216c59..efb8c2d 100644
--- a/gtk/src/grid.hg
+++ b/gtk/src/grid.hg
@@ -26,7 +26,7 @@ namespace Gtk
{
/** A container which arranges its child widgets in rows and columns.
- * It is a very similar to Table and Box,
+ * It is very similar to Table and Box,
* but it consistently uses Widget's margin and expand
* properties instead of custom child properties, and it fully supports
* height-for-width geometry management.
@@ -57,7 +57,25 @@ public:
//Probably not, because a vertical GtkGrid is not very useful. murrayc.
_WRAP_METHOD(void attach(Widget& child, int left, int top, int width, int height), gtk_grid_attach)
- _WRAP_METHOD(void attach_next_to(Widget& child, Widget& sibling, PositionType side, int width, int
height), gtk_grid_attach_next_to)
+
+ /** Adds a widget to the grid.
+ *
+ * The widget is placed next to @a sibling, on the side determined by
+ * @a side. The %attach_next_to() without the @a sibling parameter
+ * places the widget in row 0 (for left or right placement) or column 0
+ * (for top or bottom placement), at the end indicated by @a side.
+ *
+ * Attaching widgets labeled [1], [2], [3] without the @a sibling parameter and
+ * @a side == Gtk::POS_LEFT yields a layout of [3][2][1].
+ *
+ * @param child The widget to add.
+ * @param sibling The child of @a grid that @a child will be placed
+ * next to, or omitted to place @a child at the beginning or end.
+ * @param side The side of @a sibling that @a child is positioned next to.
+ * @param width The number of columns that @a child will span.
+ * @param height The number of rows that @a child will span.
+ */
+ _WRAP_METHOD(void attach_next_to(Widget& child, Widget& sibling{?}, PositionType side, int width, int
height), gtk_grid_attach_next_to)
_WRAP_METHOD(Widget* get_child_at(int left, int top), gtk_grid_get_child_at)
_WRAP_METHOD(const Widget* get_child_at(int left, int top) const, gtk_grid_get_child_at)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]