box-layout: Deprecate expand/fill/align child properties

These are covered by ClutterActor:[xy]-align and
ClutterActor:[xy]-expand

https://bugzilla.gnome.org/show_bug.cgi?id=677283
This commit is contained in:
Bastian Winkler 2012-06-04 11:47:58 +02:00
parent f14c71cd3c
commit c7c3d85225
2 changed files with 29 additions and 13 deletions

View File

@ -35,18 +35,15 @@
* <listitem><para>all children are arranged on a single * <listitem><para>all children are arranged on a single
* line;</para></listitem> * line;</para></listitem>
* <listitem><para>the axis used is controlled by the * <listitem><para>the axis used is controlled by the
* #ClutterBoxLayout:vertical boolean property;</para></listitem> * #ClutterBoxLayout:orientation property;</para></listitem>
* <listitem><para>the order of the packing is determined by the * <listitem><para>the order of the packing is determined by the
* #ClutterBoxLayout:pack-start boolean property;</para></listitem> * #ClutterBoxLayout:pack-start boolean property;</para></listitem>
* <listitem><para>each child will be allocated to its natural * <listitem><para>each child will be allocated to its natural
* size or, if set to expand, the available size;</para></listitem> * size or, if #ClutterActor:x-expand/#ClutterActor:y-expand
* <listitem><para>if a child is set to fill on either (or both) * is set, the available size;</para></listitem>
* axis, its allocation will match all the available size; the * <listitem><para>honours the #ClutterActor's #ClutterActor:x-align
* fill layout property only makes sense if the expand property is * and #ClutterActor:y-align properties to fill the available
* also set;</para></listitem> * size;</para></listitem>
* <listitem><para>if a child is set to expand but not to fill then
* it is possible to control the alignment using the X and Y alignment
* layout properties.</para></listitem>
* <listitem><para>if the #ClutterBoxLayout:homogeneous boolean property * <listitem><para>if the #ClutterBoxLayout:homogeneous boolean property
* is set, then all widgets will get the same size, ignoring expand * is set, then all widgets will get the same size, ignoring expand
* settings and the preferred sizes</para></listitem> * settings and the preferred sizes</para></listitem>
@ -62,10 +59,6 @@
* It is possible to control the spacing between children of a * It is possible to control the spacing between children of a
* #ClutterBoxLayout by using clutter_box_layout_set_spacing(). * #ClutterBoxLayout by using clutter_box_layout_set_spacing().
* *
* In order to set the layout properties when packing an actor inside a
* #ClutterBoxLayout you should use the clutter_box_layout_pack()
* function.
*
* #ClutterBoxLayout is available since Clutter 1.2 * #ClutterBoxLayout is available since Clutter 1.2
*/ */
@ -1613,6 +1606,11 @@ clutter_box_layout_get_pack_start (ClutterBoxLayout *layout)
* and sets the layout properties * and sets the layout properties
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout honours #ClutterActor's
* align and expand properties. The preferred way is adding
* the @actor with clutter_actor_add_child() and setting
* #ClutterActor:x-align, #ClutterActor:y-align,
* #ClutterActor:x-expand and #ClutterActor:y-expand
*/ */
void void
clutter_box_layout_pack (ClutterBoxLayout *layout, clutter_box_layout_pack (ClutterBoxLayout *layout,
@ -1664,6 +1662,8 @@ clutter_box_layout_pack (ClutterBoxLayout *layout,
* inside @layout * inside @layout
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-align and #ClutterActor:y-align properies
*/ */
void void
clutter_box_layout_set_alignment (ClutterBoxLayout *layout, clutter_box_layout_set_alignment (ClutterBoxLayout *layout,
@ -1718,6 +1718,8 @@ clutter_box_layout_set_alignment (ClutterBoxLayout *layout,
* as set using clutter_box_layout_pack() or clutter_box_layout_set_alignment() * as set using clutter_box_layout_pack() or clutter_box_layout_set_alignment()
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-align and #ClutterActor:y-align properies
*/ */
void void
clutter_box_layout_get_alignment (ClutterBoxLayout *layout, clutter_box_layout_get_alignment (ClutterBoxLayout *layout,
@ -1776,6 +1778,8 @@ clutter_box_layout_get_alignment (ClutterBoxLayout *layout,
* inside @layout * inside @layout
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-align and #ClutterActor:y-align properies
*/ */
void void
clutter_box_layout_set_fill (ClutterBoxLayout *layout, clutter_box_layout_set_fill (ClutterBoxLayout *layout,
@ -1830,6 +1834,8 @@ clutter_box_layout_set_fill (ClutterBoxLayout *layout,
* as set using clutter_box_layout_pack() or clutter_box_layout_set_fill() * as set using clutter_box_layout_pack() or clutter_box_layout_set_fill()
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-align and #ClutterActor:y-align properies
*/ */
void void
clutter_box_layout_get_fill (ClutterBoxLayout *layout, clutter_box_layout_get_fill (ClutterBoxLayout *layout,
@ -1886,6 +1892,8 @@ clutter_box_layout_get_fill (ClutterBoxLayout *layout,
* Sets whether @actor should expand inside @layout * Sets whether @actor should expand inside @layout
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-expand and #ClutterActor:y-expand properies
*/ */
void void
clutter_box_layout_set_expand (ClutterBoxLayout *layout, clutter_box_layout_set_expand (ClutterBoxLayout *layout,
@ -1938,6 +1946,8 @@ clutter_box_layout_set_expand (ClutterBoxLayout *layout,
* Return value: %TRUE if the #ClutterActor should expand, %FALSE otherwise * Return value: %TRUE if the #ClutterActor should expand, %FALSE otherwise
* *
* Since: 1.2 * Since: 1.2
* Deprecated: 1.12: #ClutterBoxLayout will honour #ClutterActor's
* #ClutterActor:x-expand and #ClutterActor:y-expand properies
*/ */
gboolean gboolean
clutter_box_layout_get_expand (ClutterBoxLayout *layout, clutter_box_layout_get_expand (ClutterBoxLayout *layout,

View File

@ -110,25 +110,31 @@ void clutter_box_layout_pack (ClutterBoxLayou
gboolean y_fill, gboolean y_fill,
ClutterBoxAlignment x_align, ClutterBoxAlignment x_align,
ClutterBoxAlignment y_align); ClutterBoxAlignment y_align);
CLUTTER_DEPRECATED_IN_1_12
void clutter_box_layout_set_alignment (ClutterBoxLayout *layout, void clutter_box_layout_set_alignment (ClutterBoxLayout *layout,
ClutterActor *actor, ClutterActor *actor,
ClutterBoxAlignment x_align, ClutterBoxAlignment x_align,
ClutterBoxAlignment y_align); ClutterBoxAlignment y_align);
CLUTTER_DEPRECATED_IN_1_12
void clutter_box_layout_get_alignment (ClutterBoxLayout *layout, void clutter_box_layout_get_alignment (ClutterBoxLayout *layout,
ClutterActor *actor, ClutterActor *actor,
ClutterBoxAlignment *x_align, ClutterBoxAlignment *x_align,
ClutterBoxAlignment *y_align); ClutterBoxAlignment *y_align);
CLUTTER_DEPRECATED_IN_1_12
void clutter_box_layout_set_fill (ClutterBoxLayout *layout, void clutter_box_layout_set_fill (ClutterBoxLayout *layout,
ClutterActor *actor, ClutterActor *actor,
gboolean x_fill, gboolean x_fill,
gboolean y_fill); gboolean y_fill);
CLUTTER_DEPRECATED_IN_1_12
void clutter_box_layout_get_fill (ClutterBoxLayout *layout, void clutter_box_layout_get_fill (ClutterBoxLayout *layout,
ClutterActor *actor, ClutterActor *actor,
gboolean *x_fill, gboolean *x_fill,
gboolean *y_fill); gboolean *y_fill);
CLUTTER_DEPRECATED_IN_1_12
void clutter_box_layout_set_expand (ClutterBoxLayout *layout, void clutter_box_layout_set_expand (ClutterBoxLayout *layout,
ClutterActor *actor, ClutterActor *actor,
gboolean expand); gboolean expand);
CLUTTER_DEPRECATED_IN_1_12
gboolean clutter_box_layout_get_expand (ClutterBoxLayout *layout, gboolean clutter_box_layout_get_expand (ClutterBoxLayout *layout,
ClutterActor *actor); ClutterActor *actor);