Fusuma

Components / Components

splitter

A splitter at permille thousandths, sending what on_change makes of the new position.

How it looks

Drawn by the toolkit from the example below. No page of the gallery uses splitter yet, so there is nothing to run.

splitter drawn by Fusuma

A splitter at permille thousandths, sending what on_change makes of the new position.

Signature

pub const fn splitter<M>(permille: u16, on_change: fn(u16) -> M) -> Splitter<M>

Example

use fusuma::splitter;
let view = splitter(500, |permille| permille);
let built = fusuma::doc::built::<u16, _>(&view);
assert_eq!(built.nodes(), 1);

All components · Source