pulsatrix 1.1.0
Loading...
Searching...
No Matches
fonts.hpp
Go to the documentation of this file.
1
6#pragma once
7
8#include <string>
9#include <vector>
10
11namespace pulsatrix {
12
15 std::string path;
16 int index = 0;
17};
18
22 std::vector<VizFontFile> fonts;
24 bool system_fallbacks = true;
26 float size = 13.0f;
27};
28
43[[nodiscard]] std::vector<VizFontFile> FindFallbackFonts();
44
51
58std::vector<VizFontFile> LoadVizFonts(const VizFontOptions& options);
59
61[[nodiscard]] bool VizFontsUseFreeType();
62
63} // namespace pulsatrix
Definition acquisition_functions.hpp:16
std::vector< VizFontFile > LoadVizFonts(const VizFontOptions &options)
Loads ImGui's default font and merges options' fonts into it, in the current ImGui context....
bool VizFontsUseFreeType()
Whether this build's ImGui uses FreeType (color emoji) rather than stb_truetype.
std::vector< VizFontFile > FindFallbackFonts()
The system fonts that together cover as many scripts as this machine has fonts for,...
VizFontOptions DefaultVizFontOptions()
The font options a VizWindow uses when given none. With the environment variable PULSATRIX_VIZ_FONTS ...
A font file, and the face to use when it holds several (.ttc).
Definition fonts.hpp:14
int index
Definition fonts.hpp:16
std::string path
Definition fonts.hpp:15
Which fonts a VizWindow loads.
Definition fonts.hpp:20
std::vector< VizFontFile > fonts
Fonts merged after ImGui's default font, in priority order.
Definition fonts.hpp:22
bool system_fallbacks
Also merge the system fonts FindFallbackFonts() finds, after fonts.
Definition fonts.hpp:24
float size
Font size in pixels (ImGui's default font is 13).
Definition fonts.hpp:26