Skip to main content

Crate GORBIE

Crate GORBIE 

Source
Expand description

§Working with mutable/non-cloneable things.

Sometimes when working with existing code, libraries or even std things like files, can introduce an impedance mismatch with a dataflow-style model. Often it is enough to wrap the object in question into another layer of Arcs and RWLocks in addition to what Gorby already does with its shared state store.

For heavier work, ComputedState can run background tasks and hold the latest value. Use Option<T> when a value may be absent while a computation runs.

But sometimes that isn’t enough, e.g. when you want to display some application global state. This is why NotebookCtx::state and NotebookCtx::view are carefully designed to stay independent from any dataflow runtime. Instead they can be used, like any other mutable rust type, via the typed StateId handle.

Re-exports§

pub use card_ctx::CardCtx;
pub use card_ctx::Grid;
pub use card_ctx::GRID_COL_WIDTH;
pub use card_ctx::GRID_COLUMNS;
pub use card_ctx::GRID_GUTTER;

Modules§

card_ctx
Card context — the &mut CardCtx passed to card closures.
cards
Card trait and built-in card types (stateful, stateless).
dataflow
Background computation with ComputedState.
prelude
Convenient glob import of common types and constants. Re-exports commonly used types, constants, and helpers for convenient glob imports.
state
Thread-safe state management via StateId handles.
themes
Visual themes, RAL colors, and widget style structs.
widgets
Built-in widgets: buttons, fields, sliders, progress bars, and more. Widgets module — a thin glossary re-exporting individual widget submodules.

Macros§

md
Render a formatted markdown string as a full-width grid cell.
note
Render a formatted markdown string inside a styled note frame.

Structs§

EditorCommand
Command template for opening source files in an external editor.
NotebookConfig
Configuration for a notebook application.
NotebookCtx
Frame-scoped notebook builder used to collect cards in immediate mode.

Attribute Macros§

notebook