-- GENERATED by C->Haskell Compiler, version 0.28.3 Switcheroo, 25 November 2017 (Haskell)
-- Edit the ORIGNAL .chs file instead!


{-# LINE 1 "src/NanoVG/Internal/State.chs" #-}
module NanoVG.Internal.State where
import qualified Foreign.Ptr as C2HSImp



import NanoVG.Internal.Context




{-# LINE 7 "src/NanoVG/Internal/State.chs" #-}


-- | Pushes and saves the current render state into a state stack.
--
-- A matching 'restore' must be used to restore the state.
save :: (Context) -> IO ()
save a1 =
  let {a1' = id a1} in
  save'_ a1' >>
  return ()

{-# LINE 13 "src/NanoVG/Internal/State.chs" #-}


-- | Pops and restores current render state.
restore :: (Context) -> IO ()
restore a1 =
  let {a1' = id a1} in
  restore'_ a1' >>
  return ()

{-# LINE 17 "src/NanoVG/Internal/State.chs" #-}


-- | Resets current render state to default values. Does not affect the render state stack.
reset :: (Context) -> IO ()
reset a1 =
  let {a1' = id a1} in
  reset'_ a1' >>
  return ()

{-# LINE 21 "src/NanoVG/Internal/State.chs" #-}



foreign import ccall unsafe "NanoVG/Internal/State.chs.h nvgSave"
  save'_ :: ((Context) -> (IO ()))

foreign import ccall unsafe "NanoVG/Internal/State.chs.h nvgRestore"
  restore'_ :: ((Context) -> (IO ()))

foreign import ccall unsafe "NanoVG/Internal/State.chs.h nvgReset"
  reset'_ :: ((Context) -> (IO ()))