Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.21 #596

Merged
merged 2 commits into from
Aug 23, 2021
Merged

0.21 #596

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# Version 0.21
- Expose `is_raw` function.
- Add 'purge' option on unix system, this clears the entire screen buffer.
- Improve serialisation for color enum values.

# Version 0.20
- Update from signal-hook with 'mio-feature flag' to signal-hook-mio 0.2.1.
- Manually implements Eq, PartialEq and Hash for KeyEvent improving equality checks and hash calculation.
Expand Down
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "crossterm"
version = "0.20.0"
version = "0.21.0"
authors = ["T. Post"]
description = "A crossplatform terminal library for manipulating terminals."
repository = "https://github.com/crossterm-rs/crossterm"
Expand Down
2 changes: 1 addition & 1 deletion src/event/read.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ impl InternalEventReader {
F: Filter,
{
for event in &self.events {
if filter.eval(&event) {
if filter.eval(event) {
return Ok(true);
}
}
Expand Down
3 changes: 3 additions & 0 deletions src/terminal/sys/windows.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ pub(crate) fn clear(clear_type: ClearType) -> Result<()> {
ClearType::FromCursorUp => clear_before_cursor(pos, buffer_size, current_attribute)?,
ClearType::CurrentLine => clear_current_line(pos, buffer_size, current_attribute)?,
ClearType::UntilNewLine => clear_until_line(pos, buffer_size, current_attribute)?,
_ => {
clear_entire_screen(buffer_size, current_attribute)?;
} //TODO: make purge flush the entire screen buffer not just the visible window.
};
Ok(())
}
Expand Down