3#include "di/container/string/prelude.h"
4#include "di/reflect/prelude.h"
5#include "di/types/integers.h"
6#include "di/vocab/optional/prelude.h"
7#include "di/vocab/span/prelude.h"
44 constexpr friend auto tag_invoke(di::Tag<di::reflect>, di::InPlaceType<Color>) {
50constexpr auto tag_invoke(di::Tag<di::reflect>, di::InPlaceType<Color::Palette>) {
52 return di::make_enumerators<
"Color::Palette">(
53 di::enumerator<
"None",
None>, di::enumerator<
"Custom", Custom>, di::enumerator<
"Black", Black>,
54 di::enumerator<
"Red", Red>, di::enumerator<
"Green", Green>, di::enumerator<
"Brown", Brown>,
55 di::enumerator<
"Blue", Blue>, di::enumerator<
"Magenta", Magenta>, di::enumerator<
"Cyan", Cyan>,
56 di::enumerator<
"LightGrey", LightGrey>, di::enumerator<
"DarkGrey", DarkGrey>,
57 di::enumerator<
"LightRed", LightRed>, di::enumerator<
"LightGreen", LightGreen>,
58 di::enumerator<
"Yellow", Yellow>, di::enumerator<
"LightBlue", LightBlue>,
59 di::enumerator<
"LightMagenta", LightMagenta>, di::enumerator<
"LightCyan", LightCyan>,
60 di::enumerator<
"White", White>);
69constexpr auto tag_invoke(di::Tag<di::reflect>, di::InPlaceType<BlinkMode>) {
71 return di::make_enumerators<
"BlinkMode">(di::enumerator<
"None",
None>, di::enumerator<
"Normal",
Normal>,
72 di::enumerator<
"Rapid",
Rapid>);
81constexpr auto tag_invoke(di::Tag<di::reflect>, di::InPlaceType<FontWeight>) {
83 return di::make_enumerators<
"FontWeight">(di::enumerator<
"None",
None>, di::enumerator<
"Bold",
Bold>,
84 di::enumerator<
"Dim",
Dim>);
96constexpr auto tag_invoke(di::Tag<di::reflect>, di::InPlaceType<UnderlineMode>) {
98 return di::make_enumerators<
"UnderlineMode">(di::enumerator<
"None",
None>, di::enumerator<
"Normal",
Normal>,
99 di::enumerator<
"Double",
Double>, di::enumerator<
"Curly",
Curly>,
100 di::enumerator<
"Dotted",
Dotted>, di::enumerator<
"Dashed",
Dashed>);
128 return di::make_fields<
"GraphicsRendition">(
Definition test_params.cpp:4
Definition cursor_style.h:5
BlinkMode
Definition graphics_rendition.h:63
@ None
Definition graphics_rendition.h:64
@ Normal
Definition graphics_rendition.h:65
@ Rapid
Definition graphics_rendition.h:66
@ None
Definition direction.h:8
constexpr auto tag_invoke(di::Tag< di::reflect >, di::InPlaceType< CursorStyle >)
Definition cursor_style.h:16
UnderlineMode
Definition graphics_rendition.h:87
@ None
Definition graphics_rendition.h:88
@ Dotted
Definition graphics_rendition.h:92
@ Double
Definition graphics_rendition.h:90
@ Curly
Definition graphics_rendition.h:91
@ Dashed
Definition graphics_rendition.h:93
FontWeight
Definition graphics_rendition.h:75
@ Bold
Definition graphics_rendition.h:77
@ None
Definition graphics_rendition.h:76
@ Dim
Definition graphics_rendition.h:78
Definition graphics_rendition.h:11
Palette
Definition graphics_rendition.h:12
@ LightGreen
Definition graphics_rendition.h:25
@ DarkGrey
Definition graphics_rendition.h:23
@ LightCyan
Definition graphics_rendition.h:29
@ Yellow
Definition graphics_rendition.h:26
@ Custom
Definition graphics_rendition.h:14
@ Red
Definition graphics_rendition.h:16
@ Brown
Definition graphics_rendition.h:18
@ LightRed
Definition graphics_rendition.h:24
@ Cyan
Definition graphics_rendition.h:21
@ None
Definition graphics_rendition.h:13
@ LightGrey
Definition graphics_rendition.h:22
@ LightMagenta
Definition graphics_rendition.h:28
@ Blue
Definition graphics_rendition.h:19
@ LightBlue
Definition graphics_rendition.h:27
@ Green
Definition graphics_rendition.h:17
@ White
Definition graphics_rendition.h:30
@ Magenta
Definition graphics_rendition.h:20
@ Black
Definition graphics_rendition.h:15
constexpr friend auto tag_invoke(di::Tag< di::reflect >, di::InPlaceType< Color >)
Definition graphics_rendition.h:44
Palette c
Definition graphics_rendition.h:37
u8 r
Definition graphics_rendition.h:38
auto operator==(Color const &other) const -> bool=default
u8 b
Definition graphics_rendition.h:40
u8 g
Definition graphics_rendition.h:39
constexpr Color(u8 r, u8 g, u8 b)
Definition graphics_rendition.h:35
constexpr Color(Palette c)
Definition graphics_rendition.h:34
Definition graphics_rendition.h:103
static auto from_csi_params(Params const ¶ms)
Definition graphics_rendition.h:117
bool strike_through
Definition graphics_rendition.h:115
bool italic
Definition graphics_rendition.h:111
BlinkMode blink_mode
Definition graphics_rendition.h:109
auto as_csi_params() const -> di::Vector< Params >
Definition graphics_rendition.cpp:261
constexpr friend auto tag_invoke(di::Tag< di::reflect >, di::InPlaceType< GraphicsRendition >)
Definition graphics_rendition.h:127
Color fg
Definition graphics_rendition.h:104
UnderlineMode underline_mode
Definition graphics_rendition.h:110
void update_with_csi_params(Params const ¶ms)
Definition graphics_rendition.cpp:81
Color underline_color
Definition graphics_rendition.h:106
Color bg
Definition graphics_rendition.h:105
bool invisible
Definition graphics_rendition.h:114
FontWeight font_weight
Definition graphics_rendition.h:108
bool overline
Definition graphics_rendition.h:112
bool inverted
Definition graphics_rendition.h:113