Use unicode characters for Xmonad workspaces

Viewed 1744

I want to use Unicode characters from the Nerd Fonts for my workspaces in Xmonad.

myWorkspaces = ["1:", "2:", "3:", "4:", "5:", "6:ﱘ", "7:", "8:", "9:"]

For reference:

Array of workspace Unicode names

However, I get the following error on compilation:

xmonad.hs:191:13: error:
    lexical error in string/character literal at character '\62057'
    |
191 |         ["1:", "2:", "3:", "4:", "5:", "6:ﱘ", "7:", "8:", "9:"]
    |             ^

Please check the file for errors.

Warning: Missing charsets in String to FontSet conversion 

Is there any chance to use a full set of nerd fonts unicode characters? I have seen that others use a subset of unicode in their config.

1 Answers

I think you're running into GHC bug #5518. As a workaround, try the escape syntax instead (e.g., "1:\62057" or "1:\xf269" instead of "1:").

Related