[][src]Crate cursive_multiplex

cursive view multiplexer

This crate provides a view for the cursive tui crate. It provides an easier way to display nesting view structures as for example in tmux in cursive. All that has to be done is to insert the view into cursive and later to operate on the reference of it, to add, remove, switch views.

Similar to tmux the user is able to resize, and switch between the current views, given they are focusable.

Usage example

extern crate cursive;
extern crate cursive_multiplex;

use cursive_multiplex::Mux;
use cursive::views::TextView;
use cursive::Cursive;

fn main() {
    let mut mux = Mux::new();
    let node1 = mux.add_right_of(TextView::new("Hello World"), mux.root().build().unwrap()).unwrap();
    let mut siv = Cursive::default();
    mux.add_right_of(TextView::new("Hello from me too!".to_string()), node1);

    // When your finished setting up
    // siv.run();



View holding information and managing multiplexer.


Path used to get the id of a specific pane in the mux. self can be directed by calling .up(), .down(), .left() and .right() on the instance. To get the final id of a pane .build().



Type Definitions


Identifier for views in binary tree of mux, typically returned after adding a new view to the multiplexer.