/** * st_table_get_column_count: * @table: A #StTable * * Retrieve the current number of columns in @table * * Returns: the number of columns */ gint st_table_get_column_count (StTable *table) { g_return_val_if_fail (ST_IS_TABLE (table), -1); return ST_TABLE (table)->priv->n_cols; }
/** * st_table_child_get_y_align: * @table: A #StTable * @child: A #ClutterActor * * Get the y-align value of the child * * Returns: An #StAlign value */ StAlign st_table_child_get_y_align (StTable *table, ClutterActor *child) { StTableChild *meta; g_return_val_if_fail (ST_IS_TABLE (table), 0); g_return_val_if_fail (CLUTTER_IS_ACTOR (child), 0); meta = get_child_meta (table, child); return meta->y_align; }
/** * st_table_child_get_allocate_hidden: * @table: A #StTable * @child: A #ClutterActor * * Determine if the child is allocated even if it is hidden * * Returns: %TRUE if the actor is allocated when hidden */ gboolean st_table_child_get_allocate_hidden (StTable *table, ClutterActor *child) { StTableChild *meta; g_return_val_if_fail (ST_IS_TABLE (table), TRUE); g_return_val_if_fail (CLUTTER_IS_ACTOR (child), TRUE); meta = get_child_meta (table, child); return meta->allocate_hidden; }
/** * st_table_child_get_x_expand: * @table: A #StTable * @child: A #ClutterActor * * Get the x-expand property of the child * * Returns: %TRUE if the child is set to x-expand */ gboolean st_table_child_get_x_expand (StTable *table, ClutterActor *child) { StTableChild *meta; g_return_val_if_fail (ST_IS_TABLE (table), 0); g_return_val_if_fail (CLUTTER_IS_ACTOR (child), 0); meta = get_child_meta (table, child); return meta->x_expand; }
/** * st_table_child_set_y_align: * @table: A #StTable * @child: A #ClutterActor * @align: A #StAlign value * * Set the value of the y-align property. This will only have an effect if * y-fill value is set to FALSE. * */ void st_table_child_set_y_align (StTable *table, ClutterActor *child, StAlign align) { StTableChild *meta; g_return_if_fail (ST_IS_TABLE (table)); g_return_if_fail (CLUTTER_IS_ACTOR (child)); meta = get_child_meta (table, child); meta->y_align = align; clutter_actor_queue_relayout (child); }
/** * st_table_child_set_y_expand: * @table: A #StTable * @child: A #ClutterActor * @expand: the new value of the y-expand child property * * Set y-expand on the child. This causes the row which the child * resides in to be allocated any extra space if the allocation of the table is * larger than the preferred size. * */ void st_table_child_set_y_expand (StTable *table, ClutterActor *child, gboolean expand) { StTableChild *meta; g_return_if_fail (ST_IS_TABLE (table)); g_return_if_fail (CLUTTER_IS_ACTOR (child)); meta = get_child_meta (table, child); meta->y_expand = expand; clutter_actor_queue_relayout (child); }
/** * st_table_child_set_row_span: * @table: A #StTable * @child: A #ClutterActor * @span: the number of rows to span * * Set the row span of the child. * */ void st_table_child_set_row_span (StTable *table, ClutterActor *child, gint span) { StTableChild *meta; g_return_if_fail (ST_IS_TABLE (table)); g_return_if_fail (CLUTTER_IS_ACTOR (child)); g_return_if_fail (span > 1); meta = get_child_meta (table, child); meta->row_span = span; clutter_actor_queue_relayout (child); }
/** * st_table_child_set_allocate_hidden: * @table: A #StTable * @child: A #ClutterActor * @value: %TRUE if the actor should be allocated when hidden * * Set whether the child should be allocate even if it is hidden */ void st_table_child_set_allocate_hidden (StTable *table, ClutterActor *child, gboolean value) { StTableChild *meta; g_return_if_fail (ST_IS_TABLE (table)); g_return_if_fail (CLUTTER_IS_ACTOR (child)); meta = get_child_meta (table, child); if (meta->allocate_hidden != value) { meta->allocate_hidden = value; clutter_actor_queue_relayout (child); g_object_notify (G_OBJECT (meta), "allocate-hidden"); } }