speedie 2022-12-06 20:25:25 +01:00
parent 3c68c3efa9
commit b0724cd949
3 changed files with 4 additions and 1 deletions

View file

@ -38,6 +38,7 @@ static float cxoffset = 0;
static float cyoffset = 0;
/* Text drawing options */
static int badweight = 0; /* Enable badweight detection? This can break certain fonts which is why it's disabled by default. */
static int brightbold = 0; /* Should bright text also be bold? */
static unsigned int cols = 80; /* Number of columns */
static unsigned int rows = 24; /* Number of rows */

3
x.c
View file

@ -1045,7 +1045,8 @@ xloadfont(Font *f, FcPattern *pattern)
XftResultMatch)) {
if ((XftPatternGetInteger(f->match->pattern, "weight", 0,
&haveattr) != XftResultMatch) || haveattr != wantattr) {
f->badweight = 1;
if (badweight)
f->badweight = 1;
fputs("font weight does not match\n", stderr);
}
}

View file

@ -42,6 +42,7 @@ ResourcePref resources[] = {
{ "defaultcs", INTEGER, &defaultcs },
{ "defaultrc", INTEGER, &defaultrc },
{ "cursorstyle", INTEGER, &cursorstyle },
{ "badweight", INTEGER, &badweight },
{ "brightbold", INTEGER, &brightbold },
{ "alpha", FLOAT, &alpha },
{ "gradalpha", FLOAT, &gradalpha },