Skip to main content

capture_window

Function capture_window 

Source
pub unsafe fn capture_window(
    window: *mut c_void,
    width: u32,
    height: u32,
) -> Rendered
Expand description

Capture a window including its titlebar, at width x height.

The titlebar is drawn by the window’s frame view, the private superview of the content view. Capturing that is the only way to see a .toolbar from a test.

§Safety

window must be a live NSWindow.