fn refresh_screen(&self) -> Result<(), std::io::Error> {
		Terminal::cursor_hide();
		Terminal::cursor_position(&Position::default());

		if self.should_quit {
			println!("Goodbye.\r");
			Terminal::clear_screen();
		} else {
			self.draw_rows();
			self.draw_status_bar();
			self.draw_message_bar();
			Terminal::cursor_position(&Position {
				x: self.cursor_position.x.saturating_sub(self.offset.x),
				y: self.cursor_position.y.saturating_sub(self.offset.y),
			});
		}

		Terminal::cursor_show();
		Terminal::flush()
	}
/*
		Refresh with redraw or exit message
	*/
Refresh with redraw or exit message
Refresh with redraw or exit message
fn refresh_screen(&self) -> Result<(), std::io::Error> {
		Terminal::cursor_hide();
		Terminal::cursor_position(&Position::default());
		if self.should_quit {
			println!("Goodbye.\r");
			Terminal::clear_screen();
		} else {
			self.draw_rows();
			self.draw_status_bar();
			self.draw_message_bar();
			Terminal::cursor_position(&Position {
				x: self.cursor_position.x.saturating_sub(self.offset.x),
				y: self.cursor_position.y.saturating_sub(self.offset.y),
			});
		}
		Terminal::cursor_show();
		Terminal::flush()
	}
fn refresh_screen ( & self ) -> Result < ( ) , std :: io :: Error > { Terminal :: cursor_hide ( ) ; Terminal :: cursor_position ( & Position :: default ( ) ) ; if self . should_quit { println ! ( " \r " ) ; Terminal :: clear_screen ( ) ; } else { self . draw_rows ( ) ; self . draw_status_bar ( ) ; self . draw_message_bar ( ) ; Terminal :: cursor_position ( & Position { x : self . cursor_position . x . saturating_sub ( self . offset . x ) , y : self . cursor_position . y . saturating_sub ( self . offset . y ) , } ) ; } Terminal :: cursor_show ( ) ; Terminal :: flush ( ) }
Refresh with redraw or exit message
Refresh with redraw or exit message
&self
&self