Safe Haskell | None |
---|---|
Language | Haskell2010 |
pcf-font-embed allows users to render and embed text with X11 PCF fonts at compile-time. Perhaps the best use-case for this library is in generating textures for text rendering with accelerated graphics. For reference, here is a simple example of pcf-font-embed in action:
{-# LANGUAGE TemplateHaskell #-} import Graphics.Text.PCF import Graphics.Text.PCF.Embed -- | USAGE: program main :: IO () main = putStrLn $ pcf_text_ascii $(embedPCFText "font.pcf.gz" "Hello!")
- embedPCFText :: FilePath -> String -> Q Exp