Crate raw_window_handle
Expand description
Interoperability library for Rust Windowing applications.
This library provides standard types for accessing a window’s platform-specific raw window handle and platforms display handle. This does not provide any utilities for creating and managing windows; instead, it provides a common interface that window creation libraries (e.g. Winit, SDL) can use to easily talk with graphics libraries (e.g. gfx-hal).
§Safety guarantees
Please see the docs of HasWindowHandle
and HasDisplayHandle
.
§Platform handle initialization
Each platform handle struct is purposefully non-exhaustive, so that additional fields may be
added without breaking backwards compatibility. Each struct provides an empty
method that may
be used along with the struct update syntax to construct it. See each specific struct for
examples.
§Display Handles
Some windowing systems use a separate display handle for some operations. The display usually
represents a connection to some display server, but it is not necessarily tied to a particular
window. See RawDisplayHandle
for more details.
Structs§
- Android
Display Handle - Raw display handle for Android.
- Android
NdkWindow Handle - Raw window handle for Android NDK.
- AppKit
Display Handle - Raw display handle for AppKit.
- AppKit
Window Handle - Raw window handle for AppKit.
- Display
Handle - The handle to the display controller of the windowing system.
- DrmDisplay
Handle - Raw display handle for the Linux Kernel Mode Set/Direct Rendering Manager.
- DrmWindow
Handle - Raw window handle for the Linux Kernel Mode Set/Direct Rendering Manager.
- GbmDisplay
Handle - Raw display handle for the Linux Generic Buffer Manager.
- GbmWindow
Handle - Raw window handle for the Linux Generic Buffer Manager.
- Haiku
Display Handle - Raw display handle for Haiku.
- Haiku
Window Handle - Raw window handle for Haiku.
- Ohos
Display Handle - Raw display handle for OpenHarmony.
- Ohos
NdkWindow Handle - Raw window handle for Ohos NDK.
- Orbital
Display Handle - Raw display handle for the Redox operating system.
- Orbital
Window Handle - Raw window handle for the Redox operating system.
- UiKit
Display Handle - Raw display handle for UIKit.
- UiKit
Window Handle - Raw window handle for UIKit.
- Wayland
Display Handle - Raw display handle for Wayland.
- Wayland
Window Handle - Raw window handle for Wayland.
- WebCanvas
Window Handle - Raw window handle for a Web canvas registered via
wasm-bindgen
. - WebDisplay
Handle - Raw display handle for the Web.
- WebOffscreen
Canvas Window Handle - Raw window handle for a Web offscreen canvas registered via
wasm-bindgen
. - WebWindow
Handle - Raw window handle for the Web.
- Win32
Window Handle - Raw window handle for Win32.
- WinRt
Window Handle - Raw window handle for WinRT.
- Window
Handle - The handle to a window.
- Windows
Display Handle - Raw display handle for Windows.
- XcbDisplay
Handle - Raw display handle for Xcb.
- XcbWindow
Handle - Raw window handle for Xcb.
- Xlib
Display Handle - Raw display handle for Xlib.
- Xlib
Window Handle - Raw window handle for Xlib.
Enums§
- Handle
Error - An error that can occur while fetching a display or window handle.
- RawDisplay
Handle - A display server handle for a particular windowing system.
- RawWindow
Handle - A window handle for a particular windowing system.
Traits§
- HasDisplay
Handle - A display that acts as a wrapper around a display handle.
- HasRaw
Display Handle Deprecated - Display that wraps around a raw display handle.
- HasRaw
Window Handle Deprecated - Window that wraps around a raw window handle.
- HasWindow
Handle - A handle to a window.