diff --git a/CHANGELOG.md b/CHANGELOG.md index 9cd58498b..4c7b234ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,14 @@ +# Version 0.24.0 +- Add DoubleUnderlined, Undercurled, Underdots the text, Underdotted, Underdashes, Underdashed attributes and allow coloring their foreground / background color. +- Fix windows unicode character parsing, this fixed various key combinations and support typing unicode characters. +- Consistency and better documentation on mouse cursor operations (BREAKING CHANGE). + - MoveTo, MoveToColumn, MoveToRow are 0-based. (left top most cell is 0,0). Moving like this is absolute + - MoveToNextLine, MoveToPreviousLine, MoveUp, MoveDown, MoveRight, MoveLeft are 1-based,. Moving like this is relative. Moving 1 left means moving 1 left. Moving 0 to the left is not possible, wikipedia states that most terminals will just default to 1. +- terminal::size returns error when previously it returned (0,0). +- Remove println from serialisation code. +- Fix mouse up for middle and right buttons. +- Fix escape codes on Git-Bash + Windows Terminal / Alacritty / WezTerm. +- Add support for cursor keys in application mode. # Version 0.23.2 - Update signal-hook and mio to version 0.8. diff --git a/Cargo.toml b/Cargo.toml index bc1c8b407..0893b0304 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "crossterm" -version = "0.23.2" +version = "0.24.0" authors = ["T. Post"] description = "A crossplatform terminal library for manipulating terminals." repository = "https://github.com/crossterm-rs/crossterm" diff --git a/examples/interactive-demo/src/test/attribute.rs b/examples/interactive-demo/src/test/attribute.rs index 8c5de8eda..a9ea17ce3 100644 --- a/examples/interactive-demo/src/test/attribute.rs +++ b/examples/interactive-demo/src/test/attribute.rs @@ -4,10 +4,11 @@ use crate::Result; use crossterm::{cursor, queue, style}; use std::io::Write; -const ATTRIBUTES: [(style::Attribute, style::Attribute); 6] = [ +const ATTRIBUTES: [(style::Attribute, style::Attribute); 10] = [ (style::Attribute::Bold, style::Attribute::NormalIntensity), (style::Attribute::Italic, style::Attribute::NoItalic), (style::Attribute::Underlined, style::Attribute::NoUnderline), + (style::Attribute::DoubleUnderlined, style::Attribute::NoUnderline), (style::Attribute::Undercurled, style::Attribute::NoUnderline), (style::Attribute::Underdotted, style::Attribute::NoUnderline), diff --git a/examples/is_tty.rs b/examples/is_tty.rs index e6c7d01c5..628d9a73f 100644 --- a/examples/is_tty.rs +++ b/examples/is_tty.rs @@ -1,4 +1,8 @@ -use crossterm::{tty::IsTty, terminal::{size, SetSize}, execute}; +use crossterm::{ + execute, + terminal::{size, SetSize}, + tty::IsTty, +}; use std::io::{stdin, stdout}; pub fn main() { diff --git a/src/event/sys/unix/parse.rs b/src/event/sys/unix/parse.rs index 6910361d4..37bf54c3b 100644 --- a/src/event/sys/unix/parse.rs +++ b/src/event/sys/unix/parse.rs @@ -44,12 +44,24 @@ pub(crate) fn parse_event(buffer: &[u8], input_available: bool) -> Result