~alcinnz/harfbuzz-pure

80b4e9841099ed917abba3d045dcf69e3ee227b2 — Adrian Cochrane 1 year, 8 months ago cd5a7d0
Attempt fix regarding fontscale bitsizes.
1 files changed, 4 insertions(+), 4 deletions(-)

M Data/Text/Glyphize/Font.hs
M Data/Text/Glyphize/Font.hs => Data/Text/Glyphize/Font.hs +4 -4
@@ 660,11 660,11 @@ fontScale :: Font -> (Int, Int)
fontScale font = unsafePerformIO $
    withForeignPtr font $ \font' -> alloca $ \x' -> alloca $ \y' -> do
        hb_font_get_scale font' x' y'
        x <- peek x'
        y <- peek y'
        return (x, y)
        x <- peek x' :: IO Int32
        y <- peek y' :: IO Int32
        return (fromEnum x, fromEnum y)
foreign import ccall "hb_font_get_scale" hb_font_get_scale
    :: Font_ -> Ptr Int -> Ptr Int -> IO ()
    :: Font_ -> Ptr Int32 -> Ptr Int32 -> IO ()

-- | Fetches the "synthetic slant" of a font.
fontSyntheticSlant :: Font -> Float