Donner SVG main
0.8.0 ยท 382bd0190.8.0 main
SVG editor and embeddable C⁠+⁠+⁠20 engine.
Loading...
Searching...
No Matches
FontManager.h File Reference
#include <cstddef>
#include <cstdint>
#include <memory>
#include <optional>
#include <span>
#include <string>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#include "donner/base/EcsRegistry.h"
#include "donner/base/fonts/SfntUtils.h"
#include "donner/css/FontFace.h"
#include "donner/svg/resources/FontCatalogTypes.h"
Include dependency graph for FontManager.h:
This graph shows which files directly or indirectly include this file:

Classes

struct  donner::svg::FontDataRenderingOptions
 Owned rendering attributes for a provider face reloaded from encoded bytes. More...
struct  donner::svg::FontLoadingDomainIdentity
 Non-owning identity of an installed font-loading domain. More...
class  donner::svg::FontHandle
 Opaque handle to a loaded font, used to reference fonts in the FontManager. More...
struct  std::hash< donner::svg::FontHandle >
 std::hash specialization so donner::svg::FontHandle can be used as a key in unordered associative containers. More...
class  donner::svg::FontManager
 Manages font loading, caching, and lookup for text rendering. More...
struct  donner::svg::FontManager::GlyphOutlineComplexity
 Validation-time allocation/work bound for one font outline. More...
class  donner::svg::FontManager::DependencyCapture
 Record every catalog face consulted in a layout, including memoized and pending faces. The output survives this manager and can be attached to a stable preview/document task. More...

Namespaces

namespace  donner
 Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css.
namespace  donner::svg
 Donner SVG library, which can load, manipulate and render SVG files.

Enumerations

enum class  donner::svg::FontDataTrust {
  donner::svg::Untrusted ,
  donner::svg::Trusted
}
 Declares whether font bytes come from a trusted local source. More...

Class Documentation

◆ donner::svg::FontDataRenderingOptions

struct donner::svg::FontDataRenderingOptions

Owned rendering attributes for a provider face reloaded from encoded bytes.

These values configure the new face before a backend can cache it. They do not name or query a provider, and do not associate the face with a CSS family.

Class Members
bool genericSans = false The source face belongs to the generic sans-serif provider.
bool immutableCatalog = false The source face belongs to an immutable font catalog.
optional< FontFaceRequest > providerRequest Requested weight, style and stretch.

◆ donner::svg::FontLoadingDomainIdentity

struct donner::svg::FontLoadingDomainIdentity

Non-owning identity of an installed font-loading domain.

Compare owner control blocks, including after expiration. The allowance conservatively accounts for the fixed coallocation kept alive by a weak reference, not live font data or physical RSS.

Class Members
weak_ptr< const void > owner Does not retain the source or its resources.
size_t retainedStorageBytes = 0 Conservative fixed weak-identity storage allowance.

◆ donner::svg::FontManager::GlyphOutlineComplexity

struct donner::svg::FontManager::GlyphOutlineComplexity

Validation-time allocation/work bound for one font outline.

Class Members
size_t maximumVertices = 0
size_t work = 0