Skip to content

Instantly share code, notes, and snippets.

@hackerb9
Created June 5, 2017 11:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hackerb9/431a96f033cf16eefc39fbf9b6448bde to your computer and use it in GitHub Desktop.
Save hackerb9/431a96f033cf16eefc39fbf9b6448bde to your computer and use it in GitHub Desktop.
How to kludge neep font to pretend to have italics
# Neep is the loveliest bitmap terminal font I've found so far with good Unicode coverage.
# Unfortunately, neep has no italics.
#
# As a quick workaround, one can use the terminus-oblique font as a replacement by using X fonts.alias.
sudo apt-get install xfonts-jmk xfonts-terminus-oblique
echo "-jmk-neep-medium-o-normal--20-180-75-75-c-100-iso10646-1 -xos4-terminus-bold-o-normal--20-200-72-72-c-100-iso10646-1" > local.alias
echo "-jmk-neep-medium-o-normal--15-140-75-75-c-80-iso10646-1 -xos4-terminus-bold-o-normal--14-140-72-72-c-80-iso10646-1" >> local.alias
sudo cp -i local.alias /etc/X11/fonts/misc/local.alias \
&& sudo update-fonts-alias misc \
&& xset fp rehash
xterm -fn *neep-medium-r-normal--20-*10646*
# Within xterm, you can test italics using 'tput sitm' and 'tput ritm'
tput sitm
echo "This is in italic!"
tput ritm
echo "This is not italic."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment