#include <inttypes.h>
#include "gui.h"
#include "wizard_types.h"
Go to the source code of this file.
|
int | wiz_get_percent (int min, int max, int value) |
|
int | wiz_set_progressbar (window_progress_t *p_progress, int min, int max, int value) |
|
int | wiz_set_progressbar_range (window_progress_t *p_progress, int min, int max, int range_min, int range_max, int value) |
|
void | wiz_set_progressbar_range_auto (window_progress_t *p_progress, int min, int max, int range_dif, int value) |
|
void | wiz_set_progressbar_dual_cl (window_progress_t *p_progress, int value, int cl_val, color_t cl_0, color_t cl_100) |
|
◆ wiz_get_percent()
int wiz_get_percent |
( |
int |
min, |
|
|
int |
max, |
|
|
int |
value |
|
) |
| |
46 return (
float)(value -
min) * (
float)100 / (float)(
max -
min);
◆ wiz_set_progressbar()
int wiz_set_progressbar |
( |
window_progress_t * |
p_progress, |
|
|
int |
min, |
|
|
int |
max, |
|
|
int |
value |
|
) |
| |
◆ wiz_set_progressbar_range()
int wiz_set_progressbar_range |
( |
window_progress_t * |
p_progress, |
|
|
int |
min, |
|
|
int |
max, |
|
|
int |
range_min, |
|
|
int |
range_max, |
|
|
int |
value |
|
) |
| |
19 if (value < range_min)
21 else if (value > range_max)
◆ wiz_set_progressbar_range_auto()
void wiz_set_progressbar_range_auto |
( |
window_progress_t * |
p_progress, |
|
|
int |
min, |
|
|
int |
max, |
|
|
int |
range_dif, |
|
|
int |
value |
|
) |
| |
7 int new_min =
min - range_dif;
8 int new_max =
max + range_dif;
9 int visible_min = new_min + 3 * (
min +
max) / 100;
11 if (value < visible_min)
◆ wiz_set_progressbar_dual_cl()
70 for (
int channel = 0; channel <= 3; ++channel) {
71 mix_cl(&color, cl_0, cl_100, cl_val, channel);