slint-ui/slint · error

not implemented

Error message

not implemented

What it means

When the Skia renderer runs on Vulkan, creating a surface matches the window's raw-window-handle against implemented pairs: Android, Wayland and Win32 are handled. Any other combination — X11, macOS AppKit, etc. — reaches `_ => unimplemented!()` and panics during surface creation, i.e. as soon as a window is shown.

Source

Thrown at internal/renderers/skia/vulkan_surface.rs:523

            }),
            raw_window_handle::RawDisplayHandle::Wayland(raw_window_handle::WaylandDisplayHandle {
                display,
                ..
            }),
        ) => unsafe {
            Surface::from_wayland(instance.clone(), display.as_ptr(), surface.as_ptr(), None)
        },
        (
            raw_window_handle::RawWindowHandle::Win32(raw_window_handle::Win32WindowHandle {
                hwnd,
                hinstance,
                ..
            }),
            _,
        ) => unsafe {
            Surface::from_win32(instance.clone(), hinstance.unwrap().get(), hwnd.get(), None)
        },
        _ => unimplemented!(),
    }
}

View on GitHub (pinned to a9ea814a58)

Solutions

  1. Don't select the Vulkan Skia renderer on X11/macOS — use the default femtovg/skia GL renderer.
  2. Run the app under a real Wayland session if the Vulkan path is required.
  3. Unset SLINT_RENDERER / remove the vulkan feature that forces this path.
  4. Longer term, contribute an X11 arm (Surface::from_xlib) upstream.

Example fix

# before
SLINT_RENDERER=skia-vulkan ./myapp   # on X11/macOS -> panic in vulkan_surface

# after
unset SLINT_RENDERER
./myapp                               # default GL renderer
Defensive patterns

Strategy: validation

Validate before calling

// Only allow the Vulkan Skia renderer on supported window systems, before slint::run_event_loop()
#[cfg(all(feature = "renderer-skia-vulkan", not(any(target_os = "android", target_os = "windows"))))]
{
    let is_wayland = std::env::var("WAYLAND_DISPLAY").is_ok();
    if !is_wayland {
        eprintln!("skia-vulkan requires Wayland/Win32/Android window handles; falling back to default renderer");
        std::env::remove_var("SLINT_RENDERER");
    }
}

Prevention

When it happens

Trigger: Enabling the Skia Vulkan path (renderer-skia built with the vulkan feature, or a SLINT_RENDERER selection resolving to skia-vulkan) on X11 or macOS, then creating/showing a window — the (RawWindowHandle, RawDisplayHandle) pair is not Wayland/Win32/Android so surface creation panics.

Common situations: Forcing Vulkan on an X11 desktop for performance testing; a renderer env var or feature set copied from Wayland docs; CI runners defaulting to X11 while the build hard-enables vulkan.

Related errors


AI-assisted analysis of slint-ui/slint@a9ea814a58 (2026-08-16). Data as JSON: /api/errors/2f527359a10ee28d. Report an issue: GitHub.