API ReferencePlatform & Testing
Window Events & State
Lifecycle, operations, icons, limits, and fullscreen policy.
WindowLifecycle (native per-window): Creating / Visible / Hidden /
Focused / Unfocused / Closing / Closed — independent of the app
lifecycle. WindowEventKind: Platform / Lifecycle / RedrawRequested /
StateChanged.
WindowOperation enumerates every data-only UI-thread op (set title,
visibility, size, drag/resize, minimize/maximize/fullscreen, decorations,
cursor, focus, close). WindowRequestedState tracks app-requested
visible/minimized/maximized/fullscreen/resizable/decorations/
limits/level, distinct from observed state.
use incular::prelude::*;
fn main() {
let icon = WindowIcon::from_rgba(vec![255u8; 64], 4, 4).expect("icon");
println!("icon: {}x{}", icon.width(), icon.height());
let limits = LogicalSizeLimits::new(None, None).expect("limits");
println!("has max: {}", limits.maximum().is_some());
}
Related: [`WindowHandle`](/docs/api/application/window),
[`Displays`](/docs/api/platform/displays).