pub struct Panel { /* private fields */ }Expand description
A Panel is a control within a window that groups other controls. It defines its own reference system, that is, if we move a panel all its descendants will move in unison since their locations will be relative to its origin. It will support other (sub)-panels as descendants, which allows to form a Window Hierarchy. A Panel is a control within a window that groups other controls.
§Remark
This type is managed by nappgui itself. Rust does not have its ownership. When the window object is dropped, all components assciated with it will be automatically released.
Implementations§
Trait Implementations§
Source§impl ControlLayoutTrait for Panelwhere
Panel: PanelTrait,
impl ControlLayoutTrait for Panelwhere
Panel: PanelTrait,
Source§fn insert_in_layout<T>(&self, layout: T, col: u32, row: u32)where
T: LayoutTrait,
fn insert_in_layout<T>(&self, layout: T, col: u32, row: u32)where
T: LayoutTrait,
Insert the control to the layout
Source§impl ControlTrait for Panel
impl ControlTrait for Panel
Source§fn as_control_ptr(&self) -> *mut GuiControl
fn as_control_ptr(&self) -> *mut GuiControl
Returns the pointer to the control.
Source§fn from_control_ptr(ptr: *mut GuiControl) -> Option<Self>
fn from_control_ptr(ptr: *mut GuiControl) -> Option<Self>
Returns the control from the pointer.
impl Copy for Panel
Source§impl PanelTrait for Panel
impl PanelTrait for Panel
Source§fn layout<T>(&self, layout: T)where
T: LayoutTrait,
fn layout<T>(&self, layout: T)where
T: LayoutTrait,
Add a layout to a panel.
Source§fn visible_layout(&self, index: usize)
fn visible_layout(&self, index: usize)
Set the active layout inside the panel. Read more
Source§fn scroll_width(&self) -> f32
fn scroll_width(&self) -> f32
Gets the width of the scroll bar of the associated panel. Read more
Source§fn scroll_height(&self) -> f32
fn scroll_height(&self) -> f32
Gets the height of the scroll bar.
Auto Trait Implementations§
impl !Send for Panel
impl !Sync for Panel
impl Freeze for Panel
impl RefUnwindSafe for Panel
impl Unpin for Panel
impl UnsafeUnpin for Panel
impl UnwindSafe for Panel
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