50 virtual uint32_t
hash()
const = 0;
107 bool italic)
const = 0;
#define UExport
Definition Defines.h:65
Represents a font file, either on-disk path or in-memory file contents.
Definition FontLoader.h:18
FontFile(const FontFile &)
virtual RefPtr< Buffer > buffer() const =0
The in-memory buffer (if any).
static RefPtr< FontFile > Create(const String &filepath)
Create a font file from an on-disk file path.
virtual bool is_in_memory() const =0
Whether or not this font file was created from an in-memory buffer.
void operator=(const FontFile &)
virtual uint32_t hash() const =0
Unique hash (if this is a filepath, only the path string is hashed).
virtual String filepath() const =0
The file path (if any).
static RefPtr< FontFile > Create(RefPtr< Buffer > buffer)
Create a font file from an in-memory buffer.
User-defined font loader interface.
Definition FontLoader.h:82
virtual String fallback_font_for_characters(const String &characters, int weight, bool italic) const =0
Fallback font family name that can render the specified characters.
virtual RefPtr< FontFile > Load(const String &family, int weight, bool italic)=0
Get the actual font file data (TTF/OTF) for a given font description.
virtual String fallback_font() const =0
Fallback font family name.
Interface for all ref-counted objects that will be managed using the RefPtr<> smart pointer.
Definition RefPtr.h:47
A nullable smart pointer.
Definition RefPtr.h:79
UTF-8 String container with conversions for UTF-16 and UTF-32.
Definition String.h:21