summaryrefslogtreecommitdiff
path: root/include/ncurses/char_attributes.hpp
diff options
context:
space:
mode:
authorDaniil Rozanov <dev@rozanov.info>2025-03-15 18:03:23 +0400
committerDaniil Rozanov <dev@rozanov.info>2025-03-15 18:03:23 +0400
commit4a9ce6e2555dfaf9155fa279f25667350377f688 (patch)
tree11bc0ea3a7b1c0be2c47419b7058d46d16e5f9f4 /include/ncurses/char_attributes.hpp
feat: chtype wrap
Diffstat (limited to 'include/ncurses/char_attributes.hpp')
-rw-r--r--include/ncurses/char_attributes.hpp40
1 files changed, 40 insertions, 0 deletions
diff --git a/include/ncurses/char_attributes.hpp b/include/ncurses/char_attributes.hpp
new file mode 100644
index 0000000..9d45488
--- /dev/null
+++ b/include/ncurses/char_attributes.hpp
@@ -0,0 +1,40 @@
+#ifndef INCLUDE_NCURSES_CHAR_ATTRIBUTES_HPP_
+#define INCLUDE_NCURSES_CHAR_ATTRIBUTES_HPP_
+
+#include <ncurses/utils/preamble.hpp>
+
+#include <ncurses/utils/flags.hpp>
+
+namespace NCURSES_CPP_NAMESPACE {
+
+enum class attr : attr_t {
+ normal = A_NORMAL,
+ attributes = A_ATTRIBUTES,
+ chartext = A_CHARTEXT,
+ color = A_COLOR,
+ standout = A_STANDOUT,
+ underline = A_UNDERLINE,
+ reverse = A_REVERSE,
+ blink = A_BLINK,
+ dim = A_DIM,
+ bold = A_BOLD,
+ altcharset = A_ALTCHARSET,
+ invis = A_INVIS,
+ protect = A_PROTECT,
+ italic = A_ITALIC,
+ // WA attributes for only attr_on, attr_off and attr_set
+ horizontal = A_HORIZONTAL,
+ left = A_LEFT,
+ low = A_LOW,
+ right = A_RIGHT,
+ top = A_TOP,
+ vertical = A_VERTICAL,
+};
+
+template <> struct is_bitmask<attr> : public std::true_type {};
+
+using attr_flags = flags<attr>;
+
+} // namespace NCURSES_CPP_NAMESPACE
+
+#endif // INCLUDE_NCURSES_CHAR_ATTRIBUTES_HPP_