/// <summary> /// Преобразовать наименование цвета в цветовое значение /// </summary> public static ColorPrintType ColorPrintFromString(string colorPrint) => ColorPrintTypesString.FirstOrDefault(color => color.Value == colorPrint).Key;
/// <summary> /// Преобразовать цветовое значение в наименование цвета /// </summary> public static string ColorPrintToString(ColorPrintType colorPrintType) { ColorPrintTypesString.TryGetValue(colorPrintType, out string colorPrintString); return(colorPrintString); }