pub struct Cluster {
pub id: ClusterId,
pub core: Option<NodeId>,
pub mode: ClusterMode,
pub active_workspace: Option<ActiveWorkspace>,
/* private fields */
}Expand description
A cluster is a group of window nodes (members). When collapsed, a Core node represents the cluster as the handle.
Fields§
§id: ClusterId§core: Option<NodeId>When collapsed, which Core node represents this cluster.
mode: ClusterMode§active_workspace: Option<ActiveWorkspace>Implementations§
Source§impl Cluster
impl Cluster
pub fn new(id: ClusterId, members: Vec<NodeId>) -> Option<Self>
pub fn contains(&self, id: NodeId) -> bool
pub fn members(&self) -> &[NodeId]
pub fn master(&self) -> NodeId
pub fn secondaries(&self) -> &[NodeId]
pub fn visible_members(&self, max_stack: usize) -> &[NodeId]
pub fn overflow_members(&self, max_stack: usize) -> &[NodeId]
pub fn core_node(&self) -> Option<NodeId>
pub fn is_collapsed(&self) -> bool
pub fn is_active(&self) -> bool
pub fn set_collapsed(&mut self, collapsed: bool)
pub fn enter_active(&mut self)
pub fn exit_active(&mut self)
pub fn workspace_layout( &self, bounds: Rect, max_stack: usize, ) -> MasterStackLayout
pub fn workspace_member(&self, id: NodeId) -> Option<&Node>
pub fn workspace_member_mut(&mut self, id: NodeId) -> Option<&mut Node>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Cluster
impl RefUnwindSafe for Cluster
impl Send for Cluster
impl Sync for Cluster
impl Unpin for Cluster
impl UnsafeUnpin for Cluster
impl UnwindSafe for Cluster
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more