summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorSibi Prabakaran <sibi@psibi.in>2020-08-08 22:21:40 +0530
committerSibi Prabakaran <sibi@psibi.in>2020-08-09 13:09:51 +0530
commit78efa5900a8670450139cfce52f30d6670ba1e09 (patch)
treee1783c3abdea50be4c96161bfc4fd96ad2fe1746
parent8e2c3adf49c2157789d840d34cec10efdd7eba4f (diff)
downloadxmobar-78efa5900a8670450139cfce52f30d6670ba1e09.tar.gz
xmobar-78efa5900a8670450139cfce52f30d6670ba1e09.tar.bz2
Avoid double utf8 encoding
With this change, xmobar should respect the data which it gets. Xmobar should just render the data instead of trying to encode it.
-rw-r--r--src/Xmobar/X11/MinXft.hsc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Xmobar/X11/MinXft.hsc b/src/Xmobar/X11/MinXft.hsc
index e593da0..acc60b2 100644
--- a/src/Xmobar/X11/MinXft.hsc
+++ b/src/Xmobar/X11/MinXft.hsc
@@ -164,7 +164,7 @@ foreign import ccall "XftDrawStringUtf8"
drawXftString :: (Integral a1, Integral a) =>
AXftDraw -> AXftColor -> AXftFont -> a -> a1 -> String -> IO ()
drawXftString d c f x y string =
- withArrayLen (map fi (UTF8.encode string))
+ withArrayLen (map (fi . ord) string)
(\len ptr -> cXftDrawStringUtf8 d c f (fi x) (fi y) ptr (fi len))
drawXftString' :: AXftDraw ->