static void create_base_gui(appdata_s *ad) {
/* Window */
/* Create and initialize elm_win,
which is mandatory to manipulate a window
*/
ad->win = elm_win_util_standard_add(PACKAGE, PACKAGE);
elm_win_autodel_set(ad->win, EINA_TRUE);
if (elm_win_wm_rotation_supported_get(ad->win)) {
int rots[4] = {0, 90, 180, 270};
elm_win_wm_rotation_available_rotations_set(ad->win, (const int *)(&rots), 4);
}
evas_object_smart_callback_add(ad->win, "delete,request", win_delete_request_cb, NULL);
eext_object_event_callback_add(ad->win, EEXT_CALLBACK_BACK, win_back_cb, ad);
/* Conformant */
/* Create and initialize elm_conformant,
which is mandatory for the base UI to have a proper size
when an indicator or virtual keypad is visible
*/
ad->conform = elm_conformant_add(ad->win);
elm_win_indicator_mode_set(ad->win, ELM_WIN_INDICATOR_HIDE);
evas_object_size_hint_weight_set(ad->conform, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_win_resize_object_add(ad->win, ad->conform);
evas_object_show(ad->conform);
/* Naviframe */
ad->naviFrame = elm_naviframe_add(ad->conform);
evas_object_show(ad->naviFrame);
elm_naviframe_prev_btn_auto_pushed_set(ad->naviFrame, EINA_TRUE);
elm_object_content_set(ad->conform, ad->naviFrame);
/* Starting right after the basic EFL UI layout code */
/* (win - conformant - naviframe) */
/* Set a circle surface */
ad->circleSurface = eext_circle_surface_conformant_add(ad->conform);
/* Add a layout and push the layout into the naviframe */
/* EDJ_PATH is folder path, it contains the progressbar_circle.edj file */
ad->progressBarLayout = elm_layout_add(ad->naviFrame);
elm_layout_file_set(ad->progressBarLayout, "res/progressbar_circle.edj", "eext_progressbar_layout");
evas_object_show(ad->progressBarLayout);
elm_naviframe_item_push(ad->naviFrame, NULL, NULL, NULL, ad->progressBarLayout, NULL);
/* Add a progressbar and set a circle surface to render the progressbar */
ad->progressBar = eext_circle_object_progressbar_add(ad->progressBarLayout, ad->circleSurface);
/*Set a minimum and maximum values */
eext_circle_object_value_min_max_set(ad->progressBar, 0.0, 100.0);
/* Set a progressbar value */
eext_circle_object_value_set(ad->progressBar, 0);
/* Set a part content */
elm_object_part_content_set(ad->progressBarLayout, "elm.swallow.content", ad->progressBar);
evas_object_show(ad->progressBar);
/* Set a text */
elm_object_part_text_set(ad->progressBarLayout, "elm.text.progressbar", "10");
evas_object_show(ad->win);
}
Sample progressbar not working
Im trying to create a sample application following the example in https://developer.tizen.org/ko/development/guides/native-application/user-interface/efl/ui-components/wearable-ui-components/circle-progressbar for wearable-4.0 but the text in the center of progress bar does not show at all as illustrated in the sample picture.
Im using the following code as instructed.
and EDJ
Can you see any issue with my implementation? I tried both in emu. and Galaxy watch.
BY
16 Apr 2025
Tizen Studio
BY
04 Nov 2024
Tizen Studio
BY
02 Apr 2024
Tizen Studio