Convenience smart object that packs children under a regular grid layout, using their virtual grid location and size to determine children's positions inside the grid object's area. More...
Functions | |
| EVAS_API void | evas_object_grid_size_set (Evas_Grid *obj, int w, int h) |
| Set the virtual resolution for the grid. | |
| EVAS_API void | evas_object_grid_size_get (const Evas_Grid *obj, int *w, int *h) |
| Get the current virtual resolution. | |
| EVAS_API Eina_List * | evas_object_grid_children_get (const Evas_Grid *obj) |
| Get the list of children for the grid. | |
| EVAS_API Eina_Accessor * | evas_object_grid_accessor_new (const Evas_Grid *obj) |
| Get an accessor to get random access to the list of children for the grid. | |
| EVAS_API void | evas_object_grid_clear (Evas_Grid *obj, Eina_Bool clear) |
| Faster way to remove all child objects from a grid object. | |
| EVAS_API Eina_Iterator * | evas_object_grid_iterator_new (const Evas_Grid *obj) |
| Get an iterator to walk the list of children for the grid. | |
| EVAS_API Efl_Canvas_Object * | evas_object_grid_add_to (Evas_Grid *obj) |
| Create a grid that is child of a given element parent. | |
| EVAS_API Eina_Bool | evas_object_grid_unpack (Evas_Grid *obj, Efl_Canvas_Object *child) |
| Remove child from grid. | |
| EVAS_API Eina_Bool | evas_object_grid_pack_get (const Evas_Grid *obj, Efl_Canvas_Object *child, int *x, int *y, int *w, int *h) |
| Get the pack options for a grid child. | |
| EVAS_API Eina_Bool | evas_object_grid_pack (Evas_Grid *obj, Efl_Canvas_Object *child, int x, int y, int w, int h) |
| Add a new child to a grid object. | |
| EVAS_API Evas_Object * | evas_object_grid_add (Evas *evas) |
| Create a new grid. | |
| EVAS_API void | evas_object_grid_mirrored_set (Eo *obj, Eina_Bool mirrored) |
| Sets the mirrored mode of the grid. | |
| EVAS_API Eina_Bool | evas_object_grid_mirrored_get (const Eo *obj) |
| Gets the mirrored mode of the grid. | |
| EVAS_API Evas_Object * | evas_object_textgrid_add (Evas *e) |
| Add a textgrid to the given Evas. | |
| EVAS_API void | evas_object_textgrid_font_source_set (Eo *obj, const char *font_source) |
| Set the font (source) file to be used on a given textgrid object. | |
| EVAS_API void | evas_object_textgrid_ligatures_set (Eo *obj, Eina_Bool enabled) |
| Enable OpenType ligature shaping on a textgrid object. | |
| EVAS_API Eina_Bool | evas_object_textgrid_ligatures_get (const Eo *obj) |
| Get whether OpenType ligature shaping is enabled on a textgrid object. | |
| EVAS_API void | evas_object_textgrid_truecolor_set (Eo *obj, Eina_Bool enabled) |
| Enable the per-cell true color buffer of a textgrid object. | |
| EVAS_API Eina_Bool | evas_object_textgrid_truecolor_get (const Eo *obj) |
| Get whether the per-cell true color buffer is enabled on a textgrid object. | |
| EVAS_API Evas_Textgrid_Truecolor * | evas_object_textgrid_truecolor_cellrow_get (const Eo *obj, int y) |
| Get the true color entries of one row of a textgrid object. | |
| EVAS_API void | evas_object_textgrid_truecolor_cellrow_set (Eo *obj, int y, const Evas_Textgrid_Truecolor *row) |
| Set the true color entries of one row of a textgrid object. | |
| EVAS_API const char * | evas_object_textgrid_font_source_get (const Eo *obj) |
| Get the font file's path which is being used on a given textgrid object. | |
| EVAS_API void | evas_object_textgrid_font_set (Eo *obj, const char *font_name, Evas_Font_Size font_size) |
| Set the font family and size on a given textgrid object. | |
| EVAS_API void | evas_object_textgrid_font_get (const Eo *obj, const char **font_name, Evas_Font_Size *font_size) |
| Retrieve the font family and size in use on a given textgrid object. | |
Convenience smart object that packs children under a regular grid layout, using their virtual grid location and size to determine children's positions inside the grid object's area.
| EVAS_API void evas_object_grid_size_set | ( | Evas_Grid * | obj, |
| int | w, | ||
| int | h ) |
Set the virtual resolution for the grid.
| [in] | obj | The object. |
| [in] | w | The virtual horizontal size (resolution) in integer units. |
| [in] | h | The virtual vertical size (resolution) in integer units. |
References evas_object_grid_size_set().
Referenced by evas_object_grid_size_set().
| EVAS_API void evas_object_grid_size_get | ( | const Evas_Grid * | obj, |
| int * | w, | ||
| int * | h ) |
Get the current virtual resolution.
See also evas_object_grid_size_set
| [in] | obj | The object. |
| [out] | w | The virtual horizontal size (resolution) in integer units. |
| [out] | h | The virtual vertical size (resolution) in integer units. |
References evas_object_grid_size_get().
Referenced by evas_object_grid_size_get().
| EVAS_API Eina_List * evas_object_grid_children_get | ( | const Evas_Grid * | obj | ) |
Get the list of children for the grid.
| [in] | obj | The object. |
References evas_object_grid_children_get().
Referenced by evas_object_grid_children_get().
| EVAS_API Eina_Accessor * evas_object_grid_accessor_new | ( | const Evas_Grid * | obj | ) |
Get an accessor to get random access to the list of children for the grid.
| [in] | obj | The object. |
References evas_object_grid_accessor_new().
Referenced by evas_object_grid_accessor_new().
| EVAS_API void evas_object_grid_clear | ( | Evas_Grid * | obj, |
| Eina_Bool | clear ) |
Faster way to remove all child objects from a grid object.
| [in] | obj | The object. |
| [in] | clear | If true, it will delete just removed children. |
References evas_object_grid_clear().
Referenced by evas_object_grid_clear().
| EVAS_API Eina_Iterator * evas_object_grid_iterator_new | ( | const Evas_Grid * | obj | ) |
Get an iterator to walk the list of children for the grid.
| [in] | obj | The object. |
References evas_object_grid_iterator_new().
Referenced by evas_object_grid_iterator_new().
| EVAS_API Efl_Canvas_Object * evas_object_grid_add_to | ( | Evas_Grid * | obj | ) |
Create a grid that is child of a given element parent.
| [in] | obj | The object. |
References evas_object_grid_add_to().
Referenced by evas_object_grid_add_to().
| EVAS_API Eina_Bool evas_object_grid_unpack | ( | Evas_Grid * | obj, |
| Efl_Canvas_Object * | child ) |
Remove child from grid.
| [in] | obj | The object. |
| [in] | child | Child to be removed |
References evas_object_grid_unpack().
Referenced by evas_object_grid_unpack().
| EVAS_API Eina_Bool evas_object_grid_pack_get | ( | const Evas_Grid * | obj, |
| Efl_Canvas_Object * | child, | ||
| int * | x, | ||
| int * | y, | ||
| int * | w, | ||
| int * | h ) |
Get the pack options for a grid child.
Get the pack x, y, width and height in virtual coordinates set by evas_object_grid_pack.
| [in] | obj | The object. |
| [in] | child | The grid child to query for coordinates. |
| [out] | x | The pointer to where the x coordinate will be returned. |
| [out] | y | The pointer to where the y coordinate will be returned. |
| [out] | w | The pointer to where the width will be returned. |
| [out] | h | The pointer to where the height will be returned. |
References evas_object_grid_pack_get().
Referenced by elm_grid_pack_get(), and evas_object_grid_pack_get().
| EVAS_API Eina_Bool evas_object_grid_pack | ( | Evas_Grid * | obj, |
| Efl_Canvas_Object * | child, | ||
| int | x, | ||
| int | y, | ||
| int | w, | ||
| int | h ) |
Add a new child to a grid object.
| [in] | obj | The object. |
| [in] | child | The child object to add. |
| [in] | x | The virtual x coordinate of the child. |
| [in] | y | The virtual y coordinate of the child. |
| [in] | w | The virtual width of the child. |
| [in] | h | The virtual height of the child. |
References evas_object_grid_pack().
Referenced by elm_grid_pack_set(), and evas_object_grid_pack().
| EVAS_API Evas_Object * evas_object_textgrid_add | ( | Evas * | e | ) |
Add a textgrid to the given Evas.
| e | The given evas. |
This function adds a new textgrid object to the Evas e and returns the object.
References EINA_SAFETY_ON_FALSE_RETURN_VAL, EVAS_CANVAS_CLASS, and evas_object_textgrid_add().
Referenced by evas_object_textgrid_add().
| EVAS_API Evas_Object * evas_object_grid_add | ( | Evas * | evas | ) |
Create a new grid.
It's set to a virtual size of 1x1 by default and add children with evas_object_grid_pack().
References EINA_SAFETY_ON_FALSE_RETURN_VAL, EVAS_CANVAS_CLASS, and evas_object_grid_add().
Referenced by evas_object_grid_add().
| EVAS_API void evas_object_grid_mirrored_set | ( | Eo * | obj, |
| Eina_Bool | mirrored ) |
Sets the mirrored mode of the grid.
In mirrored mode the grid items go from right to left instead of left to right. That is, 0,0 is top right, not to left.
| [in] | obj | The object. |
| [in] | mirrored | true if mirrored mode is set, false otherwise |
References evas_object_grid_mirrored_set().
Referenced by evas_object_grid_mirrored_set().
| EVAS_API Eina_Bool evas_object_grid_mirrored_get | ( | const Eo * | obj | ) |
Gets the mirrored mode of the grid.
See also evas_object_grid_mirrored_set
| [in] | obj | The object. |
true if mirrored mode is set, false otherwiseReferences evas_object_grid_mirrored_get().
Referenced by evas_object_grid_mirrored_get().
| EVAS_API void evas_object_textgrid_font_source_set | ( | Eo * | obj, |
| const char * | font_source ) |
Set the font (source) file to be used on a given textgrid object.
This function allows the font file font_source to be explicitly set for the textgrid object obj, overriding system lookup, which will first occur in the given file's contents. If font_source is NULL or is an empty string, or the same font_source has already been set, or on error, this function does nothing.
| [in] | font_source | The font file's path. |
| EVAS_API void evas_object_textgrid_ligatures_set | ( | Eo * | obj, |
| Eina_Bool | enabled ) |
Enable OpenType ligature shaping on a textgrid object.
When enabled, adjacent cells whose codepoints can take part in a liga, clig, calt, dlig or rlig substitution are shaped together, so coding ligatures such as "=>" render as the font intends. A change of foreground colour or bold/italic style splits a run, so the cursor and selection edges split ligatures.
A shaped run is used only if it advances exactly one cell per source cell; otherwise its cells are rendered one by one. Other cells are unaffected.
Disabled by default.
| [in] | enabled | EINA_TRUE to shape ligature runs, EINA_FALSE not to. |
| EVAS_API Eina_Bool evas_object_textgrid_ligatures_get | ( | const Eo * | obj | ) |
Get whether OpenType ligature shaping is enabled on a textgrid object.
EINA_TRUE if ligature shaping is enabled, EINA_FALSE otherwise.References EINA_FALSE.
| EVAS_API void evas_object_textgrid_truecolor_set | ( | Eo * | obj, |
| Eina_Bool | enabled ) |
Enable the per-cell true color buffer of a textgrid object.
When enabled, a cell whose fg_truecolor or bg_truecolor flag is set takes that color from the buffer returned by evas_object_textgrid_truecolor_cellrow_get() instead of from the palettes. An entry's components are pre-multiplied, and an alpha of 0 means no color, as for palette entries. The buffer follows the cell array: it is reset to zero whenever the grid is resized.
When disabled (the default), both flags are ignored and the buffer is freed, so objects that never enable it behave exactly as before.
| [in] | enabled | EINA_TRUE to allocate and use the true color buffer, EINA_FALSE not to. |
| EVAS_API Eina_Bool evas_object_textgrid_truecolor_get | ( | const Eo * | obj | ) |
Get whether the per-cell true color buffer is enabled on a textgrid object.
EINA_TRUE if the true color buffer is enabled, EINA_FALSE otherwise.References EINA_FALSE.
| EVAS_API Evas_Textgrid_Truecolor * evas_object_textgrid_truecolor_cellrow_get | ( | const Eo * | obj, |
| int | y ) |
Get the true color entries of one row of a textgrid object.
Returns a pointer to the row's entries, one per column, parallel to the cells returned by evas_object_textgrid_cellrow_get(). Modify them in place (a checkout/checkin pattern together with evas_object_textgrid_truecolor_cellrow_set()), then call evas_object_textgrid_update_add() for the changed range.
w entries for row y, or NULL if the true color buffer is disabled or y is out of range.| [in] | y | The row to access, between 0 and the grid height minus 1. |
| EVAS_API void evas_object_textgrid_truecolor_cellrow_set | ( | Eo * | obj, |
| int | y, | ||
| const Evas_Textgrid_Truecolor * | row ) |
Set the true color entries of one row of a textgrid object.
Copies w entries from row into the row's true color buffer, parallel to evas_object_textgrid_cellrow_set(), and marks the row as changed. Together with evas_object_textgrid_truecolor_cellrow_get() this forms a checkout/checkin pattern: get a row, make any changes (or just reads), then set it back.
Does nothing if the true color buffer is disabled, row is NULL, or y is out of range.
| [in] | y | The row to write, between 0 and the grid height minus 1. |
| [in] | row | The array of w entries to copy into the row. |
| EVAS_API const char * evas_object_textgrid_font_source_get | ( | const Eo * | obj | ) |
Get the font file's path which is being used on a given textgrid object.
This function returns the font source path of the textgrid object obj. If the font source path has not been set, or on error, NULL is returned.
| EVAS_API void evas_object_textgrid_font_set | ( | Eo * | obj, |
| const char * | font_name, | ||
| Evas_Font_Size | font_size ) |
Set the font family and size on a given textgrid object.
This function allows the font name font_name and size font_size of the textgrid object obj to be set. The font_name string has to follow fontconfig's convention on naming fonts, as it's the underlying library used to query system fonts by Evas (see the fc-list command's output, on your system, to get an idea). It also has to be a monospace font. If font_name is NULL, or if it is an empty string, or if font_size is less or equal than 0, or on error, this function does nothing.
| [in] | font_name | The font (family) name. |
| [in] | font_size | The font size, in points. |
| EVAS_API void evas_object_textgrid_font_get | ( | const Eo * | obj, |
| const char ** | font_name, | ||
| Evas_Font_Size * | font_size ) |
Retrieve the font family and size in use on a given textgrid object.
This function allows the font name and size of a textgrid object obj to be queried and stored respectively in the buffers font_name and font_size. Be aware that the font name string is still owned by Evas and should not have free() called on it by the caller of the function. On error, the font name is the empty string and the font size is 0. font_name and font_source can be NULL.
| [out] | font_name | The font (family) name. |
| [out] | font_size | The font size, in points. |