Tizen Native API  5.5
Edje Class: Text

Functions that deal with Text Classes.

Sometimes we want to change the text of two or more parts equally and that's when we use text classes.

If one or more parts are assigned with a text class, when we set font attributes to this class will update all these parts with the new font attributes. Setting values to a text class at a process level will affect all parts with that text class, while at object level will affect only the parts inside an specified object.

Functions

Eina_Bool edje_text_class_set (const char *text_class, const char *font, Evas_Font_Size size)
 Sets the Edje text class.
Eina_Bool edje_text_class_get (const char *text_class, const char **font, Evas_Font_Size *size)
 Gets the font and the font size from Edje text class.
void edje_text_class_del (const char *text_class)
 Deletes the text class.
Eina_Listedje_text_class_list (void)
 Lists text classes.
Eina_Iteratoredje_text_class_active_iterator_new (void)
 Iterate over all active classes of an application.
Eina_Iteratoredje_mmap_text_class_iterator_new (Eina_File *f)
 Iterate over all text classes provided by an Edje file.

Function Documentation

Iterate over all text classes provided by an Edje file.

Parameters:
fThe mapped edje file.
Returns:
an iterator of Edje_Text_Class provided by the Edje file.
Since (EFL) :
1.17

Iterate over all active classes of an application.

Returns:
an iterator of Edje_Text_Class of the currently active text class

This function only iterates over the Edje_Text_Class in use by an application.

Since (EFL) :
1.17
void edje_text_class_del ( const char *  text_class)

Deletes the text class.

Parameters:
text_classThe text class name string

This function deletes any values at the process level for the specified text class.

Since :
2.3
Eina_Bool edje_text_class_get ( const char *  text_class,
const char **  font,
Evas_Font_Size *  size 
)

Gets the font and the font size from Edje text class.

Parameters:
text_classThe text class name
fontThe font name
sizeThe font size
Returns:
EINA_TRUE on success, or EINA_FALSE on error

This function gets the font and the font name from the specified Edje text class. The font string will only be valid until the text class is changed or edje is shut down.

See also:
edje_text_class_set().
Since (EFL) :
1.14
Since :
2.3

Lists text classes.

Returns:
A list of text class names (strings). These strings are stringshares and the list must be free()'d by the caller.

This function lists all text classes known about by the current process.

Since :
2.3
Eina_Bool edje_text_class_set ( const char *  text_class,
const char *  font,
Evas_Font_Size  size 
)

Sets the Edje text class.

Parameters:
text_classThe text class name
fontThe font name
sizeThe font size
Returns:
EINA_TRUE on success, or EINA_FALSE on error

This function updates all Edje members at the process level which belong to this text class with the new font attributes. If the size is 0 then the font size will be kept with the previous size. If the size is less then 0 then the font size will be calculated in the percentage. For example, if the size is -50, then the font size will be scaled to half of the original size and if the size is -10 then the font size will be scaled as much as 0.1x.

See also:
edje_text_class_get().
Since :
2.3