Trait winit::platform::unix::WindowBuilderExtUnix
source · pub trait WindowBuilderExtUnix {
// Required methods
fn with_name(
self,
general: impl Into<String>,
instance: impl Into<String>
) -> Self;
fn with_skip_taskbar(self, skip: bool) -> WindowBuilder;
fn with_transient_for(self, parent: &impl IsA<Window>) -> WindowBuilder;
fn with_transparent_draw(self, draw: bool) -> WindowBuilder;
fn with_double_buffered(self, double_buffered: bool) -> WindowBuilder;
fn with_rgba_visual(self, rgba_visual: bool) -> WindowBuilder;
fn with_app_paintable(self, app_paintable: bool) -> WindowBuilder;
fn with_default_vbox(self, add: bool) -> WindowBuilder;
}
x11_platform
or wayland_platform
only.Required Methods§
sourcefn with_name(
self,
general: impl Into<String>,
instance: impl Into<String>
) -> Self
fn with_name( self, general: impl Into<String>, instance: impl Into<String> ) -> Self
Build window with the given general
and instance
names.
The general
sets general class of WM_CLASS(STRING)
, while instance
set the
instance part of it. The resulted property looks like WM_CLASS(STRING) = "general", "instance"
.
For details about application ID conventions, see the Desktop Entry Spec
sourcefn with_skip_taskbar(self, skip: bool) -> WindowBuilder
fn with_skip_taskbar(self, skip: bool) -> WindowBuilder
Whether to create the window icon with the taskbar icon or not.
sourcefn with_transient_for(self, parent: &impl IsA<Window>) -> WindowBuilder
fn with_transient_for(self, parent: &impl IsA<Window>) -> WindowBuilder
Set this window as a transient dialog for parent
https://gtk-rs.org/gtk3-rs/stable/latest/docs/gdk/struct.Window.html#method.set_transient_for
sourcefn with_transparent_draw(self, draw: bool) -> WindowBuilder
fn with_transparent_draw(self, draw: bool) -> WindowBuilder
Whether to enable or disable the internal draw for transparent window.
When tranparent attribute is enabled, we will call connect_draw
and draw a transparent background.
For anyone who wants to draw the background themselves, set this to false
.
Default is true
.
sourcefn with_double_buffered(self, double_buffered: bool) -> WindowBuilder
fn with_double_buffered(self, double_buffered: bool) -> WindowBuilder
Whether to enable or disable the double buffered rendering of the window.
Default is true
.
sourcefn with_rgba_visual(self, rgba_visual: bool) -> WindowBuilder
fn with_rgba_visual(self, rgba_visual: bool) -> WindowBuilder
Whether to enable the rgba visual for the window.
Default is false
but is always true
if WindowAttributes::transparent
is true
sourcefn with_app_paintable(self, app_paintable: bool) -> WindowBuilder
fn with_app_paintable(self, app_paintable: bool) -> WindowBuilder
Wether to set this window as app paintable
https://docs.gtk.org/gtk3/method.Widget.set_app_paintable.html
Default is false
but is always true
if WindowAttributes::transparent
is true
sourcefn with_default_vbox(self, add: bool) -> WindowBuilder
fn with_default_vbox(self, add: bool) -> WindowBuilder
Whether to create a vertical gtk::Box
and add it as the sole child of this window.
Created by default.