pub fn new() -> Self {
        let mut tabs = TabView::new();
        let (tx, rx) = unbounded();
        let (active_tx, active_rx) = unbounded();
        tabs.set_bar_rx(rx);
        tabs.set_active_key_tx(active_tx);
        Self {
            bar: TabBar::new(active_rx)
                .with_placement(Placement::HorizontalTop)
                .with_alignment(Align::Start),
            bar_size: Vec2::new(1, 1),
            tab_size: Vec2::new(1, 1),
            tabs,
            tx,
            bar_focused: true,
            bar_align: Align::Start,
            bar_placement: Placement::HorizontalTop,
        }
    }
/// Returns a new instance of a TabPanel.
/// Alignment is set by default to left, to change this use `set_bar_alignment` to change to any other `HAlign` provided by `cursive`.
Returns a new instance of a TabPanel.
Returns a new instance of a TabPanel .
pub fn new() -> Self {
        let mut tabs = TabView::new();
        let (tx, rx) = unbounded();
        let (active_tx, active_rx) = unbounded();
        tabs.set_bar_rx(rx);
        tabs.set_active_key_tx(active_tx);
        Self {
            bar: TabBar::new(active_rx)
                .with_placement(Placement::HorizontalTop)
                .with_alignment(Align::Start),
            bar_size: Vec2::new(1, 1),
            tab_size: Vec2::new(1, 1),
            tabs,
            tx,
            bar_focused: true,
            bar_align: Align::Start,
            bar_placement: Placement::HorizontalTop,
        }
    }
pub fn new ( ) -> Self { let mut tabs = TabView :: new ( ) ; let ( tx , rx ) = unbounded ( ) ; let ( active_tx , active_rx ) = unbounded ( ) ; tabs . set_bar_rx ( rx ) ; tabs . set_active_key_tx ( active_tx ) ; Self { bar : TabBar :: new ( active_rx ) . with_placement ( Placement :: HorizontalTop ) . with_alignment ( Align :: Start ) , bar_size : Vec2 :: new ( 1 , 1 ) , tab_size : Vec2 :: new ( 1 , 1 ) , tabs , tx , bar_focused : true , bar_align : Align :: Start , bar_placement : Placement :: HorizontalTop , } }
Returns a new instance of a TabPanel.
Returns a new instance of a TabPanel .