@@ -906,7 +906,7 @@ impl Grid {
906
906
mut new_cursor_y,
907
907
mut saved_cursor_y_coordinates,
908
908
new_cursor_x,
909
- saved_cursor_x_coordinates
909
+ saved_cursor_x_coordinates,
910
910
) = cursors;
911
911
912
912
let current_viewport_row_count = self . viewport . len ( ) ;
@@ -2144,7 +2144,8 @@ impl Perform for Grid {
2144
2144
fn print ( & mut self , c : char ) {
2145
2145
let c = self . cursor . charsets [ self . active_charset ] . map ( c) ;
2146
2146
2147
- let terminal_character = TerminalCharacter :: new_styled ( c, self . cursor . pending_styles . clone ( ) ) ;
2147
+ let terminal_character =
2148
+ TerminalCharacter :: new_styled ( c, self . cursor . pending_styles . clone ( ) ) ;
2148
2149
self . set_preceding_character ( terminal_character. clone ( ) ) ;
2149
2150
self . add_character ( terminal_character) ;
2150
2151
}
@@ -2443,9 +2444,7 @@ impl Perform for Grid {
2443
2444
if intermediates. is_empty ( ) {
2444
2445
self . cursor
2445
2446
. pending_styles
2446
- . update ( |styles| {
2447
- styles. add_style_from_ansi_params ( & mut params_iter)
2448
- } )
2447
+ . update ( |styles| styles. add_style_from_ansi_params ( & mut params_iter) )
2449
2448
}
2450
2449
} else if c == 'C' || c == 'a' {
2451
2450
// move cursor forward
@@ -2456,9 +2455,9 @@ impl Perform for Grid {
2456
2455
if let Some ( clear_type) = params_iter. next ( ) . map ( |param| param[ 0 ] ) {
2457
2456
let mut char_to_replace = EMPTY_TERMINAL_CHARACTER ;
2458
2457
if let Some ( background_color) = self . cursor . pending_styles . background {
2459
- char_to_replace. styles . update ( |styles| {
2460
- styles . background = Some ( background_color )
2461
- } ) ;
2458
+ char_to_replace
2459
+ . styles
2460
+ . update ( |styles| styles . background = Some ( background_color ) ) ;
2462
2461
}
2463
2462
if clear_type == 0 {
2464
2463
self . replace_characters_in_line_after_cursor ( char_to_replace) ;
@@ -2472,9 +2471,9 @@ impl Perform for Grid {
2472
2471
// clear all (0 => below, 1 => above, 2 => all, 3 => saved)
2473
2472
let mut char_to_replace = EMPTY_TERMINAL_CHARACTER ;
2474
2473
if let Some ( background_color) = self . cursor . pending_styles . background {
2475
- char_to_replace. styles . update ( |styles| {
2476
- styles . background = Some ( background_color )
2477
- } ) ;
2474
+ char_to_replace
2475
+ . styles
2476
+ . update ( |styles| styles . background = Some ( background_color ) ) ;
2478
2477
}
2479
2478
if let Some ( clear_type) = params_iter. next ( ) . map ( |param| param[ 0 ] ) {
2480
2479
if clear_type == 0 {
0 commit comments