pub enum Overflow {
Scroll,
Auto,
Hidden,
Visible,
}
Expand description
Represents a overflow-x
or overflow-y
property, see
TextOverflowBehaviour
- default: Auto
Variants§
Scroll
Always shows a scroll bar, overflows on scroll
Auto
Does not show a scroll bar by default, only when text is overflowing
Hidden
Never shows a scroll bar, simply clips text
Visible
Doesn’t show a scroll bar, simply overflows the text
Implementations§
Source§impl Overflow
impl Overflow
Sourcepub fn needs_scrollbar(&self, currently_overflowing: bool) -> bool
pub fn needs_scrollbar(&self, currently_overflowing: bool) -> bool
Returns whether this overflow value needs to display the scrollbars.
overflow:scroll
always shows the scrollbaroverflow:auto
only shows the scrollbar when the content is currently overflowingoverflow:hidden
andoverflow:visible
do not show any scrollbars
Sourcepub fn is_overflow_visible(&self) -> bool
pub fn is_overflow_visible(&self) -> bool
Returns whether this is an overflow:visible
node
(the only overflow type that doesn’t clip its children)
Trait Implementations§
Source§impl Ord for Overflow
impl Ord for Overflow
Source§impl PartialOrd for Overflow
impl PartialOrd for Overflow
impl Copy for Overflow
impl Eq for Overflow
impl StructuralPartialEq for Overflow
Auto Trait Implementations§
impl Freeze for Overflow
impl RefUnwindSafe for Overflow
impl Send for Overflow
impl Sync for Overflow
impl Unpin for Overflow
impl UnwindSafe for Overflow
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)