NoTeX
1.0.0
A modern noteworthy LaTeX template
Toggle main menu visibility
Loading...
Searching...
No Matches
notex
include
notex
output.hpp
Go to the documentation of this file.
1
11
12
#pragma once
13
14
#include <optional>
15
#include <string_view>
16
17
namespace
notex::ui
{
18
28
void
set_assume_yes
(
bool
assume_yes
);
29
31
bool
assume_yes
();
32
34
void
success
(std::string_view message);
35
38
void
warning
(std::string_view message);
39
41
void
error
(std::string_view message);
42
44
void
step
(std::string_view message);
45
47
void
info
(std::string_view message);
48
64
bool
confirm
(std::string_view prompt,
bool
default_answer =
false
);
65
82
void
set_stdin_interactive_override_for_testing
(
83
std::optional<bool> is_interactive);
84
85
}
// namespace notex::ui
notex::ui
Definition
output.hpp:17
notex::ui::set_stdin_interactive_override_for_testing
void set_stdin_interactive_override_for_testing(std::optional< bool > is_interactive)
Testing seam: overrides whether confirm() treats standard input as an interactive terminal.
Definition
output.cpp:45
notex::ui::assume_yes
bool assume_yes()
Definition
output.cpp:43
notex::ui::error
void error(std::string_view message)
Prints an error message, prefixed with a red cross, to stderr.
Definition
output.cpp:58
notex::ui::info
void info(std::string_view message)
Prints a plain informational message to stdout.
Definition
output.cpp:66
notex::ui::success
void success(std::string_view message)
Prints a success message, prefixed with a green checkmark, to stdout.
Definition
output.cpp:50
notex::ui::warning
void warning(std::string_view message)
Definition
output.cpp:54
notex::ui::set_assume_yes
void set_assume_yes(bool assume_yes)
Sets whether confirm() should answer "yes" without prompting.
Definition
output.cpp:41
notex::ui::step
void step(std::string_view message)
Prints a step or progress message, prefixed with an arrow, to stdout.
Definition
output.cpp:62
notex::ui::confirm
bool confirm(std::string_view prompt, bool default_answer=false)
Asks the user to confirm an action.
Definition
output.cpp:68
Generated by
1.17.0