Oyranos
git-devel
Oyranos is a full featured Color Management System
|
The idea behind this API is to provide one layout for presenting a configuration dialog to users. The advantage is, every application, like KDE and Gnome control panels, will inherit the same logic. A user can easily use the one and the other panel without too much relearning. More...
Functions | |
oyWIDGET_e * | oyWidgetListGet (oyGROUP_e group, int *count, oyAlloc_f allocate_func) |
all widgets of a group More... | |
oyWIDGET_TYPE_e | oyWidgetTitleGet (oyWIDGET_e option, const oyGROUP_e **categories, const char **name, const char **tooltip, int *flags) |
Get a special Options UI strings. More... | |
int | oyOptionChoicesGet (oyWIDGET_e option, int *choices, const char ***choices_string_list, int *current) |
Get a Options choices UI strings. More... | |
int | oyOptionChoicesGet2 (oyWIDGET_e option, uint32_t flags, int name_type, int *choices, const char ***choices_string_list, int *current) |
see oyOptionChoicesGet() More... | |
void | oyOptionChoicesFree (oyWIDGET_e option, const char ***list, int size) |
delete list of choices from a option More... | |
The idea behind this API is to provide one layout for presenting a configuration dialog to users. The advantage is, every application, like KDE and Gnome control panels, will inherit the same logic. A user can easily use the one and the other panel without too much relearning.
To illustrate a bit: In analogy to the WWW, I suggest to implement something like a minimalistic HTML display. Once the HTML alike content logic is done in Oyranos, the HTML page works and appears everywhere compareable. Smaller changes to the Oyranos HTML alike pages will appear everywhere in all HTML page display programms. To remain in the WWW analogy, CSS would be optional to adapt visually.
Functions are provided to set and query for Options layout and UI strings in Oyranos.
void oyOptionChoicesFree | ( | oyWIDGET_e | option, |
const char *** | list, | ||
int | size | ||
) |
delete list of choices from a option
option | option type |
list | string list |
size | number of strings in the list to free |
int oyOptionChoicesGet | ( | oyWIDGET_e | option, |
int * | choices, | ||
const char *** | choices_string_list, | ||
int * | current | ||
) |
Get a Options choices UI strings.
This function is checked for double occuring profiles. Such are sorted out.
option | merge oyBEHAVIOUR_e and oyPROFILE_e | |
[out] | choices | n choices; if choices is zero then you need to optain the choices otherwise, like for profiles |
[out] | choices_string_list | translated list of n choices |
[out] | current | the actual setting |
int oyOptionChoicesGet2 | ( | oyWIDGET_e | option, |
uint32_t | flags, | ||
int | name_type, | ||
int * | choices, | ||
const char *** | choices_string_list, | ||
int * | current | ||
) |
flags can come from oyICCProfileSelectionFlagsFromRegistration() and is for oyProfiles_Create() . Possible values for name_type come from oyNAME_e.
The flags argument relates to the option arg. For profile options see oyICCProfileSelectionFlagsFromRegistration(). The name_type argument can be a oyNAME_e .
oyWIDGET_e* oyWidgetListGet | ( | oyGROUP_e | group, |
int * | count, | ||
oyAlloc_f | allocate_func | ||
) |
all widgets of a group
group | specify which group dialog to build | |
[out] | count | number of widgets contained in list |
allocate_func | user provided function for allocating the strings memory |
oyWIDGET_TYPE_e oyWidgetTitleGet | ( | oyWIDGET_e | option, |
const oyGROUP_e ** | categories, | ||
const char ** | name, | ||
const char ** | tooltip, | ||
int * | flags | ||
) |
Get a special Options UI strings.
option | merges oyBEHAVIOUR_e and oyPROFILE_e | |
[out] | categories | enums list, to place into the right group widget { n, first category, second c., ... , n'th c. } for widget of type oyGROUP_e this is empty |
[out] | name | transated widget title |
[out] | tooltip | transated tooltip |
[out] | flags | option properties |