mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-06-11 03:32:46 +08:00
parent
1495285a6a
commit
21c7374177
1
.github/actions/spell-check/expect.txt
vendored
1
.github/actions/spell-check/expect.txt
vendored
@ -375,7 +375,6 @@ CXSMICON
|
|||||||
CXVIRTUALSCREEN
|
CXVIRTUALSCREEN
|
||||||
cxx
|
cxx
|
||||||
cxxopts
|
cxxopts
|
||||||
CYMK
|
|
||||||
CYSMICON
|
CYSMICON
|
||||||
cziplib
|
cziplib
|
||||||
Dac
|
Dac
|
||||||
|
@ -13,7 +13,7 @@ namespace ColorPicker.Helpers
|
|||||||
internal static class ColorHelper
|
internal static class ColorHelper
|
||||||
{
|
{
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Convert a given <see cref="Color"/> to a CYMK color (cyan, magenta, yellow, black key)
|
/// Convert a given <see cref="Color"/> to a CMYK color (cyan, magenta, yellow, black key)
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="color">The <see cref="Color"/> to convert</param>
|
/// <param name="color">The <see cref="Color"/> to convert</param>
|
||||||
/// <returns>The cyan[0..1], magenta[0..1], yellow[0..1] and black key[0..1] of the converted color</returns>
|
/// <returns>The cyan[0..1], magenta[0..1], yellow[0..1] and black key[0..1] of the converted color</returns>
|
||||||
|
@ -35,7 +35,7 @@ namespace ColorPicker.Helpers
|
|||||||
internal static string GetStringRepresentation(Color color, ColorRepresentationType colorRepresentationType)
|
internal static string GetStringRepresentation(Color color, ColorRepresentationType colorRepresentationType)
|
||||||
=> colorRepresentationType switch
|
=> colorRepresentationType switch
|
||||||
{
|
{
|
||||||
ColorRepresentationType.CMYK => ColorToCYMK(color),
|
ColorRepresentationType.CMYK => ColorToCMYK(color),
|
||||||
ColorRepresentationType.HEX => ColorToHex(color),
|
ColorRepresentationType.HEX => ColorToHex(color),
|
||||||
ColorRepresentationType.HSB => ColorToHSB(color),
|
ColorRepresentationType.HSB => ColorToHSB(color),
|
||||||
ColorRepresentationType.HSI => ColorToHSI(color),
|
ColorRepresentationType.HSI => ColorToHSI(color),
|
||||||
@ -50,11 +50,11 @@ namespace ColorPicker.Helpers
|
|||||||
};
|
};
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Return a <see cref="string"/> representation of a CYMK color
|
/// Return a <see cref="string"/> representation of a CMYK color
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="color">The <see cref="Color"/> for the CYMK color presentation</param>
|
/// <param name="color">The <see cref="Color"/> for the CMYK color presentation</param>
|
||||||
/// <returns>A <see cref="string"/> representation of a CYMK color</returns>
|
/// <returns>A <see cref="string"/> representation of a CMYK color</returns>
|
||||||
private static string ColorToCYMK(Color color)
|
private static string ColorToCMYK(Color color)
|
||||||
{
|
{
|
||||||
var (cyan, magenta, yellow, blackKey) = ColorHelper.ConvertToCMYKColor(color);
|
var (cyan, magenta, yellow, blackKey) = ColorHelper.ConvertToCMYKColor(color);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user