CPGen
C++ project generator
Loading...
Searching...
No Matches
Functions
System Namespace Reference

Utilities that query or interact with the host operating system. More...

Functions

bool isFontValid ()
 Interactively check whether the terminal font supports Nerd Font glyphs.
 

Detailed Description

Utilities that query or interact with the host operating system.

Function Documentation

◆ isFontValid()

bool System::isFontValid ( )

Interactively check whether the terminal font supports Nerd Font glyphs.

Renders a pair of checkbox glyphs to stdout and prompts the user to confirm whether they render correctly. This is used at startup to decide whether the TUI should use Unicode icons or fall back to plain ASCII.

Returns
true if the user confirmed the glyphs look correct (y / Y), false otherwise.
Note
This function reads from std::cin and is therefore not testable without stdin redirection.