8#if (defined(_MSVC_LANG) ? _MSVC_LANG : __cplusplus) < 201703L
10 "OpenPine C++ wrapper headers require C++17 (std::optional, std::string_view)."
29 const ffi::BackgroundColors* p_;
37 int32_t
offset()
const {
return ffi::bgcolorsOffset(p_); }
42 bool editable()
const {
return ffi::bgcolorsEditable(p_); }
49 if (ffi::bgcolorsShowLast(p_, &v)) {
60 std::optional<std::string_view>
title()
const {
61 ffi::PineStringRef ref;
62 if (ffi::bgcolorsTitle(p_, &ref)) {
77 bool forceOverlay()
const {
return ffi::bgcolorsForceOverlay(p_); }
85 std::optional<uint32_t>
color(uintptr_t idx)
const {
87 if (ffi::bgcolorsColor(p_, idx, &col)) {
A type-safe display bitmask.
int32_t offset() const
Returns the background-colors offset.
bool forceOverlay() const
Gets whether the background colors are forced to render as overlay.
BackgroundColors(const ffi::BackgroundColors *p)
std::optional< std::string_view > title() const
Gets the title of the background-colors series.
std::optional< uintptr_t > showLast() const
Gets the show_last value, if set.
bool editable() const
Returns whether background-colors are editable.
std::optional< uint32_t > color(uintptr_t idx) const
Gets the background color at the specified index.
Display display() const
Gets the display bitmask.
Type-safe wrappers for display bitmasks used by visuals.
std::string_view refToView(const ffi::PineStringRef &ref)
Shared helpers for converting C ABI string refs to std::string_view.