/// <summary> /// Replaces one System.Drawing.Color in the ColorManager with another. /// </summary> /// <param name="oldColor">The color to be replaced.</param> /// <param name="newColor">The replacement color.</param> public void ReplaceColor(Color oldColor, Color newColor) { if (!IsInCompatibilityMode) { ConsoleColor consoleColor = colorStore.Replace(oldColor, newColor); colorMapper.MapColor(consoleColor, newColor); } }
/// <summary> /// Replaces one System.Drawing.Color in the ColorManager with another. /// </summary> /// <param name="oldColor">The color to be replaced.</param> /// <param name="newColor">The replacement color.</param> public void ReplaceColor(Color oldColor, Color newColor) { // If the console exists and Colorful.Console is running on Windows. if (!IsInCompatibilityMode && IsWindows()) { ConsoleColor consoleColor = colorStore.Replace(oldColor, newColor); colorMapper.MapColor(consoleColor, newColor); } }