private ConsoleColorTheme(ConsoleColor foregroundColour, ConsoleColor backgroundColour, ConsoleColorDefaultThemes theme) { this.Mappings = new ConsoleColorExt[0x20]; switch (theme) { case ConsoleColorDefaultThemes.None: this.SetNoTheme(foregroundColour, backgroundColour); return; case ConsoleColorDefaultThemes.HighContrast: this.SetHighContrastTheme(foregroundColour, backgroundColour); return; } }
public static ConsoleColorTheme Load(ConsoleColor foregroundColour, ConsoleColor backgroundColour, ConsoleColorDefaultThemes theme) { Stream manifestResourceStream; Assembly assembly = typeof(ConsoleColorTheme).Assembly; switch (theme) { case ConsoleColorDefaultThemes.None: case ConsoleColorDefaultThemes.HighContrast: return new ConsoleColorTheme(foregroundColour, backgroundColour, theme); case ConsoleColorDefaultThemes.Simple: manifestResourceStream = assembly.GetManifestResourceStream(typeof(ConsoleColorTheme), "Simple.ctheme"); return Load(backgroundColour, manifestResourceStream); case ConsoleColorDefaultThemes.Colorful: manifestResourceStream = assembly.GetManifestResourceStream(typeof(ConsoleColorTheme), "Colorful.ctheme"); return Load(backgroundColour, manifestResourceStream); } return new ConsoleColorTheme(foregroundColour, backgroundColour, ConsoleColorDefaultThemes.None); }
public static ConsoleColorTheme Load(ConsoleColor foregroundColour, ConsoleColor backgroundColour, ConsoleColorDefaultThemes theme) { Stream manifestResourceStream; Assembly assembly = typeof(ConsoleColorTheme).Assembly; switch (theme) { case ConsoleColorDefaultThemes.None: case ConsoleColorDefaultThemes.HighContrast: return(new ConsoleColorTheme(foregroundColour, backgroundColour, theme)); case ConsoleColorDefaultThemes.Simple: manifestResourceStream = assembly.GetManifestResourceStream(typeof(ConsoleColorTheme), "Simple.ctheme"); return(Load(backgroundColour, manifestResourceStream)); case ConsoleColorDefaultThemes.Colorful: manifestResourceStream = assembly.GetManifestResourceStream(typeof(ConsoleColorTheme), "Colorful.ctheme"); return(Load(backgroundColour, manifestResourceStream)); } return(new ConsoleColorTheme(foregroundColour, backgroundColour, ConsoleColorDefaultThemes.None)); }
public static ConsoleColorTheme Load(ConsoleColorDefaultThemes theme) { return(Load((ConsoleColor)RugConsole.ForegroundColor, (ConsoleColor)RugConsole.BackgroundColor, theme)); }
public static ConsoleColorTheme Load(ConsoleColorDefaultThemes theme) { return Load((ConsoleColor) RugConsole.ForegroundColor, (ConsoleColor) RugConsole.BackgroundColor, theme); }