Cargo Features

[dependencies]
crossterm = { version = "0.29.0", default-features = false, features = ["bracketed-paste", "events", "windows", "event-stream", "serde", "use-dev-tty", "derive-more", "osc52", "libc"] }
default = bracketed-paste, derive-more, events, windows

These default features are set whenever crossterm is added without default-features = false somewhere in the dependency tree.

bracketed-paste default

Default features

Enables triggering Event::Paste when pasting text into the terminal.

Affects event::EnableBracketedPaste, event::DisableBracketedPaste

events default event-stream?

Enables reading input/events from the system using the event module.

Enables mio, signal-hook, and signal-hook-mio

Affects event::EnableMouseCapture, crossterm::event, unix::supports_keyboard_enhancement, unix::query_keyboard_enhancement_flags, windows::supports_keyboard_enhancement

windows default

Enables windows specific crates.

Enables crossterm_winapi and winapi

event-stream = events

Optional Features

Enables the EventStream struct for async event reading.

Enables futures-core

serde

Enables serde for various types.

Enables serde, serde of bitflags

use-dev-tty = filedescriptor

Enables raw file descriptor polling / selecting instead of mio.

Enables process of rustix

derive-more default

Enables is_* helper functions for event enums.

Enables derive_more

osc52

Enables interacting with a host clipboard via clipboard

Enables base64

Affects crossterm::clipboard

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.

libc unix implicit feature

Enables libc

libc:

Raw FFI bindings to platform libraries like libc

Affects file_descriptor::FileDesc, file_descriptor::tty_fd

filedescriptor unix use-dev-tty?