Crate egui_window_glfw_passthrough

Source
Expand description

This crate uses glfw-passthrough crate as a window backend for egui.

Re-exports§

pub use glfw;

Structs§

GlfwBackend
This is the window backend for egui using glfw You can configure most of it at startup using GlfwConfig.
GlfwConfig
The configuration struct for Glfw Backend creation

Functions§

egui_to_glfw_cursor
This converts egui’s cursor icon into glfw’s cursor which can be set by glfw. we can get some sample cursor images and use them in place of missing icons (like diagonal resizing cursor)
emscripten_cancel_main_loop
emscripten_get_device_pixel_ratio
emscripten_get_element_css_size
emscripten_run_script_int
emscripten_set_element_css_size
emscripten_set_main_loop
glfw_to_egui_action
will return true if pressed, false if released and None if repeat this allows us to use unwrap_or_default to get pressed as false when we get a key repeat event
glfw_to_egui_modifers
glfw_to_egui_pointer_button
layout_based_glfw_to_egui_key
glfw separates keys into two categories.
layout_independent_glfw_to_egui_key
a function to get the matching egui key event for a given glfw key. egui does not support all the keys provided here. This just matches the enum to map to the relevant egui key.
set_main_loop_callback

Type Aliases§

GlfwCallback
Signature of Glfw callback function inside GlfwConfig
WindowCallback
This is the signature for window callback inside new function of GlfwBackend