summaryrefslogtreecommitdiff
path: root/lib/Graphics/Fountainhead/Type.hs
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Graphics/Fountainhead/Type.hs')
-rw-r--r--lib/Graphics/Fountainhead/Type.hs5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/Graphics/Fountainhead/Type.hs b/lib/Graphics/Fountainhead/Type.hs
index e809d9c..beaf6e4 100644
--- a/lib/Graphics/Fountainhead/Type.hs
+++ b/lib/Graphics/Fountainhead/Type.hs
@@ -9,10 +9,12 @@ module Graphics.Fountainhead.Type
, FWord
, UFWord
, fixed2Double
+ , newlineBuilder
, succIntegral
, ttfEpoch
) where
+import qualified Data.Text.Lazy.Builder as Text.Builder
import Data.Bits ((.>>.), (.&.))
import Data.Int (Int16)
import Data.Word (Word16, Word32)
@@ -39,3 +41,6 @@ fixed2Double (F2Dot14 fixed) =
let mantissa = realToFrac (fixed .>>. 14)
fraction = realToFrac (fixed .&. 0x3fff) / 16384.0
in mantissa + fraction
+
+newlineBuilder :: Text.Builder.Builder
+newlineBuilder = Text.Builder.singleton '\n'