Learn R Programming

terminalgraphics (version 0.2.1)

term_color_mode: Get the color mode of the terminal

Description

Get the color mode of the terminal

Usage

term_color_mode()

Arguments

Value

Returns NA when the terminal does not support querying the color mode. Otherwise returns either 'dark' or 'light'.

Details

Uses ANSI SI ? 996 n to determine the color mode. See https://contour-terminal.org/vt-extensions/color-palette-update-notifications/.

Examples

Run this code
term_color_mode()

Run the code above in your browser using DataLab