README.md

January 31, 2024 ยท View on GitHub

Egui file browser

Example app showing how to pick a file on both web and desktop.

The web application can be accessed here:

https://woelper.github.io/egui_pick_file/

For native:

On linux install dependencies of rfd as applicable. Copied from https://docs.rs/rfd/latest/rfd/#linux--bsd-backends

GTK backend is used with the gtk3 Cargo feature which is enabled by default. The GTK3 backend requires the C library and development headers to be installed to build RFD. The package names on various distributions are:

DistributionInstallation Command
Fedoradnf install gtk3-devel
Archpacman -S gtk3
Debian & Ubuntuapt install libgtk-3-dev

cargo run

For web:

rustup target add wasm32-unknown-unknown

cargo install --locked trunk

trunk serve --open

There is also an alternate example implementation that uses poll-promise instead available herehttps://github.com/c-git/egui_file_picker_poll_promise.