eina: add eina_tiler_empty.
This commit is contained in:
parent
5479da04b6
commit
f07d4c17e9
|
@ -1198,6 +1198,14 @@ EAPI void eina_tiler_tile_size_set(Eina_Tiler *t, int w, int h)
|
|||
_splitter_tile_size_set(t, w, h);
|
||||
}
|
||||
|
||||
EAPI Eina_Bool
|
||||
eina_tiler_empty(Eina_Tiler *t)
|
||||
{
|
||||
EINA_MAGIC_CHECK_TILER(t, EINA_TRUE);
|
||||
|
||||
return !memcmp(&t->splitter.rects, &list_zeroed, sizeof (list_t));
|
||||
}
|
||||
|
||||
EAPI Eina_Bool eina_tiler_rect_add(Eina_Tiler *t, const Eina_Rectangle *r)
|
||||
{
|
||||
Eina_Rectangle tmp;
|
||||
|
|
|
@ -228,7 +228,7 @@ EAPI void eina_tiler_area_size_set(Eina_Tiler *t, int w, int h);
|
|||
*
|
||||
* @since 1.8
|
||||
*/
|
||||
EAPI void eina_tiler_area_size_get(const Eina_Tiler *t, int *w, int *h);
|
||||
EAPI void eina_tiler_area_size_get(const Eina_Tiler *t, int *w, int *h);
|
||||
|
||||
/**
|
||||
* @brief Define if we need to follow a strict grid of tile or a loosy one
|
||||
|
@ -237,9 +237,21 @@ EAPI void eina_tiler_area_size_get(const Eina_Tiler *t, int *w, int *h);
|
|||
* @param strict Define if it will be strict or loosy
|
||||
*
|
||||
* By default it will be loosy.
|
||||
*
|
||||
* @since 1.8
|
||||
*/
|
||||
EAPI void eina_tiler_strict_set(Eina_Tiler *t, Eina_Bool strict);
|
||||
|
||||
/**
|
||||
* @brief Tell if a tiler is empty or not
|
||||
*
|
||||
* @param t The tiler to apply the strict rules to.
|
||||
* @return EINA_TRUE when empty, EINA_FALSE when not.
|
||||
*
|
||||
* @since 1.8
|
||||
*/
|
||||
EAPI Eina_Bool eina_tiler_empty(Eina_Tiler *t);
|
||||
|
||||
/**
|
||||
* @brief Adds a rectangle to a tiler.
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue