Ejemplo n.º 1
0
 public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
 {
     var c = new HslColor((Color) value)
                 {Luminance = System.Convert.ToSingle(parameter, CultureInfo.InvariantCulture)};
     return (Color) c;
 }
Ejemplo n.º 2
0
 public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture)
 {
     HslColor c = new HslColor((Color)value);
     c.Luminance = System.Convert.ToSingle(parameter, System.Globalization.CultureInfo.InvariantCulture);
     return (Color)c;
 }