pub struct StyleMask(/* private fields */);
Expand description
Window style mask builder for NSPanel
Allows combining multiple style masks using the builder pattern. Style masks control the appearance and behavior of the window frame.
§Example
use tauri_nspanel::{StyleMask, PanelBuilder};
// Create a borderless panel that doesn't activate the app
let style = StyleMask::new()
.borderless()
.nonactivating_panel();
// Use with PanelBuilder
PanelBuilder::new(&app, "my-panel")
.style_mask(style)
.build();
Implementations§
Source§impl StyleMask
impl StyleMask
Sourcepub fn new() -> Self
pub fn new() -> Self
Create with default style mask (Titled | Closable | Miniaturizable | Resizable)
Sourcepub fn miniaturizable(self) -> Self
pub fn miniaturizable(self) -> Self
Window has a minimize button
Sourcepub fn unified_title_and_toolbar(self) -> Self
pub fn unified_title_and_toolbar(self) -> Self
Window uses unified title and toolbar
Sourcepub fn full_size_content_view(self) -> Self
pub fn full_size_content_view(self) -> Self
Window uses full size content view
Sourcepub fn utility_window(self) -> Self
pub fn utility_window(self) -> Self
Window is a utility window
Sourcepub fn hud_window(self) -> Self
pub fn hud_window(self) -> Self
Window is a HUD window
Sourcepub fn nonactivating_panel(self) -> Self
pub fn nonactivating_panel(self) -> Self
Window is a non-activating panel
Sourcepub fn borderless(self) -> Self
pub fn borderless(self) -> Self
Window has no title bar or border
Sourcepub fn from_raw(flags: NSWindowStyleMask) -> Self
pub fn from_raw(flags: NSWindowStyleMask) -> Self
Create from raw NSWindowStyleMask flags
Sourcepub fn value(&self) -> NSWindowStyleMask
pub fn value(&self) -> NSWindowStyleMask
Get the raw NSWindowStyleMask flags
Trait Implementations§
Source§impl From<NSWindowStyleMask> for StyleMask
impl From<NSWindowStyleMask> for StyleMask
Source§fn from(value: NSWindowStyleMask) -> Self
fn from(value: NSWindowStyleMask) -> Self
Converts to this type from the input type.
Source§impl From<StyleMask> for NSWindowStyleMask
impl From<StyleMask> for NSWindowStyleMask
impl Copy for StyleMask
impl StructuralPartialEq for StyleMask
Auto Trait Implementations§
impl Freeze for StyleMask
impl RefUnwindSafe for StyleMask
impl Send for StyleMask
impl Sync for StyleMask
impl Unpin for StyleMask
impl UnwindSafe for StyleMask
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