aboutsummaryrefslogtreecommitdiff
path: root/source/30-game/FontManager.hpp
blob: ef87f0cbe5787df85dc61eb87cd5153ae1806d17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#pragma once

#include "Font.hpp"
#include "RcPtr.hpp"

class FontManager {
public:
	// Pointers are valid staring from program entry, but object will not be initialized until FontManager::Init() is called.
	static RcPtr<Font> sans;
	static RcPtr<Font> serif;
	static RcPtr<Font> monospace;

public:
	static const RcPtr<Font>& GetDefaultFont();

	static const Font* ResolveFallback(const Font* font);
	static const RcPtr<Font>& ResolveFallback(const RcPtr<Font>& font);

	static void Init();
	static void Shutdown();
};