Пример #1
0
 public static string ColorPivot(int val, int pivot)
 {
     return(val <pivot?ColorCoder.ErrorBright(val) : val> pivot ? ColorCoder.SuccessDim(val) : $"{val}");
 }
Пример #2
0
 public static string ColorPivotPercent(double val, double pivot, string valStr = null)
 {
     valStr = valStr ?? $"{val:0.##}%";
     return(val <0 ? ColorCoder.ErrorBright(valStr) : val> pivot ? ColorCoder.SuccessDim(valStr) : $"{valStr}");
 }