Re-enable runtime font rendering if a font handler is assigned, clean up some font handler things.

This commit is contained in:
elasota
2021-04-15 19:32:15 -04:00
parent c49bab04d5
commit 4e8e76f8fc
15 changed files with 103 additions and 140 deletions

View File

@@ -2,6 +2,7 @@
#include "FontHacks.h"
#include "FontFamilyID.h"
#include "FontPresets.h"
struct IGpFont;
@@ -10,34 +11,6 @@ namespace PortabilityLayer
class FontFamily;
class RenderedFont;
namespace FontPresets
{
enum FontPreset
{
kSystem12,
kSystem12Bold,
kApplication8,
kApplication9,
kApplication9Bold,
kApplication10Bold,
kApplication12Bold,
kApplication14,
kApplication14Bold,
kApplication18,
kApplication40,
kMono10,
kHandwriting24,
kHandwriting48,
kCount,
};
}
typedef FontPresets::FontPreset FontPreset_t;
class FontManager
{
public:
@@ -47,8 +20,6 @@ namespace PortabilityLayer
virtual FontFamily *GetFont(FontFamilyID_t fontFamilyID) const = 0;
virtual void GetFontPreset(FontPreset_t fontPreset, FontFamilyID_t *outFamilyID, int *outSize, int *outVariationFlags, bool *outAA) const = 0;
virtual RenderedFont *GetRenderedFontFromFamily(FontFamily *fontFamily, int fontSize, bool aa, int flags) = 0;
virtual RenderedFont *LoadCachedRenderedFont(FontFamilyID_t familyID, int size, bool aa, int flags) = 0;
virtual void PurgeCache() = 0;