brillo-2.0.0: Painless 2D vector graphics, animations, and simulations powered by GLFW
Safe HaskellNone
LanguageGHC2021

Brillo.Interface.Environment

Synopsis

Documentation

getScreenSize :: IO (Int, Int) Source #

Get the size of the screen, in pixels.

This will be the size of the rendered brillo image when fullscreen mode is enabled.

openFileDialog :: FileDialog -> IO (Maybe [FilePath]) Source #

Open a file dialog to select files/directories.

Returns a list of paths, or Nothing if the dialog was cancelled.

saveFileDialog Source #

Arguments

:: Text

Dialog title

-> Text

Default file path

-> [Text]

Filter patterns like ["*.svg", "*.png"]

-> Text

Filter description like "Image files"

-> IO (Maybe FilePath) 

Open a save file dialog.

Returns the selected file path, or Nothing if the dialog was cancelled.