app: display profile name in "Color space" field of Image Properties.
"RGB color" is not a color space, only the model. To get full color space information, we want to display the model and associated profile name. Of course, the "Image Properties" dialog also has a tab displaying details about the color profile. Still it's better if the general info displays not too wrong label contents. Note: when the used color profile has no name, it will show "(unnamed profile)" which is still more informative than just the color model.
This commit is contained in:
@ -25,6 +25,7 @@
|
||||
#include <gtk/gtk.h>
|
||||
|
||||
#include "libgimpbase/gimpbase.h"
|
||||
#include "libgimpcolor/gimpcolor.h"
|
||||
#include "libgimpwidgets/gimpwidgets.h"
|
||||
|
||||
#include "widgets-types.h"
|
||||
@ -409,6 +410,7 @@ static void
|
||||
gimp_image_prop_view_update (GimpImagePropView *view)
|
||||
{
|
||||
GimpImage *image = view->image;
|
||||
GimpColorProfile *profile;
|
||||
GimpImageBaseType type;
|
||||
GimpPrecision precision;
|
||||
GimpUnit unit;
|
||||
@ -453,9 +455,8 @@ gimp_image_prop_view_update (GimpImagePropView *view)
|
||||
unit == GIMP_UNIT_INCH ? _("ppi") : format_buf);
|
||||
gtk_label_set_text (GTK_LABEL (view->resolution_label), buf);
|
||||
|
||||
/* color type */
|
||||
/* color space */
|
||||
type = gimp_image_get_base_type (image);
|
||||
|
||||
gimp_enum_get_value (GIMP_TYPE_IMAGE_BASE_TYPE, type,
|
||||
NULL, NULL, &desc, NULL);
|
||||
|
||||
@ -463,7 +464,9 @@ gimp_image_prop_view_update (GimpImagePropView *view)
|
||||
{
|
||||
case GIMP_RGB:
|
||||
case GIMP_GRAY:
|
||||
g_snprintf (buf, sizeof (buf), "%s", desc);
|
||||
profile = gimp_color_managed_get_color_profile (GIMP_COLOR_MANAGED (image));
|
||||
g_snprintf (buf, sizeof (buf), "%s: %s", desc,
|
||||
gimp_color_profile_get_label (profile));
|
||||
break;
|
||||
case GIMP_INDEXED:
|
||||
g_snprintf (buf, sizeof (buf),
|
||||
|
Reference in New Issue
Block a user