C# 클래스 Colorful.ColorManager

Manages the number of different colors that the Windows console is able to display in a given session.
파일 보기 프로젝트 열기: tomakita/Colorful.Console 1 사용 예제들

공개 메소드들

메소드 설명
ColorManager ( ColorStore colorStore, ColorMapper colorMapper, int maxColorChanges, int initialColorChangeCountValue ) : System

Manages the number of different colors that the Windows console is able to display in a given session.

GetColor ( ConsoleColor color ) : Color

Gets the System.Drawing.Color mapped to the ConsoleColor provided as an argument.

GetConsoleColor ( Color color ) : ConsoleColor

Gets the ConsoleColor mapped to the System.Drawing.Color provided as an argument.

비공개 메소드들

메소드 설명
CanChangeColor ( ) : bool
GetConsoleColorNative ( Color color ) : ConsoleColor

메소드 상세

ColorManager() 공개 메소드

Manages the number of different colors that the Windows console is able to display in a given session.
public ColorManager ( ColorStore colorStore, ColorMapper colorMapper, int maxColorChanges, int initialColorChangeCountValue ) : System
colorStore ColorStore The ColorStore instance in which the ColorManager will store colors.
colorMapper ColorMapper The ColorMapper instance the ColorManager will use to relate different color /// types to one another.
maxColorChanges int The maximum number of color changes allowed by the ColorManager. It's /// necessary to keep track of this, because the Windows console can only display 16 different colors in /// a given session.
initialColorChangeCountValue int The number of color changes which have already occurred.
리턴 System

GetColor() 공개 메소드

Gets the System.Drawing.Color mapped to the ConsoleColor provided as an argument.
public GetColor ( ConsoleColor color ) : Color
color ConsoleColor The ConsoleColor alias under which the desired System.Drawing.Color is stored.
리턴 Color

GetConsoleColor() 공개 메소드

Gets the ConsoleColor mapped to the System.Drawing.Color provided as an argument.
public GetConsoleColor ( Color color ) : ConsoleColor
color Color The System.Drawing.Color whose ConsoleColor alias should be retrieved.
리턴 ConsoleColor