Skip to content

Commit b892409

Browse files
waywardmonkeysdjc
authored andcommitted
Fix some typos
1 parent f6cd73f commit b892409

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ term.clear_line()?;
3838

3939
## Colors and Styles
4040

41-
`console` automaticaly detects when to use colors based on the tty flag. It also
41+
`console` automatically detects when to use colors based on the tty flag. It also
4242
provides higher level wrappers for styling text and other things that can be
4343
displayed with the `style` function and utility types.
4444

examples/cursor_at.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ use console::{style, Term};
88

99
fn write_chars() -> io::Result<()> {
1010
let term = Term::stdout();
11-
let (heigth, width) = term.size();
11+
let (height, width) = term.size();
1212
for x in 0..width {
13-
for y in 0..heigth {
13+
for y in 0..height {
1414
term.move_cursor_to(x as usize, y as usize)?;
1515
let text = if (x + y) % 2 == 0 {
1616
format!("{}", style(x % 10).black().on_red())

src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
//!
3434
//! # Colors and Styles
3535
//!
36-
//! `console` automaticaly detects when to use colors based on the tty flag. It also
36+
//! `console` automatically detects when to use colors based on the tty flag. It also
3737
//! provides higher level wrappers for styling text and other things that can be
3838
//! displayed with the `style` function and utility types.
3939
//!
@@ -56,7 +56,7 @@
5656
//!
5757
//! # Working with ANSI Codes
5858
//!
59-
//! The crate provids the function `strip_ansi_codes` to remove ANSI codes
59+
//! The crate provides the function `strip_ansi_codes` to remove ANSI codes
6060
//! from a string as well as `measure_text_width` to calculate the width of a
6161
//! string as it would be displayed by the terminal. Both of those together
6262
//! are useful for more complex formatting.

src/unix_term.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -323,7 +323,7 @@ pub fn read_single_key(ctrlc_key: bool) -> io::Result<Key> {
323323
let rv: io::Result<Key> = read_single_key_impl(fd);
324324
c_result(|| unsafe { libc::tcsetattr(fd, libc::TCSADRAIN, &original) })?;
325325

326-
// if the user hit ^C we want to signal SIGINT to outselves.
326+
// if the user hit ^C we want to signal SIGINT to ourselves.
327327
if let Err(ref err) = rv {
328328
if err.kind() == io::ErrorKind::Interrupted {
329329
if !ctrlc_key {

src/windows_term/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ pub fn read_single_key(_ctrlc_key: bool) -> io::Result<Key> {
402402
// Confirm that there is a next character to read.
403403
if get_key_event_count()? == 0 {
404404
let message = format!(
405-
"Read invlid utf16 {}: {}",
405+
"Read invalid utf16 {}: {}",
406406
unicode_char,
407407
Utf16TupleError::MissingSecond
408408
);

0 commit comments

Comments
 (0)