Add documentation about EnvColorProfile
Christian Muehlhaeuser
2 years ago
46 | 46 |
- `termenv.ANSI` - 16 color ANSI support
|
47 | 47 |
- `termenv.ANSI256` - Extended 256 color ANSI support
|
48 | 48 |
- `termenv.TrueColor` - RGB/TrueColor support
|
|
49 |
|
|
50 |
Alternatively, you can use `termenv.EnvColorProfile` which evaluates the
|
|
51 |
terminal like `ColorProfile`, but also respects the `NO_COLOR` and
|
|
52 |
`CLICOLOR_FORCE` environment variables.
|
49 | 53 |
|
50 | 54 |
You can also query the terminal for its color scheme, so you know whether your
|
51 | 55 |
app is running in a light- or dark-themed environment:
|
50 | 50 |
|
51 | 51 |
// EnableWindowsANSIConsole enables virtual terminal processing on Windows
|
52 | 52 |
// platforms. This allows the use of ANSI escape sequences in Windows console
|
53 | |
// applications. Ensure this gets called before anything gets rendered with
|
|
53 |
// applications. Ensure this gets called before anything gets rendered with
|
54 | 54 |
// termenv.
|
55 | 55 |
//
|
56 | 56 |
// Returns the original console mode and an error if one occurred.
|