Struct fltk::window::OverlayWindow [−][src]
pub struct OverlayWindow { /* fields omitted */ }
Expand description
Creates an overlay (buffered) window widget
Implementations
impl OverlayWindow
[src]
impl OverlayWindow
[src]pub fn default() -> OverlayWindow
[src]
pub fn default() -> OverlayWindow
[src]Creates a default initialized overlay window
pub unsafe fn find_by_handle(handle: RawHandle) -> Option<impl WindowExt>
[src]
pub unsafe fn find_by_handle(handle: RawHandle) -> Option<impl WindowExt>
[src]Find an Fl_Window
through a raw handle. The window must have been instatiated by the app.
void *
to: (Windows: HWND
, X11: Xid
(u64
), macOS: NSWindow
)
Safety
The data must be valid and is OS-dependent.
pub fn show_with_env_args(&mut self)
[src]
pub fn show_with_env_args(&mut self)
[src]Use FLTK specific arguments for the application: More info here. The options are:
-bg2 color
-bg color
-di[splay] host:n.n
-dn[d]
-fg color
-g[eometry] WxH+X+Y
-i[conic]
-k[bd]
-na[me] classname
-nod[nd]
-nok[bd]
-not[ooltips]
-s[cheme] scheme
-ti[tle] windowtitle
-to[oltips]
pub fn show_with_args(&mut self, args: &[&str])
[src]
pub fn show_with_args(&mut self, args: &[&str])
[src]Use FLTK specific arguments for the application: More info here. The options are:
-bg2 color
-bg color
-di[splay] host:n.n
-dn[d]
-fg color
-g[eometry] WxH+X+Y
-i[conic]
-k[bd]
-na[me] classname
-nod[nd]
-nok[bd]
-not[ooltips]
-s[cheme] scheme
-ti[tle] windowtitle
-to[oltips]
pub fn flush(&mut self)
[src]
pub fn flush(&mut self)
[src]Forces the window to be drawn, this window is also made current and calls draw()
pub fn draw_overlay<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]
pub fn draw_overlay<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]Draw overlay
pub fn redraw_overlay(&self)
[src]
pub fn redraw_overlay(&self)
[src]Redraw overlay
pub fn can_do_overlay(&self) -> bool
[src]
pub fn can_do_overlay(&self) -> bool
[src]Returns whether the overlay window can do hardware backed overlay
Trait Implementations
impl Clone for OverlayWindow
[src]
impl Clone for OverlayWindow
[src]fn clone(&self) -> OverlayWindow
[src]
fn clone(&self) -> OverlayWindow
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for OverlayWindow
[src]
impl Debug for OverlayWindow
[src]impl Default for OverlayWindow
[src]
impl Default for OverlayWindow
[src]impl GroupExt for OverlayWindow
[src]
impl GroupExt for OverlayWindow
[src]unsafe fn unsafe_clear(&mut self)
[src]
unsafe fn unsafe_clear(&mut self)
[src]Clear a group from all widgets using FLTK’s clear call. Read more
fn find<W: WidgetExt>(&self, widget: &W) -> i32
[src]
fn find<W: WidgetExt>(&self, widget: &W) -> i32
[src]Find a widget within a group and return its index
fn insert<W: WidgetExt>(&mut self, widget: &W, index: i32)
[src]
fn insert<W: WidgetExt>(&mut self, widget: &W, index: i32)
[src]Insert a widget to a group at a certain index
fn remove<W: WidgetExt>(&mut self, widget: &W)
[src]
fn remove<W: WidgetExt>(&mut self, widget: &W)
[src]Remove a widget from a group, but does not delete it
fn remove_by_index(&mut self, idx: i32)
[src]
fn remove_by_index(&mut self, idx: i32)
[src]Remove a child widget by its index
fn make_resizable(&mut self, val: bool)
[src]
fn make_resizable(&mut self, val: bool)
[src]Make the window resizable, should be called before show
fn set_clip_children(&mut self, flag: bool)
[src]
fn set_clip_children(&mut self, flag: bool)
[src]Clips children outside the group boundaries
fn clip_children(&mut self) -> bool
[src]
fn clip_children(&mut self) -> bool
[src]Get whether clip_children
is set
fn draw_child<W: WidgetExt>(&self, w: &mut W)
[src]
fn draw_child<W: WidgetExt>(&self, w: &mut W)
[src]Draw a child widget, the call should be in a WidgetBase::draw
method
fn update_child<W: WidgetExt>(&self, w: &mut W)
[src]
fn update_child<W: WidgetExt>(&self, w: &mut W)
[src]Update a child widget, the call should be in a WidgetBase::draw
method
fn draw_outside_label<W: WidgetExt>(&self, w: &mut W)
[src]
fn draw_outside_label<W: WidgetExt>(&self, w: &mut W)
[src]Draw the outside label, the call should be in a WidgetBase::draw
method
fn draw_children(&mut self)
[src]
fn draw_children(&mut self)
[src]Draw children, the call should be in a WidgetBase::draw
method
impl HasRawWindowHandle for OverlayWindow
[src]
impl HasRawWindowHandle for OverlayWindow
[src]fn raw_window_handle(&self) -> RawWindowHandle
[src]
impl IntoIterator for OverlayWindow
[src]
impl IntoIterator for OverlayWindow
[src]impl WidgetBase for OverlayWindow
[src]
impl WidgetBase for OverlayWindow
[src]fn new<T: Into<Option<&'static str>>>(
x: i32,
y: i32,
width: i32,
height: i32,
title: T
) -> OverlayWindow
[src]
fn new<T: Into<Option<&'static str>>>(
x: i32,
y: i32,
width: i32,
height: i32,
title: T
) -> OverlayWindow
[src]Creates a new widget, takes an x, y coordinates, as well as a width and height, plus a title Read more
unsafe fn from_widget_ptr(ptr: *mut Fl_Widget) -> Self
[src]
unsafe fn from_widget_ptr(ptr: *mut Fl_Widget) -> Self
[src]transforms a widget pointer to a Widget, for internal use Read more
unsafe fn from_widget<W: WidgetExt>(w: W) -> Self
[src]
unsafe fn from_widget<W: WidgetExt>(w: W) -> Self
[src]Get a widget from base widget Read more
fn handle<F: FnMut(&mut Self, Event) -> bool + 'static>(&mut self, cb: F)
[src]
fn handle<F: FnMut(&mut Self, Event) -> bool + 'static>(&mut self, cb: F)
[src]Set a custom handler, where events are managed manually, akin to Fl_Widget::handle(int)
.
Handled or ignored events should return true, unhandled events should return false.
takes the widget as a closure argument Read more
fn draw<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]
fn draw<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]Set a custom draw method.
takes the widget as a closure argument.
macOS requires that WidgetBase::draw
actually calls drawing functions Read more
impl WidgetExt for OverlayWindow
[src]
impl WidgetExt for OverlayWindow
[src]fn set_label(&mut self, title: &str)
[src]
fn set_label(&mut self, title: &str)
[src]Sets the widget’s label.
labels support special symbols preceded by an @
sign.
and for the associated formatting. Read more
unsafe fn as_widget_ptr(&self) -> *mut Fl_Widget
[src]
unsafe fn as_widget_ptr(&self) -> *mut Fl_Widget
[src]transforms a widget to a base Fl_Widget
, for internal use Read more
fn deactivate(&mut self)
[src]
fn deactivate(&mut self)
[src]Deactivates the widget
fn redraw_label(&mut self)
[src]
fn redraw_label(&mut self)
[src]Redraws the label of the widget
fn resize(&mut self, x: i32, y: i32, width: i32, height: i32)
[src]
fn resize(&mut self, x: i32, y: i32, width: i32, height: i32)
[src]Resizes and/or moves the widget, takes x, y, width and height
fn set_tooltip(&mut self, txt: &str)
[src]
fn set_tooltip(&mut self, txt: &str)
[src]Sets the tooltip text
fn label_color(&self) -> Color
[src]
fn label_color(&self) -> Color
[src]Returns the widget label’s color
fn set_label_color(&mut self, color: Color)
[src]
fn set_label_color(&mut self, color: Color)
[src]Sets the widget label’s color
fn label_font(&self) -> Font
[src]
fn label_font(&self) -> Font
[src]Returns the widget label’s font
fn set_label_font(&mut self, font: Font)
[src]
fn set_label_font(&mut self, font: Font)
[src]Sets the widget label’s font
fn label_size(&self) -> i32
[src]
fn label_size(&self) -> i32
[src]Returns the widget label’s size
fn set_label_size(&mut self, sz: i32)
[src]
fn set_label_size(&mut self, sz: i32)
[src]Sets the widget label’s size
fn label_type(&self) -> LabelType
[src]
fn label_type(&self) -> LabelType
[src]Returns the widget label’s type
fn set_label_type(&mut self, typ: LabelType)
[src]
fn set_label_type(&mut self, typ: LabelType)
[src]Sets the widget label’s type
fn set_changed(&mut self)
[src]
fn set_changed(&mut self)
[src]Mark the widget as changed
fn clear_changed(&mut self)
[src]
fn clear_changed(&mut self)
[src]Clears the changed status of the widget
fn set_trigger(&mut self, trigger: CallbackTrigger)
[src]
fn set_trigger(&mut self, trigger: CallbackTrigger)
[src]Sets the default callback trigger for a widget
fn trigger(&self) -> CallbackTrigger
[src]
fn trigger(&self) -> CallbackTrigger
[src]Return the callback trigger
fn selection_color(&mut self) -> Color
[src]
fn selection_color(&mut self) -> Color
[src]Gets the selection color of the widget
fn set_selection_color(&mut self, color: Color)
[src]
fn set_selection_color(&mut self, color: Color)
[src]Sets the selection color of the widget
fn do_callback(&mut self)
[src]
fn do_callback(&mut self)
[src]Runs the already registered callback
fn top_window(&self) -> Option<Box<dyn WindowExt>>
[src]
fn top_window(&self) -> Option<Box<dyn WindowExt>>
[src]Returns the topmost window holding the widget
fn takes_events(&self) -> bool
[src]
fn takes_events(&self) -> bool
[src]Checks whether a widget is capable of taking events
unsafe fn user_data(&self) -> Option<Box<dyn FnMut()>>
[src]
unsafe fn user_data(&self) -> Option<Box<dyn FnMut()>>
[src]INTERNAL: Retakes ownership of the user callback data Read more
fn set_visible_focus(&mut self)
[src]
fn set_visible_focus(&mut self)
[src]Set the widget to have visible focus
fn clear_visible_focus(&mut self)
[src]
fn clear_visible_focus(&mut self)
[src]Clear visible focus
fn visible_focus(&mut self, v: bool)
[src]
fn visible_focus(&mut self, v: bool)
[src]Set the visible focus using a flag
fn has_visible_focus(&mut self) -> bool
[src]
fn has_visible_focus(&mut self) -> bool
[src]Return whether the widget has visible focus
fn was_deleted(&self) -> bool
[src]
fn was_deleted(&self) -> bool
[src]Check if a widget was deleted
fn set_damage(&mut self, flag: bool)
[src]
fn set_damage(&mut self, flag: bool)
[src]Signal the widget as damaged and it should be redrawn in the next event loop cycle
fn damage_type(&self) -> Damage
[src]
fn damage_type(&self) -> Damage
[src]Return the damage mask
fn set_damage_type(&mut self, mask: Damage)
[src]
fn set_damage_type(&mut self, mask: Damage)
[src]Signal the type of damage a widget received
fn clear_damage(&mut self)
[src]
fn clear_damage(&mut self)
[src]Clear the damaged flag
fn as_window(&self) -> Option<Box<dyn WindowExt>>
[src]
fn as_window(&self) -> Option<Box<dyn WindowExt>>
[src]Return the widget as a window if it’s a window
fn as_group(&self) -> Option<Box<dyn GroupExt>>
[src]
fn as_group(&self) -> Option<Box<dyn GroupExt>>
[src]Return the widget as a group widget if it’s a group widget
fn below_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]
fn below_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]Positions the widget below w, the size of w should be known
fn above_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]
fn above_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]Positions the widget above w, the size of w should be known
fn right_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]
fn right_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]Positions the widget to the right of w, the size of w should be known
fn left_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]
fn left_of<W: WidgetExt>(self, w: &W, padding: i32) -> Self
[src]Positions the widget to the left of w, the size of w should be known
fn center_of<W: WidgetExt>(self, w: &W) -> Self
[src]
fn center_of<W: WidgetExt>(self, w: &W) -> Self
[src]Positions the widget to the center of w, the size of w should be known
fn center_of_parent(self) -> Self
[src]
fn center_of_parent(self) -> Self
[src]Positions the widget to the center of its parent
fn size_of<W: WidgetExt>(self, w: &W) -> Self
[src]
fn size_of<W: WidgetExt>(self, w: &W) -> Self
[src]Takes the size of w, the size of w should be known
fn size_of_parent(self) -> Self
[src]
fn size_of_parent(self) -> Self
[src]Takes the size of the parent group or window
fn inside<W: WidgetExt>(&self, wid: &W) -> bool
[src]
fn inside<W: WidgetExt>(&self, wid: &W) -> bool
[src]Checks whether the self widget is inside another widget
fn with_pos(self, x: i32, y: i32) -> Self
[src]
fn with_pos(self, x: i32, y: i32) -> Self
[src]Initialize to position x, y, (should only be called on initialization)
fn with_size(self, width: i32, height: i32) -> Self
[src]
fn with_size(self, width: i32, height: i32) -> Self
[src]Initialilze to dimensions width and height, (should only be called on initialization)
fn with_label(self, title: &str) -> Self
[src]
fn with_label(self, title: &str) -> Self
[src]Initialize with label/title, (should only be called on initialization)
fn with_align(self, align: Align) -> Self
[src]
fn with_align(self, align: Align) -> Self
[src]Sets the initial alignment of the widget, (should only be called on initialization)
fn get_type<T: WidgetType>(&self) -> T
[src]
fn get_type<T: WidgetType>(&self) -> T
[src]Returns the widget type when applicable
fn set_type<T: WidgetType>(&mut self, typ: T)
[src]
fn set_type<T: WidgetType>(&mut self, typ: T)
[src]Sets the widget type
fn set_deimage<I: ImageExt>(&mut self, image: Option<I>)
[src]
fn set_deimage<I: ImageExt>(&mut self, image: Option<I>)
[src]Sets the image of the widget
fn set_callback<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]
fn set_callback<F: FnMut(&mut Self) + 'static>(&mut self, cb: F)
[src]Sets the callback when the widget is triggered (clicks for example) takes the widget as a closure argument Read more
fn emit<T: 'static + Clone + Send + Sync>(&mut self, sender: Sender<T>, msg: T)
[src]
fn emit<T: 'static + Clone + Send + Sync>(&mut self, sender: Sender<T>, msg: T)
[src]Emits a message on callback using a sender
unsafe fn into_widget<W: WidgetBase>(&self) -> W where
Self: Sized,
[src]
unsafe fn into_widget<W: WidgetBase>(&self) -> W where
Self: Sized,
[src]Upcast a WidgetExt
to a Widget Read more
impl WindowExt for OverlayWindow
[src]
impl WindowExt for OverlayWindow
[src]fn center_screen(self) -> Self
[src]
fn center_screen(self) -> Self
[src]Positions the window to the center of the screen
fn make_modal(&mut self, val: bool)
[src]
fn make_modal(&mut self, val: bool)
[src]Makes a window modal, should be called before show
fn fullscreen(&mut self, val: bool)
[src]
fn fullscreen(&mut self, val: bool)
[src]Makes a window fullscreen
fn make_current(&mut self)
[src]
fn make_current(&mut self)
[src]Makes the window current
fn set_icon<T: ImageExt>(&mut self, image: Option<T>)
[src]
fn set_icon<T: ImageExt>(&mut self, image: Option<T>)
[src]Sets the windows icon. Supported formats are bmp, jpeg, png and rgb. Read more
fn set_cursor(&mut self, cursor: Cursor)
[src]
fn set_cursor(&mut self, cursor: Cursor)
[src]Sets the cursor style within the window. Needs to be called after the window is shown Read more
fn set_border(&mut self, flag: bool)
[src]
fn set_border(&mut self, flag: bool)
[src]Sets whether the window has a border
fn free_position(&mut self)
[src]
fn free_position(&mut self)
[src]Frees the position of the window
fn raw_handle(&self) -> RawHandle
[src]
fn raw_handle(&self) -> RawHandle
[src]Get the raw system handle of the window
unsafe fn set_raw_handle(&mut self, handle: RawHandle)
[src]
unsafe fn set_raw_handle(&mut self, handle: RawHandle)
[src]Set the window associated with a raw handle.
RawHandle
is a void pointer to: (Windows: HWND
, X11: Xid
(u64
), macOS: NSWindow
) Read more
unsafe fn set_region(&mut self, region: Region)
[src]
unsafe fn set_region(&mut self, region: Region)
[src]Set the graphical draw region of the window Read more
fn iconize(&mut self)
[src]
fn iconize(&mut self)
[src]Iconifies the window. You can tell that the window is iconized by checking that it’s shown and not visible Read more
fn fullscreen_active(&self) -> bool
[src]
fn fullscreen_active(&self) -> bool
[src]Returns whether the window is fullscreen or not
fn decorated_w(&self) -> i32
[src]
fn decorated_w(&self) -> i32
[src]Returns the decorated width
fn decorated_h(&self) -> i32
[src]
fn decorated_h(&self) -> i32
[src]Returns the decorated height
fn size_range(&mut self, min_w: i32, min_h: i32, max_w: i32, max_h: i32)
[src]
fn size_range(&mut self, min_w: i32, min_h: i32, max_w: i32, max_h: i32)
[src]Set the window’s minimum width, minimum height, max width and max height
fn set_shape<I: ImageExt>(&mut self, image: Option<I>)
[src]
fn set_shape<I: ImageExt>(&mut self, image: Option<I>)
[src]Set the shape of the window. Supported image formats are BMP, RGB and Pixmap. The window covers non-transparent/non-black shape of the image. The image must not be scaled(resized) beforehand. The size will be adapted to the window’s size Read more
fn set_cursor_image(&mut self, image: RgbImage, hot_x: i32, hot_y: i32)
[src]
fn set_cursor_image(&mut self, image: RgbImage, hot_x: i32, hot_y: i32)
[src]Set the cursor image
fn default_cursor(&mut self, cursor: Cursor)
[src]
fn default_cursor(&mut self, cursor: Cursor)
[src]Set the window’s default cursor
impl Send for OverlayWindow
[src]
impl Sync for OverlayWindow
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more