Enum cursive::menu::MenuItem [] [src]

pub enum MenuItem {
    Leaf(StringCallback),
    Subtree(StringRc<MenuTree>),
    Delimiter,
}

Node in the menu tree.

Variants

Actionnable button with a label.

Sub-menu with a label.

Delimiter without a label.

Methods

impl MenuItem
[src]

[src]

Returns the label for this item.

Returns an empty string if self is a delimiter.

[src]

Returns true if self is a delimiter.

[src]

Returns true if self is a leaf node.

[src]

Returns true if self is a subtree.

[src]

Return a mutable reference to the subtree, if applicable.

Returns None if self is not a MenuItem::Subtree.

Trait Implementations

impl Clone for MenuItem
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl !Send for MenuItem

impl !Sync for MenuItem