brick: A declarative terminal user interface library

This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.

Maintainers' corner

Readme for brick-0.24.2

brick

brick is a Haskell terminal user interface programming library in the
style of gloss. This means
you write a function that describes how your user interface should look,
but the library takes care of a lot of the book-keeping that so commonly
goes into writing such programs.

brick exposes a declarative API. Unlike most GUI toolkits which
require you to write a long and tedious sequence of "create a widget,
now bind an event handler", brick just requires you to describe your
interface using a set of declarative combinators. Then you provide a
function to transform your application state when input or other kinds
of events arrive.

Under the hood, this library builds upon
vty, so some knowledge of Vty
will be helpful in using this library.

Brick-Users Discussion

Status

There are some places were I have deliberately chosen to worry about
performance later for the sake of spending more time on the design (and
to wait on performance issues to arise first). brick is also something
of an experimental project of mine and some aspects of the design
involve trade-offs that may are not entirely settled. In addition you
can expect this library to follow a principle of fearless improvement:
new versions will make (sometimes substantial) API changes if those
changes really do make the library better. I will place more importance
on getting the API right than on maintaining backwards compatibility.

brick exports an extension API that makes it possible to make your own
packages and widgets. If you use that, you'll also be helping to test
whether the exported interface is usable and complete!

Reporting bugs

Please file bug reports as GitHub issues. For best results:

Include the versions of relevant software packages: your terminal
emulator, brick, ghc, and vty will be the most important
ones.

Clearly describe the behavior you expected ...

... and include a minimal demonstration program that exhibits the
behavior you actually observed.

Contributing

If you decide to contribute, that's great! Here are some guidelines you
should consider to make submitting patches easier for all concerned:

If you want to take on big things, talk to me first; let's have a
design/vision discussion before you start coding. Create a GitHub
issue and we can use that as the place to hash things out.

Please make changes consistent with the conventions I've used in the
codebase.