Commit 017af36f authored by Sven Neumann's avatar Sven Neumann Committed by Sven Neumann
Browse files

also use bold, right-aligned labels here.

2005-06-26  Sven Neumann  <sven@gimp.org>

	* modules/cdisplay_lcms.c: also use bold, right-aligned labels here.
parent 9588588f
2005-06-26 Sven Neumann <sven@gimp.org>
* modules/cdisplay_lcms.c: also use bold, right-aligned labels here.
2005-06-25 Manish Singh <yosh@gimp.org>
* app/core/gimpinterpreterdb.c: eat CRs too, since they might be
......
......@@ -93,6 +93,10 @@ static cmsHPROFILE cdisplay_lcms_get_rgb_profile (CdisplayLcms *lcms);
static cmsHPROFILE cdisplay_lcms_get_display_profile (CdisplayLcms *lcms);
static cmsHPROFILE cdisplay_lcms_get_printer_profile (CdisplayLcms *lcms);
static void cdisplay_lcms_attach_labelled (GtkTable *table,
gint row,
const gchar *text,
GtkWidget *widget);
static const GimpModuleInfo cdisplay_lcms_info =
{
......@@ -279,10 +283,10 @@ cdisplay_lcms_configure (GimpColorDisplay *display)
"xalign", 0.0,
"yalign", 0.5,
NULL);
gimp_label_set_attributes (GTK_LABEL (label),
PANGO_ATTR_STYLE, PANGO_STYLE_ITALIC
PANGO_ATTR_STYLE, PANGO_STYLE_ITALIC,
-1);
gtk_box_pack_start (GTK_BOX (hbox), label, FALSE, FALSE, 0);
gtk_widget_show (label);
......@@ -293,10 +297,9 @@ cdisplay_lcms_configure (GimpColorDisplay *display)
gtk_box_pack_start (GTK_BOX (vbox), table, FALSE, FALSE, 0);
gtk_widget_show (table);
label = gimp_prop_enum_label_new (config, "mode");
gimp_table_attach_aligned (GTK_TABLE (table), 0, row++,
cdisplay_lcms_attach_labelled (GTK_TABLE (table), row++,
_("Mode of operation:"),
0.0, 0.5, label, 1, TRUE);
gimp_prop_enum_label_new (config, "mode"));
/* FIXME: need to update label with config changes */
profile = cdisplay_lcms_get_rgb_profile (lcms);
......@@ -304,10 +307,9 @@ cdisplay_lcms_configure (GimpColorDisplay *display)
if (profile)
cmsCloseProfile (profile);
label = gtk_label_new (name);
gimp_table_attach_aligned (GTK_TABLE (table), 0, row++,
cdisplay_lcms_attach_labelled (GTK_TABLE (table), row++,
_("RGB workspace profile:"),
0.0, 0.5, label, 1, TRUE);
gtk_label_new (name));
/* FIXME: need to update label with config changes */
profile = cdisplay_lcms_get_display_profile (lcms);
......@@ -315,10 +317,9 @@ cdisplay_lcms_configure (GimpColorDisplay *display)
if (profile)
cmsCloseProfile (profile);
label = gtk_label_new (name);
gimp_table_attach_aligned (GTK_TABLE (table), 0, row++,
cdisplay_lcms_attach_labelled (GTK_TABLE (table), row++,
_("Monitor profile:"),
0.0, 0.5, label, 1, TRUE);
gtk_label_new (name));
/* FIXME: need to update label with config changes */
profile = cdisplay_lcms_get_printer_profile (lcms);
......@@ -326,10 +327,9 @@ cdisplay_lcms_configure (GimpColorDisplay *display)
if (profile)
cmsCloseProfile (profile);
label = gtk_label_new (name);
gimp_table_attach_aligned (GTK_TABLE (table), 0, row++,
cdisplay_lcms_attach_labelled (GTK_TABLE (table), row++,
_("Print simulation profile:"),
0.0, 0.5, label, 1, TRUE);
gtk_label_new (name));
return vbox;
}
......@@ -505,3 +505,34 @@ cdisplay_lcms_get_printer_profile (CdisplayLcms *lcms)
return NULL;
}
static void
cdisplay_lcms_attach_labelled (GtkTable *table,
gint row,
const gchar *text,
GtkWidget *widget)
{
GtkWidget *label;
GtkWidget *hbox;
label = g_object_new (GTK_TYPE_LABEL,
"label", text,
"xalign", 1.0,
"yalign", 0.5,
NULL);
gimp_label_set_attributes (GTK_LABEL (label),
PANGO_ATTR_WEIGHT, PANGO_WEIGHT_BOLD,
-1);
gtk_table_attach (table, label,
0, 1, row, row + 1, GTK_FILL, GTK_FILL, 0, 0);
gtk_widget_show (label);
hbox = gtk_hbox_new (FALSE, 0);
gtk_table_attach (table, hbox,
1, 2, row, row + 1, GTK_FILL | GTK_EXPAND, GTK_FILL, 0, 0);
gtk_widget_show (hbox);
gtk_box_pack_start (GTK_BOX (hbox), widget, FALSE, FALSE, 0);
gtk_widget_show (widget);
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment