The bindings-wlc package

[Tags:bsd3, library, test]

Please see Readme.md


[Skip to Readme]

Properties

Versions 0.1.0.0, 0.1.0.1, 0.1.0.2, 0.1.0.3, 0.1.0.5, 0.1.0.7 (info)
Dependencies base (>=4.7 && <5), bindings-DSL (>=1.0.23 && <1.1), convertible (>=1.1.1.0 && <1.1.2.0) [details]
License BSD3
Copyright 2016 Ashley Towns
Author Ashley Towns
Maintainer mail@ashleytowns.id.au
Stability Unknown
Category FFI
Home page http://github.com/aktowns/bindings-wlc#readme
Source repository head: git clone https://github.com/aktowns/bindings-wlc
Uploaded Sun Apr 3 11:02:34 UTC 2016 by ashleyis
Distributions NixOS:0.1.0.7
Downloads 175 total (5 in the last 30 days)
Votes
0 []
Status Docs uploaded by user
Build status unknown [no reports yet]

Modules

[Index]

Downloads

Maintainer's Corner

For package maintainers and hackage trustees

Readme for bindings-wlc

Readme for bindings-wlc-0.1.0.7

bindings-wlc

WIP bindings against libwlc

Using Bindings.WLC

Low level bindings to WLC via bindings-dsl

do
  logger <- mk'log_handler_cb (\_ -> print)
  c'wlc_log_set_handler logger

  c'wlc_init2

  created_cb <- mk'output_created_cb (\output -> do
    putStrLn "Output created"
    return True)
  c'wlc_set_output_created_cb created_cb

  c'wlc_run

Using System.WLC

System.WLC builds on Binding.WLC

do
  initialize
  logHandler (\tag text -> putStrLn $ stringTag tag ++ " " ++ text) -- Log all the things
  dispatchEvent (PointerMotion (\_ _ ptr -> do pointerSetPosition ptr; return True)) -- Allow mouse movement
  dispatchEvent (ViewCreated (\view -> do viewBringToFront view; viewFocus view; return True)) -- Pop views to the front
  dispatchEvent (CompositorReady $ exec "weston-terminal" []) -- Launch weston-terminal when we're ready
  run