modules: port to GIMP_CONFIG_PROP_FOO()

This commit is contained in:
Michael Natterer 2016-04-17 00:11:39 +01:00
parent 65d3ce7cb8
commit 9fd0c74ebe
4 changed files with 40 additions and 26 deletions

View file

@ -247,11 +247,13 @@ cdisplay_colorblind_class_init (CdisplayColorblindClass *klass)
object_class->get_property = cdisplay_colorblind_get_property; object_class->get_property = cdisplay_colorblind_get_property;
object_class->set_property = cdisplay_colorblind_set_property; object_class->set_property = cdisplay_colorblind_set_property;
GIMP_CONFIG_INSTALL_PROP_ENUM (object_class, PROP_DEFICIENCY, GIMP_CONFIG_PROP_ENUM (object_class, PROP_DEFICIENCY,
"deficiency", NULL, "deficiency",
CDISPLAY_TYPE_COLORBLIND_DEFICIENCY, _("Deficiency"),
DEFAULT_DEFICIENCY, NULL,
0); CDISPLAY_TYPE_COLORBLIND_DEFICIENCY,
DEFAULT_DEFICIENCY,
0);
display_class->name = _("Color Deficient Vision"); display_class->name = _("Color Deficient Vision");
display_class->help_id = "gimp-colordisplay-colorblind"; display_class->help_id = "gimp-colordisplay-colorblind";

View file

@ -119,10 +119,12 @@ cdisplay_gamma_class_init (CdisplayGammaClass *klass)
object_class->get_property = cdisplay_gamma_get_property; object_class->get_property = cdisplay_gamma_get_property;
object_class->set_property = cdisplay_gamma_set_property; object_class->set_property = cdisplay_gamma_set_property;
GIMP_CONFIG_INSTALL_PROP_DOUBLE (object_class, PROP_GAMMA, GIMP_CONFIG_PROP_DOUBLE (object_class, PROP_GAMMA,
"gamma", NULL, "gamma",
0.01, 10.0, DEFAULT_GAMMA, _("Gamma"),
0); NULL,
0.01, 10.0, DEFAULT_GAMMA,
0);
display_class->name = _("Gamma"); display_class->name = _("Gamma");
display_class->help_id = "gimp-colordisplay-gamma"; display_class->help_id = "gimp-colordisplay-gamma";

View file

@ -119,10 +119,12 @@ cdisplay_contrast_class_init (CdisplayContrastClass *klass)
object_class->get_property = cdisplay_contrast_get_property; object_class->get_property = cdisplay_contrast_get_property;
object_class->set_property = cdisplay_contrast_set_property; object_class->set_property = cdisplay_contrast_set_property;
GIMP_CONFIG_INSTALL_PROP_DOUBLE (object_class, PROP_CONTRAST, GIMP_CONFIG_PROP_DOUBLE (object_class, PROP_CONTRAST,
"contrast", NULL, "contrast",
0.01, 10.0, DEFAULT_CONTRAST, _("Contrast"),
0); NULL,
0.01, 10.0, DEFAULT_CONTRAST,
0);
display_class->name = _("Contrast"); display_class->name = _("Contrast");
display_class->help_id = "gimp-colordisplay-contrast"; display_class->help_id = "gimp-colordisplay-contrast";

View file

@ -126,19 +126,27 @@ cdisplay_proof_class_init (CdisplayProofClass *klass)
object_class->get_property = cdisplay_proof_get_property; object_class->get_property = cdisplay_proof_get_property;
object_class->set_property = cdisplay_proof_set_property; object_class->set_property = cdisplay_proof_set_property;
GIMP_CONFIG_INSTALL_PROP_ENUM (object_class, PROP_INTENT, GIMP_CONFIG_PROP_ENUM (object_class, PROP_INTENT,
"intent", NULL, "intent",
GIMP_TYPE_COLOR_RENDERING_INTENT, _("Intent"),
GIMP_COLOR_RENDERING_INTENT_PERCEPTUAL, NULL,
0); GIMP_TYPE_COLOR_RENDERING_INTENT,
GIMP_CONFIG_INSTALL_PROP_BOOLEAN (object_class, PROP_BPC, GIMP_COLOR_RENDERING_INTENT_PERCEPTUAL,
"black-point-compensation", NULL, 0);
FALSE,
0); GIMP_CONFIG_PROP_BOOLEAN (object_class, PROP_BPC,
GIMP_CONFIG_INSTALL_PROP_PATH (object_class, PROP_PROFILE, "black-point-compensation",
"profile", NULL, _("Black point compensation"),
GIMP_CONFIG_PATH_FILE, NULL, NULL,
0); FALSE,
0);
GIMP_CONFIG_PROP_PATH (object_class, PROP_PROFILE,
"profile",
_("Profile"),
NULL,
GIMP_CONFIG_PATH_FILE, NULL,
0);
display_class->name = _("Color Proof"); display_class->name = _("Color Proof");
display_class->help_id = "gimp-colordisplay-proof"; display_class->help_id = "gimp-colordisplay-proof";