Closed mschilli87 closed 8 years ago
spectrwm 1.0.0 doesn't handle quotes or escaped spaces when parsing spawn command arguments. Spawn parsing was improved in 2.4.0. Your terminal spawn command should work in the current release (3.0.2):
program[terminal] = stterm -f "Anonymice Powerline:style=Regular:pixelsize=14:antialias=true"
bind[terminal] = MOD+Shift+Return
Thanks for the fast reply.
As spectrwm 2.4.0
is not available in Ubuntu 14.04, I hacked around this issue by masking the offending space:
sudo ln -s /usr/share/fonts/powerline/Anonymice\ Powerline.ttf /usr/share/fonts/powerline/AnonymicePowerline.ttf
This allowed me to use the following configuration:
program[terminal] = AnonymicePowerline:style=Regular:pixelsize=14:antialias=true
bind[terminal] = MOD+Shift+Return
Now everything works as expected.
I use
spectrwm
in Ubuntu 14.04 & Gentoo in combinations with the suckless terminalst
(stterm
in Ubuntu).To change the font settings for
stterm
post-compilation, I use the command line flag-f
:I configured this for
spectrwm
as follows:This worked fine for years.
Now I made some changes to my
vim
settings including setting up a more fancy status bar that required me to use one of the patched powerline fonts.First I tried to get it work manually and it turned out
did the trick: I got a terminal window in which could open
vim
to see the nice new status bar.I adjusted my
spectrwm.conf
accordingly:However, opening a terminal from
spectrwm
now results in some really ugly default font.I can reproduce the same effect by running
Surprisingly, if I copy/paste the command from my
spectrwm.conf
to the (ugly font) terminal opened byspectrwm
using the very same command, it opens another terminal window that has the desired font.So somehow,
spectrwm
doesn't seem to find the font while myzsh
running in thestterm
does.I thought this might be due to the patched fonts install script installing the font for my user only (to
~/.local/share/fonts
) whichspectrwm
might not check. So I created a directorypowerline
in/usr/share/fonts
& moved the fonts there byI ran
fc-cache
to be sure andfc-list | grep "Anonymice Powerline"
returns the following entries:As it used to work with the
FreeMono
font but fails with theAnonymice Powerline
font and only fromspectrwm
I suspect a problem with how to escape the space in the font name.I tried to escape with single quotes:
And I tried to escape by backslash:
In both cases I get the ugly default font when launching the terminal from
spectrwm
even though both,and
have the desired effect for the 2nd terminal when I copy/paste them into the 1st terminal (the one with the ugly fonts that was openend by
spectrwm
).As of now the best 'solution' seems to be to
alias
in my
.zshrc
so I can quickly replace a window opened byspectrwm
by one that uses the proper font.Do you have any idea what I am doing wrong?
This was done on my Ubuntu machine were I have
spectrwm 1.0.0-1
installed.