Cargo Features

[dependencies]
egui = { version = "0.29.1", default-features = false, features = ["accesskit", "bytemuck", "callstack", "cint", "color-hex", "deadlock_detection", "default_fonts", "log", "mint", "persistence", "puffin", "rayon", "serde", "unity", "document-features"] }
default = default_fonts

The default_fonts feature is set by default whenever egui is added without default-features = false somewhere in the dependency tree.

accesskit

Exposes detailed accessibility implementation required by platform accessibility APIs. Also requires support in the egui integration.

Enables accesskit ^0.16

### Optional dependencies

Affects output::PlatformOutput.accesskit_update, egui::accesskit_root_id, pass_state::AccessKitPassState, pass_state::PassState.accesskit_state, text_selection::accesskit_text

bytemuck

bytemuck enables you to cast epaint::Vertex, emath::Vec2 etc to &[u8].

Enables bytemuck of epaint

callstack

Show a debug-ui on hover including the stacktrace to the hovered item.
This is very useful in finding the code that creates a part of the UI.
Does not work on web.

Enables backtrace

cint

cint enables interoperability with other color libraries.

Enables cint of epaint

color-hex

Enable the hex_color macro.

Enables color-hex of epaint

deadlock_detection

This will automatically detect deadlocks due to double-locking on the same thread. If your app freezes, you may want to enable this! Only affects epaint::mutex::RwLock (which egui uses a lot).

Enables deadlock_detection of epaint

default_fonts default

If set, egui will use include_bytes! to bundle some fonts. If you plan on specifying your own fonts you may disable this feature.

Enables default_fonts of epaint

log

Turn on the log feature, that makes egui log some errors using the log crate.

Enables log, log of epaint

mint

mint enables interoperability with other math libraries such as glam and nalgebra.

Enables mint of epaint

persistence = ron, serde

Enable persistence of memory (window positions etc).

Enables serde of epaint

Affects id_type_map::SerializableAny

puffin

Enable profiling with the puffin crate.

Only enabled on native, because of the low resolution (1ms) of clocks in browsers.

Enables puffin, puffin of epaint

rayon

Enable parallel tessellation using rayon.

This can help performance for graphics-intense applications.

Enables rayon of epaint

serde persistence?

Allow serialization using serde.

Enables serde, serde of epaint and optional accesskit ^0.16

unity

Change Vertex layout to be compatible with unity

Enables unity of epaint

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

document-features implicit feature

Enables document-features

Enable this when generating docs.

ron persistence?