mirror of
https://github.com/LukeSmithxyz/st.git
synced 2024-11-22 15:25:58 +01:00
Adding mor explict font patterns.
This commit is contained in:
parent
eeffbe11ab
commit
05a1ff03e9
1 changed files with 3 additions and 0 deletions
3
st.c
3
st.c
|
@ -2440,7 +2440,9 @@ xloadfonts(char *fontstr, int fontsize) {
|
||||||
xw.cw = dc.font.width;
|
xw.cw = dc.font.width;
|
||||||
xw.ch = dc.font.height;
|
xw.ch = dc.font.height;
|
||||||
|
|
||||||
|
FcPatternDel(pattern, FC_SLANT);
|
||||||
FcPatternDel(pattern, FC_WEIGHT);
|
FcPatternDel(pattern, FC_WEIGHT);
|
||||||
|
FcPatternAddInteger(pattern, FC_SLANT, FC_SLANT_ROMAN);
|
||||||
FcPatternAddInteger(pattern, FC_WEIGHT, FC_WEIGHT_BOLD);
|
FcPatternAddInteger(pattern, FC_WEIGHT, FC_WEIGHT_BOLD);
|
||||||
if(xloadfont(&dc.bfont, pattern))
|
if(xloadfont(&dc.bfont, pattern))
|
||||||
die("st: can't open font %s\n", fontstr);
|
die("st: can't open font %s\n", fontstr);
|
||||||
|
@ -2451,6 +2453,7 @@ xloadfonts(char *fontstr, int fontsize) {
|
||||||
die("st: can't open font %s\n", fontstr);
|
die("st: can't open font %s\n", fontstr);
|
||||||
|
|
||||||
FcPatternDel(pattern, FC_WEIGHT);
|
FcPatternDel(pattern, FC_WEIGHT);
|
||||||
|
FcPatternAddInteger(pattern, FC_WEIGHT, FC_WEIGHT_MEDIUM);
|
||||||
if(xloadfont(&dc.ifont, pattern))
|
if(xloadfont(&dc.ifont, pattern))
|
||||||
die("st: can't open font %s\n", fontstr);
|
die("st: can't open font %s\n", fontstr);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue