Ligatures and Emoji in the Suckless Simple Terminal

[linkstandalone]



I decided to finally mess around with the Suckless Simple Terminal ST, and add the latest work from luke smith to get color emoji support in ST. I forked Luke's repo, then installed the necessary dependency libxft-bgra for the emoji's and we were off to the races.


Next I sudo make install so I had the latest build of ST from Luke with the emoji support and then I made a branch on the repo to test out the ligatures before committing to the change. Next I manually did the patch as there was a diff made for the patch but knowing how much stuff Luke put into his build of ST I didn't want to deal with the headache of dealing with merge conflicts so I just manually added the code to the repo. I also had to install a new C library called harfbuzz and add that in.


With all these items added I ran sudo make install again and tested out the feature and lo and behold.... I didn't have ligatures.... WTH... So I remembered that I was using Inconsolata for my font and I needed a font with ligature support. This turned out to be FiraCode But I didn't like the serifs on FiraCode so what I did was install JetBrainsMono-Regular as my font of choice and I couldn't be happier with the result. So to finish it off I ran sudo make install one more time, tested, aaaaaand we have ligatures. I have ligatures in Vim too because Vim is in the terminal, and now that I have the font in as well and figured out installing fonts onto Linux, I now also have ligatures in VSCode and RStudio. It was a journey, but I'm happy with this new build of ST and with my manually added in patch for ligatures I decided to have my own repo put up Here.


Ultimately I think I will end up learning C and/or C++ for writing terminal things, for faster functions in R and just the new dimension of programming, when I do I'll probably look at ST's code for learning and so it will help me learn how to modify my terminal more.


This topic was covered in This YouTube Video.


Return To Blog Page