[ColorPicker] Unify HEX color to lower case (#16492)

This commit is contained in:
Stefan Markovic
2022-02-22 09:28:05 +01:00
committed by GitHub
parent 4cc74602c1
commit e9dccf82ab

View File

@@ -79,9 +79,9 @@ namespace ColorPicker.Helpers
/// <param name="color">The see cref="Color"/> for the hexadecimal presentation</param> /// <param name="color">The see cref="Color"/> for the hexadecimal presentation</param>
/// <returns>A hexadecimal <see cref="string"/> representation of a RGB color</returns> /// <returns>A hexadecimal <see cref="string"/> representation of a RGB color</returns>
private static string ColorToHex(Color color) private static string ColorToHex(Color color)
=> $"{color.R.ToString("X2", CultureInfo.InvariantCulture)}" => $"{color.R.ToString("x2", CultureInfo.InvariantCulture)}"
+ $"{color.G.ToString("X2", CultureInfo.InvariantCulture)}" + $"{color.G.ToString("x2", CultureInfo.InvariantCulture)}"
+ $"{color.B.ToString("X2", CultureInfo.InvariantCulture)}"; + $"{color.B.ToString("x2", CultureInfo.InvariantCulture)}";
/// <summary> /// <summary>
/// Return a <see cref="string"/> representation of a HSB color /// Return a <see cref="string"/> representation of a HSB color