From 93c4e8ebf3dea5c9e1978f78a33cb961d6a1aaf7 Mon Sep 17 00:00:00 2001 From: Grigori Goronzy Date: Fri, 19 Aug 2011 01:16:24 +0200 Subject: Use TrueType font weight scale fontconfig uses an unusual scale from 0-215 for the font weight. It looks like it is somewhat derived from the typographic scale some font families use, but is still rather nonstandard. Nowadays the TrueType scale from 100-900 seems to be standard. CSS uses it, for example. However, most importantly, VSFilter also uses the TrueType scale. So let's use it in libass, too. --- libass/ass_fontselect.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libass/ass_fontselect.h') diff --git a/libass/ass_fontselect.h b/libass/ass_fontselect.h index 651968d..05359a8 100644 --- a/libass/ass_fontselect.h +++ b/libass/ass_fontselect.h @@ -49,6 +49,10 @@ typedef struct font_provider_funcs { DestroyProviderFunc destroy_provider; } ASS_FontProviderFuncs; +#define FONT_WEIGHT_LIGHT 300 +#define FONT_WEIGHT_MEDIUM 400 +#define FONT_WEIGHT_BOLD 700 + typedef struct font_provider_meta_data { char *family; char **fullnames; -- cgit v1.2.3