Add documentations to every public functions.

This commit is contained in:
ArthurSonzogni
2023-08-19 14:56:28 +02:00
parent 5724f8483b
commit 49a48820dd
32 changed files with 396 additions and 48 deletions

View File

@@ -87,6 +87,10 @@ Terminal::Color ComputeColorSupport() {
} // namespace
namespace Terminal {
/// @brief Get the terminal size.
/// @return The terminal size.
/// @ingroup screen
Dimensions Size() {
#if defined(__EMSCRIPTEN__)
// This dimension was chosen arbitrarily to be able to display:
@@ -121,6 +125,8 @@ void SetFallbackSize(const Dimensions& fallbackSize) {
FallbackSize() = fallbackSize;
}
/// @brief Get the color support of the terminal.
/// @ingroup screen
Color ColorSupport() {
if (!g_cached) {
g_cached = true;
@@ -129,6 +135,8 @@ Color ColorSupport() {
return g_cached_supported_color;
}
/// @brief Override terminal color support in case auto-detection fails
/// @ingroup dom
void SetColorSupport(Color color) {
g_cached = true;
g_cached_supported_color = color;