helic-0.1.0.0: Clipboard Manager
Safe HaskellNone
LanguageHaskell2010

Helic.Interpreter.XClipboard

Description

XClipboard Interpreter, Internal

Synopsis

Documentation

withMainLoop :: Members [Resource, Error Text, Race, Async, Embed IO] r => InterpreterFor (Reader GtkState) r Source #

Execute a GTK main loop in a baackground thread and interpret Reader GtkState. The clipboards stored in the state need the main loop running to work properly. The main loop is killed after the interpreted program terminates.

subscribeToClipboard :: Members [Events resource XClipboardEvent, Reader GtkState, Embed IO, Final IO] r => Clipboard -> Selection -> Sem r () Source #

Listen to clipboard events for a specific source, like "primary selection", and publish them via Events.

clipboardEvents :: Members [Events resource XClipboardEvent, Reader GtkState, Embed IO, Final IO] r => Sem r () Source #

Listen to clipboard events and publish them via Events.

listenXClipboard :: Members [Events resource XClipboardEvent, Error Text, Race, Resource, Async, Embed IO, Final IO] r => InterpreterFor (Reader GtkState) r Source #

Run a GTK main loop and listen to clipboard events, publishing them via Events.

interpretXClipboardGtk :: Members [Reader GtkState, Embed IO] r => InterpreterFor XClipboard r Source #

Interpret XClipboard using a GTK backend. This uses the gi-gtk library to access the X11 clipboard.