@@ -57,36 +57,36 @@ namespace mambapy
57
57
{
58
58
namespace py = pybind11;
59
59
60
- py::enum_<fmt::emphasis>(m, " TextEmphasis" )
61
- .value (" Bold" , fmt::emphasis::bold)
62
- .value (" Faint" , fmt::emphasis::faint)
63
- .value (" Italic" , fmt::emphasis::italic)
64
- .value (" Underline" , fmt::emphasis::underline)
65
- .value (" Blink" , fmt::emphasis::blink)
66
- .value (" Reverse" , fmt::emphasis::reverse)
67
- .value (" Conceal" , fmt::emphasis::conceal)
68
- .value (" Strikethrough" , fmt::emphasis::strikethrough)
69
- .def (py::init (&enum_from_str<fmt::emphasis>));
60
+ auto emphasis = py::enum_<fmt::emphasis>(m, " TextEmphasis" )
61
+ .value (" Bold" , fmt::emphasis::bold)
62
+ .value (" Faint" , fmt::emphasis::faint)
63
+ .value (" Italic" , fmt::emphasis::italic)
64
+ .value (" Underline" , fmt::emphasis::underline)
65
+ .value (" Blink" , fmt::emphasis::blink)
66
+ .value (" Reverse" , fmt::emphasis::reverse)
67
+ .value (" Conceal" , fmt::emphasis::conceal)
68
+ .value (" Strikethrough" , fmt::emphasis::strikethrough);
69
+ emphasis .def (py::init (&enum_from_str<fmt::emphasis>));
70
70
py::implicitly_convertible<py::str, fmt::emphasis>();
71
71
72
- py::enum_<fmt::terminal_color>(m, " TextTerminalColor" )
73
- .value (" Black" , fmt::terminal_color::black)
74
- .value (" Red" , fmt::terminal_color::red)
75
- .value (" Green" , fmt::terminal_color::green)
76
- .value (" Yellow" , fmt::terminal_color::yellow)
77
- .value (" Blue" , fmt::terminal_color::blue)
78
- .value (" Magenta" , fmt::terminal_color::magenta)
79
- .value (" Cyan" , fmt::terminal_color::cyan)
80
- .value (" White" , fmt::terminal_color::white)
81
- .value (" BrightBlack" , fmt::terminal_color::bright_black)
82
- .value (" BrightRed" , fmt::terminal_color::bright_red)
83
- .value (" BrightGreen" , fmt::terminal_color::bright_green)
84
- .value (" BrightYellow" , fmt::terminal_color::bright_yellow)
85
- .value (" BrightBlue" , fmt::terminal_color::bright_blue)
86
- .value (" BrightMagenta" , fmt::terminal_color::bright_magenta)
87
- .value (" BrightCyan" , fmt::terminal_color::bright_cyan)
88
- .value (" BrightWhite" , fmt::terminal_color::bright_white)
89
- .def (py::init (&enum_from_str<fmt::terminal_color>));
72
+ auto terminal_color = py::enum_<fmt::terminal_color>(m, " TextTerminalColor" )
73
+ .value (" Black" , fmt::terminal_color::black)
74
+ .value (" Red" , fmt::terminal_color::red)
75
+ .value (" Green" , fmt::terminal_color::green)
76
+ .value (" Yellow" , fmt::terminal_color::yellow)
77
+ .value (" Blue" , fmt::terminal_color::blue)
78
+ .value (" Magenta" , fmt::terminal_color::magenta)
79
+ .value (" Cyan" , fmt::terminal_color::cyan)
80
+ .value (" White" , fmt::terminal_color::white)
81
+ .value (" BrightBlack" , fmt::terminal_color::bright_black)
82
+ .value (" BrightRed" , fmt::terminal_color::bright_red)
83
+ .value (" BrightGreen" , fmt::terminal_color::bright_green)
84
+ .value (" BrightYellow" , fmt::terminal_color::bright_yellow)
85
+ .value (" BrightBlue" , fmt::terminal_color::bright_blue)
86
+ .value (" BrightMagenta" , fmt::terminal_color::bright_magenta)
87
+ .value (" BrightCyan" , fmt::terminal_color::bright_cyan)
88
+ .value (" BrightWhite" , fmt::terminal_color::bright_white);
89
+ terminal_color .def (py::init (&enum_from_str<fmt::terminal_color>));
90
90
py::implicitly_convertible<py::str, fmt::terminal_color>();
91
91
92
92
py::class_<fmt::rgb>(m, " TextRGBColor" )
0 commit comments