Author: akv
Date: 2013-04-23 23:52:48 +0200 (Tue, 23 Apr 2013)
New Revision: 4358
Modified:
branches/4175-enfuse/src/gtk-helper.c
branches/4175-enfuse/src/gtk-helper.h
branches/4175-enfuse/src/rs-actions.c
Log:
Updated Enfuse dialog to use a combo_box and check_box - not done yet.
Modified: branches/4175-enfuse/src/gtk-helper.c
===================================================================
--- branches/4175-enfuse/src/gtk-helper.c 2013-04-23 21:51:46 UTC (rev
4357)
+++ branches/4175-enfuse/src/gtk-helper.c 2013-04-23 21:52:48 UTC (rev
4358)
@@ -832,3 +832,20 @@
RSIccProfile* profile = rs_icc_profile_new_from_memory((gchar*)buffer,
buffer_size, FALSE);
return rs_color_space_icc_new_from_icc(profile);
}
+
+GtkWidget *
+rs_combobox_new(const gchar *text, GtkListStore *store, const gchar *conf_key)
+{
+ GtkWidget *combo = gtk_combo_box_new_with_model(GTK_TREE_MODEL(store));
+ GtkWidget *hbox = gtk_hbox_new(FALSE, 0);
+ GtkWidget *label = gtk_label_new(text);
+ gtk_box_pack_start(GTK_BOX(hbox), label, TRUE, TRUE, 5);
+ gtk_box_pack_start(GTK_BOX(hbox), combo, TRUE, TRUE, 5);
+
+ GtkCellRenderer *cell = gtk_cell_renderer_text_new();
+ gtk_cell_layout_pack_start(GTK_CELL_LAYOUT(combo), cell, TRUE);
+ gtk_cell_layout_set_attributes(GTK_CELL_LAYOUT(combo), cell, "text", 0,
NULL);
+ gtk_combo_box_set_active(GTK_COMBO_BOX(combo), 0);
+
+ return hbox;
+}
Modified: branches/4175-enfuse/src/gtk-helper.h
===================================================================
--- branches/4175-enfuse/src/gtk-helper.h 2013-04-23 21:51:46 UTC (rev
4357)
+++ branches/4175-enfuse/src/gtk-helper.h 2013-04-23 21:52:48 UTC (rev
4358)
@@ -91,3 +91,5 @@
extern GtkWidget * gui_box(const gchar *title, GtkWidget *in, gchar *key,
gboolean default_expanded);
extern RSColorSpace* rs_get_display_profile(GtkWidget *widget);
+
+extern GtkWidget * rs_combobox_new(const gchar *text, GtkListStore *store,
const gchar *conf_key);
Modified: branches/4175-enfuse/src/rs-actions.c
===================================================================
--- branches/4175-enfuse/src/rs-actions.c 2013-04-23 21:51:46 UTC (rev
4357)
+++ branches/4175-enfuse/src/rs-actions.c 2013-04-23 21:52:48 UTC (rev
4358)
@@ -1542,7 +1542,24 @@
GtkWidget *content = gtk_dialog_get_content_area(GTK_DIALOG(dialog));
GtkWidget *image = gtk_image_new_from_file(thumb);
- gtk_container_add(GTK_CONTAINER(content), image);
+
+ GtkWidget *vbox = gtk_vbox_new(FALSE, 5);
+ gtk_box_pack_start(GTK_BOX(vbox), image, TRUE, TRUE, 5);
+
+ GtkListStore *enfuse_methods = gtk_list_store_new( 1, G_TYPE_STRING );
+ GtkTreeIter iter;
+ gtk_list_store_append(enfuse_methods, &iter);
+ gtk_list_store_set(enfuse_methods, &iter, 0, "Exposure Blending", -1 );
+ gtk_list_store_append(enfuse_methods, &iter);
+ gtk_list_store_set(enfuse_methods, &iter, 0, "Focus Stacking", -1 );
+
+ GtkWidget *enfuse_method_combo = rs_combobox_new(_("Enfuse method"),
enfuse_methods, CONF_ENFUSE_METHOD);
+ gtk_box_pack_start(GTK_BOX(vbox), enfuse_method_combo, TRUE, TRUE, 5);
+
+ GtkWidget *align_check = checkbox_from_conf(CONF_ENFUSE_ALIGN_IMAGES,
_("Align images (may take a long time)"), DEFAULT_CONF_ENFUSE_ALIGN_IMAGES);
+ gtk_box_pack_start(GTK_BOX(vbox), align_check, TRUE, TRUE, 5);
+
+ gtk_container_add(GTK_CONTAINER(content), vbox);
gtk_widget_show_all(dialog);
if (gtk_dialog_run(GTK_DIALOG(dialog)) != GTK_RESPONSE_ACCEPT)
_______________________________________________
Rawstudio-commit mailing list
[email protected]
http://rawstudio.org/cgi-bin/mailman/listinfo/rawstudio-commit