예제 #1
0
 public static void WriteSegment(string label, BiColor colors)
 {
     SaveColors();
     CurrentColors = colors;
     WriteSegment(label);
     ResetColors();
 }
예제 #2
0
 public static void WriteSegment(string label, ConsoleColor foregroundcolor, ConsoleColor backgroundcolor)
 {
     SaveColors();
     CurrentColors = new BiColor {
         BackgroundColor = backgroundcolor, ForegroundColor = foregroundcolor
     };
     WriteSegment(label);
     ResetColors();
 }
예제 #3
0
        public static void SaveColor(ConsoleColor color, bool @isforegroundcolor = true)
        {
            BiColor colors = SavedColors;

            if (isforegroundcolor)
            {
                colors.ForegroundColor = color;
            }
            else
            {
                colors.BackgroundColor = color;
            }
            SavedColors = colors;
        }
예제 #4
0
 public static void WriteLineSegment(string label, BiColor colors)
 {
     WriteSegment(label, colors);
     System.Console.WriteLine();
 }
예제 #5
0
 public static void SetAndSaveColors(BiColor colors)
 {
     SavedColors = colors;
     ResetColors();
 }