28#include <Objectively/Enum.h>
29#include <Objectively/Array.h>
30#include <Objectively/Data.h>
34#define DEFAULT_FONT_FAMILY "Coda"
35#define DEFAULT_FONT_SIZE 16
36#define DEFAULT_FONT_STYLE FontStyleRegular
57typedef struct FontInterface FontInterface;
110struct FontInterface {
115 ObjectInterface objectInterface;
127 Font *(*cachedFont)(
const char *family,
int size,
int style);
152 Font *(*defaultFont)(void);
165 Font *(*initWithData)(
Font *self, Data *data,
const char *family,
int size,
int style);
177 SDL_Surface *(*renderCharacters)(
const Font *self,
const char *chars, SDL_Color color,
int wrapWidth);
static void sizeCharacters(const Font *self, const char *chars, int *w, int *h)
static void clearCache(void)
static void renderDeviceDidReset(Font *self)
static void cacheFont(Data *data, const char *family)
OBJECTIVELYMVC_EXPORT const EnumName FontStyleNames[]
static SDL_Size size(const Image *self)
ObjectivelyMVC base types.
#define OBJECTIVELYMVC_EXPORT
FontInterface * interface
The interface.
ident font
The backing font.
int renderSize
The render size, adjusted for display density.
char * family
The family name.
Class * _Font(void)
The Font archetype.
Data * data
The raw font data.
Object object
The superclass.