Portability | portable (depends on GHC) |
---|---|
Stability | stable |
Maintainer | gtk2hs-devel@lists.sourceforge.net |
Safe Haskell | None |
An alternative implementation of the graphics library used in The Haskell School of Expression, by Paul Hudak, http://www.haskell.org/soe/.
It has exaclty the same interface as the original implementation Graphics.SOE. See the original for an API reference.
- runGraphics :: IO () -> IO ()
- type Title = String
- type Size = (Int, Int)
- data Window
- openWindow :: Title -> Size -> IO Window
- getWindowSize :: Window -> IO Size
- clearWindow :: Window -> IO ()
- drawInWindow :: Window -> Graphic -> IO ()
- drawInWindowNow :: Window -> Graphic -> IO ()
- setGraphic :: Window -> Graphic -> IO ()
- closeWindow :: Window -> IO ()
- openWindowEx :: Title -> Maybe Point -> Maybe Size -> RedrawMode -> Maybe Time -> IO Window
- data RedrawMode
- drawGraphic :: RedrawMode
- drawBufferedGraphic :: RedrawMode
- data Graphic
- emptyGraphic :: Graphic
- overGraphic :: Graphic -> Graphic -> Graphic
- overGraphics :: [Graphic] -> Graphic
- data Color
- withColor :: Color -> Graphic -> Graphic
- text :: Point -> String -> Graphic
- type Point = (Int, Int)
- ellipse :: Point -> Point -> Graphic
- shearEllipse :: Point -> Point -> Point -> Graphic
- line :: Point -> Point -> Graphic
- polygon :: [Point] -> Graphic
- polyline :: [Point] -> Graphic
- polyBezier :: [Point] -> Graphic
- type Angle = Float
- arc :: Point -> Point -> Angle -> Angle -> Graphic
- data Region
- createRectangle :: Point -> Point -> Region
- createEllipse :: Point -> Point -> Region
- createPolygon :: [Point] -> Region
- andRegion :: Region -> Region -> Region
- orRegion :: Region -> Region -> Region
- xorRegion :: Region -> Region -> Region
- diffRegion :: Region -> Region -> Region
- drawRegion :: Region -> Graphic
- getKey :: Window -> IO Char
- getLBP :: Window -> IO Point
- getRBP :: Window -> IO Point
- data Event
- maybeGetWindowEvent :: Window -> IO (Maybe Event)
- getWindowEvent :: Window -> IO Event
- getWindowTick :: Window -> IO ()
- data Word32
- timeGetTime :: IO Word32
- word32ToInt :: Word32 -> Int
Documentation
runGraphics :: IO () -> IO ()Source
getWindowSize :: Window -> IO SizeSource
clearWindow :: Window -> IO ()Source
drawInWindow :: Window -> Graphic -> IO ()Source
drawInWindowNow :: Window -> Graphic -> IO ()Source
setGraphic :: Window -> Graphic -> IO ()Source
closeWindow :: Window -> IO ()Source
data RedrawMode Source
overGraphic :: Graphic -> Graphic -> GraphicSource
overGraphics :: [Graphic] -> GraphicSource
polyBezier :: [Point] -> GraphicSource
createRectangle :: Point -> Point -> RegionSource
createEllipse :: Point -> Point -> RegionSource
createPolygon :: [Point] -> RegionSource
diffRegion :: Region -> Region -> RegionSource
drawRegion :: Region -> GraphicSource
getWindowEvent :: Window -> IO EventSource
getWindowTick :: Window -> IO ()Source
data Word32
32-bit unsigned integer type
word32ToInt :: Word32 -> IntSource