LambdaHack-0.11.0.0: A game engine library for tactical squad ASCII roguelike dungeon crawlers
Safe HaskellNone
LanguageHaskell2010

Game.LambdaHack.Client.UI.Frontend.Common

Description

Screen frames and animations.

Synopsis

Documentation

data RawFrontend Source #

Raw frontend definition. The minimal closed set of values that need to depend on the specifics of the chosen frontend.

Constructors

RawFrontend 

startupBound :: (MVar RawFrontend -> IO ()) -> IO RawFrontend Source #

Start up a frontend on a bound thread.

In fact, it is started on the very main thread, via a hack, because apparently some SDL backends are not thread-safe (https://wiki.libsdl.org/FAQDevelopment; "this should only be run in the thread that initialized the video subsystem, and for extra safety, you should consider only doing those things on the main thread in any case") and at least the newer OS X obtusely requires the main thread, see https://github.com/AllureOfTheStars/Allure/issues/79 In case any other exotic architecture requires the main thread, we make the hack the default for all (on frontends that require a bound thread, e.g., SLD2).

resetChanKey :: TQueue KMP -> IO () Source #

Empty the keyboard channel.

modifierTranslate :: Bool -> Bool -> Bool -> Bool -> Modifier Source #

Translates modifiers to our own encoding.