73[[nodiscard]] std::expected<HexRowResult, HexError>
formatHexRow(std::span<const std::byte> input,
76 std::span<HexByteCell> cells)
noexcept;
Public Portals API.
Definition action.hpp:8
std::expected< HexRowResult, HexError > formatHexRow(std::span< const std::byte > input, std::uint64_t absoluteOffset, HexRowOptions options, std::span< char > text, std::span< HexByteCell > cells) noexcept
ui::ValueText text(std::format_string< const ui::detail::TextArgumentValue< Args > &... > pattern, Args &&...args)
Declare live formatted text over explicit scalar roots, fields or value properties.
Definition ui_value_text.hpp:567
constexpr std::size_t MAX_HEX_ROW_BYTES
Definition document_hex.hpp:14
std::expected< std::size_t, HexError > hexRowWidth(HexRowOptions options) noexcept
@ INVALID_OPTIONS
Runner options are invalid, or a native run was requested with an injected clock.
Definition application.hpp:31
HexError
Definition document_hex.hpp:26
@ OFFSET_OVERFLOW
The offset after consumed input cannot fit in uint64_t.
Definition document_hex.hpp:28
@ TEXT_TOO_SMALL
The text output cannot hold a complete row.
Definition document_hex.hpp:29
@ CELLS_TOO_SMALL
The cell output cannot hold all consumed bytes.
Definition document_hex.hpp:30
HexByteClass
Definition document_hex.hpp:17
@ ZERO
Zero byte.
Definition document_hex.hpp:18
@ SPACE
ASCII space.
Definition document_hex.hpp:19
@ PRINTABLE
ASCII graphic character.
Definition document_hex.hpp:20
@ CONTROL
Nonzero ASCII control byte, including DEL.
Definition document_hex.hpp:21
@ HIGH_BYTE
Byte at or above 0x80.
Definition document_hex.hpp:22
Definition document_hex.hpp:42
std::uint64_t byteOffset
Absolute source byte offset.
Definition document_hex.hpp:43
HexByteClass byteClass
Semantic class for presentation.
Definition document_hex.hpp:46
std::size_t hexColumn
Zero-based column of the first hex digit.
Definition document_hex.hpp:44
std::optional< std::size_t > asciiColumn
Zero-based ASCII column, absent when disabled.
Definition document_hex.hpp:45
Definition document_hex.hpp:34
bool showAscii
Append a safe ASCII column when true.
Definition document_hex.hpp:38
std::size_t groupSize
Slots per group, from 1 through MAX_HEX_ROW_BYTES.
Definition document_hex.hpp:36
bool uppercase
Use uppercase hexadecimal digits when true.
Definition document_hex.hpp:37
std::size_t bytesPerRow
Number of byte slots, from 1 through MAX_HEX_ROW_BYTES.
Definition document_hex.hpp:35
Definition document_hex.hpp:50
std::size_t bytesConsumed
Number of input bytes represented.
Definition document_hex.hpp:51
std::size_t columns
Number of characters written, without a terminator.
Definition document_hex.hpp:52