-
Notifications
You must be signed in to change notification settings - Fork 265
Upgrade from 0.13 to 0.14
Zrzka edited this page Nov 15, 2019
·
19 revisions
- Removed
cursor
,style
,terminal
andscreen
feature flags- All the functionality is included by default and there's no way how to disable it
- Removed
input
feature flag- Replaced with the
event
feature flag, more on this below
- Replaced with the
- New feature flag
event
- Enables
event
module and allows you to handle events like key input, mouse input and terminal resize
- Enables
- New feature flag
async-event
- Auto enables
event
feature and providesEventStream
(futures::Stream
) on top of theevent
module
- Auto enables
We believe that there are two main use cases:
- you want to style your output only (default features) or
- you want to style your output and handle events (
event
feature).
Default features includes all the styling functions and it simplifies the crate usage for you
(no need to specify features). Separate event
feature allows you to add support for
event handling. It's provided as a separate feature because it brings additional dependencies
like bitflags
, parking_lot
and mio
. If you do not want to use event handling, there's no
reason to fetch & compile them for you.
But why the async-event
feature? Not everyone wants to use async stuff and it also brings
additional features
crate dependency. Basically same reasons as for the event
feature.
This whole module was removed. To be more precise, replace with the brand new
event
module.
- Change of Event enums to Structs
- Support for modifiers, bitwise, bitflag
- Supported for more events
- Rename of certain events
- poll/read api
- Async Support
- links to places for help, examples, discord.