pub struct WindowFlags {
pub move: bool,
pub grow: bool,
pub close: bool,
pub zoom: bool,
}Expand description
Window decoration flags: which of move / grow / close / zoom the window allows.
Build a customised WindowFlags (e.g. at construction) to change which
controls appear on the frame. The default (via Default) enables all
four. Disable individual fields to suppress a decoration:
use tvision_rs::window::WindowFlags;
let no_zoom = WindowFlags { zoom: false, ..Default::default() };
assert!(!no_zoom.zoom);r#move spelling: move is a Rust keyword, so the field is accessed as
flags.r#move. The raw-identifier syntax is a Rust-only artefact; at the
semantic level it is identical to the C++ wfMove bit.
These flags belong to the window; the Frame receives a pushed-down copy
via Frame::set_flags and renders the
corresponding icons (close [×], zoom [↕], grow corner ▐).
§Turbo Vision heritage
Ports the wfMove / wfGrow / wfClose / wfZoom flag word (views.h) as a
struct-of-bools.
Fields§
§move: boolThe window can be moved by dragging its frame.
grow: boolThe window can be resized by dragging its bottom corners.
close: boolThe window shows a close icon (and accepts a close command).
zoom: boolThe window shows a zoom icon (and accepts a zoom command).
Trait Implementations§
Source§impl Clone for WindowFlags
impl Clone for WindowFlags
Source§fn clone(&self) -> WindowFlags
fn clone(&self) -> WindowFlags
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for WindowFlags
Source§impl Debug for WindowFlags
impl Debug for WindowFlags
Source§impl Default for WindowFlags
impl Default for WindowFlags
Source§fn default() -> WindowFlags
fn default() -> WindowFlags
impl Eq for WindowFlags
Source§impl PartialEq for WindowFlags
impl PartialEq for WindowFlags
impl StructuralPartialEq for WindowFlags
Auto Trait Implementations§
impl Freeze for WindowFlags
impl RefUnwindSafe for WindowFlags
impl Send for WindowFlags
impl Sync for WindowFlags
impl Unpin for WindowFlags
impl UnsafeUnpin for WindowFlags
impl UnwindSafe for WindowFlags
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.