Image inside a bubble
This code snippet shows how to use image as bubble's conent (like in an mms message).
#define IMG_DIR "/opt/usr/apps/org.example.myapp/res/images"
static void bubble_test(Evas_Object *parent) {
//box for the bubbles
Evas_Object *box = elm_box_add(parent);
evas_object_size_hint_weight_set(box, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_win_resize_object_add(parent, box);
evas_object_show(box);
//create an image
Evas_Object *image = elm_image_add(parent);
char path[100] = { 0 };
snprintf(path, sizeof(path), IMG_DIR"/%s", "image.png");
elm_image_file_set(image, path, NULL);
evas_object_show(image);
//create a bubble
Evas_Object *bubble = elm_bubble_add(parent);
evas_object_size_hint_align_set(bubble, EVAS_HINT_FILL, EVAS_HINT_FILL);
evas_object_size_hint_weight_set(bubble, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_object_part_text_set(bubble, "info", "yesterday");
elm_object_text_set(bubble, "Tom");
elm_box_pack_end(box, bubble);
evas_object_show(bubble);
//set image as bubble's content
elm_object_content_set(bubble, image);
}