fatui 0.1.0

a silly little framework for terminal user interfaces
Documentation
#![warn(missing_docs)]
#![forbid(clippy::missing_safety_doc)]

//! `fatui` is a textmode ui interface library that aims to be
//! flexible, cell-perfect, immediate-mode.
//!
//! you'll start by finding a [`Backend`],
//! which represents the actual input and output system --
//! ansi terminals, graphical renderers, whatever.
//! you usually want [`open`] -- that'll pick "the right one",
//! based on the features you have configured and the runtime environment.
//!
//! from there you'll call [`Backend::step`] to get a [`Frame`],
//! which represents the input state and lets you render the output.
//! notably: none of the operations on it actually do any i/o --
//! they're purely in memory, which makes it quite quick to work with.
//! the actual input and output are all contained in the `step` function.
//!
//! once you have a frame, you can do two major things with it:
//! - [`Frame::split`] splits up the frame into multiple non-overlapping regions,
//!   each of which can itself be treated like a frame,
//!   say by splitting it even further
//! - [`Frame::render`] renders a component into a frame,
//!   processing some input and returning some output
//!
//! for details about the builtin functionality, check
//! the [`split`] and [`component`] module docs.

pub mod backend;
pub use backend::{Backend, open};
pub mod grid;
pub mod pos;

pub mod frame;
pub use frame::Frame;
pub mod input;
pub use input::{
	// raw-er input stuff
	Event,
	// higher-level input stuff
	InputState,
	KeyCode,
	MouseButton,
	StateEvent,
};
pub mod output;

pub mod split;
pub use split::Splitter;

trait Sealed {}
macro_rules! seal {
	($(
		$({ $($parm:tt)* })? $type:ident $({$($appl:tt)*})?
	),+ $(,)?) => {$(
		impl$(<$($parm)*>)? crate::Sealed for $type$(<$($appl)*>)? {}
	)*};
}
pub(crate) use seal;