Expand description
§gooey 
UI library
A gooey Interface is defined as a layer between an Application and a
Presentation backend.
An Application implementation can handle
Callbacks on model data
bound to the Interface, and a Presentation backend can receive
Input from the user or OS and display a
view of the interface.
use gooey::{application, presentation, widget, Presentation};
use gooey::interface::{self, Interface, view};
// create a default interface with a headless presentation layer that reads
// from stdin and ignores all display values
let mut interface =
presentation::Headless::make_interface::<application::Default>();
// attach a widget to the root node
let root_id = interface.root_id().clone();
let action = interface::Action::create_singleton (
widget::playback::new (None), interface::CreateOrder::Append);
for event in interface.action (&root_id, action) {
// ... model events
}
// get stdin and update the interface
for event in interface.update() {
// ... model events
}
interface.display(); // no-opSee ./examples/ for complete examples.
Re-exports§
pub use self::application::Application;pub use self::interface::Interface;pub use self::presentation::Presentation;pub use self::utils::TreeHelper;pub use self::widget::Widget;pub use id_tree as tree;pub use nsys::math;
Modules§
- application
- Application layer.
- geometry
- Geometry utilities
- interface
- Interface layer.
- prelude
- Convenience re-exports
- presentation
- Presentation layer.
- utils
- Utility functions
- widget
- Contextual interface elements.
Macros§
- def_
callback_ ids - Define an enum where each variant derefs into an application
Callback - extend_
control - Defines one or more extended control
Ids for aControltype
Structs§
- Tree
- A tree structure consisting of
Nodes.
Functions§
- report_
sizes - Diagnostic print sizes of various types