Progressbar
The progressbar adds a widget for representing current progress of a job status. More...
Functions | |
EAPI Evas_Object * | elm_progressbar_add (Evas_Object *parent) |
Add a new progressbar to the parent. | |
EAPI void | elm_progressbar_pulse_set (Evas_Object *obj, Eina_Bool pulse) |
Normally the progressbar will display and interpret values from low to high. | |
EAPI void | elm_progressbar_pulse (Evas_Object *obj, Eina_Bool state) |
Normally the progressbar will display and interpret values from low to high. | |
EAPI void | elm_progressbar_value_set (Evas_Object *obj, double val) |
Set the value the progressbar indicates. | |
EAPI double | elm_progressbar_value_get (const Evas_Object *obj) |
Get the value the progressbar has. | |
EAPI void | elm_progressbar_label_set (Evas_Object *obj, const char *label) |
Set the label of the progressbar. | |
EAPI void | elm_progressbar_icon_set (Evas_Object *obj, Evas_Object *icon) |
Set the icon object of the progressbar object. | |
EAPI void | elm_progressbar_span_size_set (Evas_Object *obj, Evas_Coord size) |
Set the length of the progression region of the progressbar. | |
EAPI void | elm_progressbar_unit_format_set (Evas_Object *obj, const char *units) |
Set the format string of the unit area. | |
EAPI void | elm_progressbar_horizontal_set (Evas_Object *obj, Eina_Bool horizontal) |
Set orientation of the progressbar. | |
EAPI void | elm_progressbar_inverted_set (Evas_Object *obj, Eina_Bool inverted) |
Invert the progressbar display. |
Detailed Description
The progressbar adds a widget for representing current progress of a job status.A progressbar can be horizontal or vertical. It can contain an Icon and has a primary label as well as a units label (that is formatted with floating point values and thus accepts a printf-style format string, like “1.2f units”.
Label, Icon and Unit strings/objects are optional.
A progressbar may be inverted which means values invert, with high vales being on the left or top and low values on the right or bottom (as opposed to normally being low on the left or top and high on the bottom and right).
The span of the progressbar is its length (horizontally or vertically). This will be scaled by the object or applications scaling factor. At any point code can query the progressbar for its value with elm_progressbar_value_get().
Function Documentation
EAPI Evas_Object* elm_progressbar_add | ( | Evas_Object * | parent | ) |
Add a new progressbar to the parent.
- Parameters:
-
parent The parent object
- Returns:
- The new object or NULL if it cannot be created
EAPI void elm_progressbar_horizontal_set | ( | Evas_Object * | obj, | |
Eina_Bool | horizontal | |||
) |
Set orientation of the progressbar.
- Parameters:
-
obj The progressbar object horizontal If set, the progressbar will be horizontal
EAPI void elm_progressbar_icon_set | ( | Evas_Object * | obj, | |
Evas_Object * | icon | |||
) |
Set the icon object of the progressbar object.
Once the icon object is set, it will become a child of the progressbar object and be deleted when the progressbar object is deleted. If another icon object is set then the previous one becomes orophaned and will no longer be deleted along with the progressbar.
- Parameters:
-
obj The progressbar object icon The icon object
EAPI void elm_progressbar_inverted_set | ( | Evas_Object * | obj, | |
Eina_Bool | inverted | |||
) |
Invert the progressbar display.
Normally the progressbar will display and interpret values from low to high and when horizontal that is left to right. When vertical that is top to bottom. This inverts this (so from right to left or bottom to top) if inverted is set to 1.
- Parameters:
-
obj The progressbar object inverted The inverted flag. 1 == inverted, 0 == normal
EAPI void elm_progressbar_label_set | ( | Evas_Object * | obj, | |
const char * | label | |||
) |
Set the label of the progressbar.
- Parameters:
-
obj The progressbar object label The text label string in UTF-8
EAPI void elm_progressbar_pulse | ( | Evas_Object * | obj, | |
Eina_Bool | state | |||
) |
Normally the progressbar will display and interpret values from low to high.
This display a progressbar for jobs with unknow state of progression, (the cursor pulse right to left and left to right, and loop) if pulse is set to 1.
- Parameters:
-
obj The progressbar object pulse The pulse flag. 1 == pulse, 0 == normal
EAPI void elm_progressbar_pulse_set | ( | Evas_Object * | obj, | |
Eina_Bool | pulse | |||
) |
Normally the progressbar will display and interpret values from low to high.
This display a progressbar for jobs with unknow state of progression, (the cursor pulse right to left and left to right, and loop) if pulse is set to 1.
- Parameters:
-
obj The progressbar object pulse The pulse flag. 1 == pulse, 0 == normal
EAPI void elm_progressbar_span_size_set | ( | Evas_Object * | obj, | |
Evas_Coord | size | |||
) |
Set the length of the progression region of the progressbar.
This sets the minimum width or height (depending on orientation) of the area of the progressbar that allows the progressbar to be dragged around. This in turn affects the objects minimum size (along with icon label and unit text).
- Parameters:
-
obj The progressbar object size The length of the progressbar area
EAPI void elm_progressbar_unit_format_set | ( | Evas_Object * | obj, | |
const char * | units | |||
) |
Set the format string of the unit area.
If NULL, this disabls the unit area display. If not it sets the format string for the unit text. The unit text is provided a floating point value, so the unit text can display up to 1 floating point falue. Note that this is optional. Use a format string such as "%1.2f meters" for example.
- Parameters:
-
obj The progressbar object units The format string for the units display
EAPI double elm_progressbar_value_get | ( | const Evas_Object * | obj | ) |
Get the value the progressbar has.
- Parameters:
-
obj The progressbar object
- Returns:
- The value of the progressbar
EAPI void elm_progressbar_value_set | ( | Evas_Object * | obj, | |
double | val | |||
) |
Set the value the progressbar indicates.
- Parameters:
-
obj The progressbar object val The fraction value (must be beween 0.0 and 1.0)