diff options
| author | ProsperousPotato <ProsperousPotato@users.noreply.github.com> | 2025-12-10 18:47:53 +0000 |
|---|---|---|
| committer | ProsperousPotato <ProsperousPotato@users.noreply.github.com> | 2025-12-10 18:47:53 +0000 |
| commit | 57e07138a53149443263ff6a792909d94214cef4 (patch) | |
| tree | 28fb04aefce8e257e5e1717cecd61bb4e1a490b2 /patches/disable_bold.diff | |
| parent | 8c4519141a7a2631c72ffc7bb611bcd3db9749b4 (diff) | |
update st config
Diffstat (limited to 'patches/disable_bold.diff')
| -rwxr-xr-x | patches/disable_bold.diff | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/patches/disable_bold.diff b/patches/disable_bold.diff deleted file mode 100755 index 385f1b4..0000000 --- a/patches/disable_bold.diff +++ /dev/null @@ -1,70 +0,0 @@ -From 0856fbfcdae3f8e48db791984591b0bb8a91de68 Mon Sep 17 00:00:00 2001 -From: Ryan Kes <alrayyes@gmail.com> -Date: Fri, 29 Mar 2019 10:59:09 +0100 -Subject: [PATCH] st-disable-bold-italic-fonts-0.8.2 - ---- - config.def.h | 6 ++++++ - x.c | 10 +++++++++- - 2 files changed, 15 insertions(+), 1 deletion(-) - -diff --git a/config.def.h b/config.def.h -index 482901e..4f5aeac 100644 ---- a/config.def.h -+++ b/config.def.h -@@ -6,6 +6,12 @@ - * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html - */ - static char *font = "Liberation Mono:pixelsize=12:antialias=true:autohint=true"; -+ -+/* disable bold, italic and roman fonts globally */ -+int disablebold = 0; -+int disableitalic = 0; -+int disableroman = 0; -+ - static int borderpx = 2; - - /* -diff --git a/x.c b/x.c -index 5828a3b..9663fa6 100644 ---- a/x.c -+++ b/x.c -@@ -233,6 +233,11 @@ static char *usedfont = NULL; - static double usedfontsize = 0; - static double defaultfontsize = 0; - -+/* declared in config.h */ -+extern int disablebold; -+extern int disableitalic; -+extern int disableroman; -+ - static char *opt_class = NULL; - static char **opt_cmd = NULL; - static char *opt_embed = NULL; -@@ -966,17 +971,20 @@ xloadfonts(char *fontstr, double fontsize) - win.ch = ceilf(dc.font.height * chscale); - - FcPatternDel(pattern, FC_SLANT); -- FcPatternAddInteger(pattern, FC_SLANT, FC_SLANT_ITALIC); -+ if (!disableitalic) -+ FcPatternAddInteger(pattern, FC_SLANT, FC_SLANT_ITALIC); - if (xloadfont(&dc.ifont, pattern)) - die("can't open font %s\n", fontstr); - - FcPatternDel(pattern, FC_WEIGHT); -- FcPatternAddInteger(pattern, FC_WEIGHT, FC_WEIGHT_BOLD); -+ if (!disablebold) -+ FcPatternAddInteger(pattern, FC_WEIGHT, FC_WEIGHT_BOLD); - if (xloadfont(&dc.ibfont, pattern)) - die("can't open font %s\n", fontstr); - - FcPatternDel(pattern, FC_SLANT); -- FcPatternAddInteger(pattern, FC_SLANT, FC_SLANT_ROMAN); -+ if (!disableroman) -+ FcPatternAddInteger(pattern, FC_SLANT, FC_SLANT_ROMAN); - if (xloadfont(&dc.bfont, pattern)) - die("can't open font %s\n", fontstr); - --- -2.39.2 - |
