X-Git-Url: http://git.xonotic.org/?p=xonotic%2Fdarkplaces.git;a=blobdiff_plain;f=draw.h;h=5e023da8ad617ed7ac22bdf9de497127a4ceef21;hp=381dd35ebadc63e4da6d2b2d60237eab4ac2643a;hb=HEAD;hpb=e9ef9da90a206204b283dacd15c35bd3fd1fe5c9 diff --git a/draw.h b/draw.h index 381dd35e..8496bb73 100644 --- a/draw.h +++ b/draw.h @@ -1,5 +1,6 @@ /* Copyright (C) 1996-1997 Id Software, Inc. +Copyright (C) 2000-2021 DarkPlaces contributors This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -92,10 +93,12 @@ typedef struct ft2_settings_s #define MAX_FONT_SIZES 16 #define MAX_FONT_FALLBACKS 3 +#define MAX_FONT_CMDLINE MAX_QPATH * (MAX_FONT_FALLBACKS + 1) typedef struct dp_font_s { cachepic_t *pic; float width_of[256]; // width_of[0] == max width of any char; 1.0f is base width (1/16 of texture width); therefore, all widths have to be <= 1 (does not include scale) + float width_of_ft2[MAX_FONT_SIZES][256]; float maxwidth; // precalculated max width of the font (includes scale) char texpath[MAX_QPATH]; char title[MAX_QPATH]; @@ -107,6 +110,8 @@ typedef struct dp_font_s struct ft2_font_s *ft2; ft2_settings_t settings; + + char cmdline[MAX_FONT_CMDLINE]; } dp_font_t;