Skip to content

Doc tweaks / improvements #77

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
6 changes: 3 additions & 3 deletions convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ def convert_key(text, file):
}
}

/// Parse from string error, returned when string does not match to any Key variant.
/// Parse from string error, returned when string does not match to any [`NamedKey`] variant.
#[derive(Clone, Debug)]
pub struct UnrecognizedNamedKeyError;

Expand Down Expand Up @@ -198,7 +198,7 @@ def convert_code(text, file):
/// Code is the physical position of a key.
///
/// The names are based on the US keyboard. If the key
/// is not present on US keyboards a name from another
/// is not present on US keyboards, a name from another
/// layout is used.
///
/// Specification:
Expand Down Expand Up @@ -298,7 +298,7 @@ def convert_code(text, file):
}
}

/// Parse from string error, returned when string does not match to any Code variant.
/// Parse from string error, returned when string does not match to any [`Code`] variant.
#[derive(Clone, Debug)]
pub struct UnrecognizedCodeError;

Expand Down
4 changes: 2 additions & 2 deletions src/code.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use std::error::Error;
/// Code is the physical position of a key.
///
/// The names are based on the US keyboard. If the key
/// is not present on US keyboards a name from another
/// is not present on US keyboards, a name from another
/// layout is used.
///
/// Specification:
Expand Down Expand Up @@ -941,7 +941,7 @@ impl FromStr for Code {
}
}

/// Parse from string error, returned when string does not match to any Code variant.
/// Parse from string error, returned when string does not match to any [`Code`] variant.
#[derive(Clone, Debug)]
pub struct UnrecognizedCodeError;

Expand Down
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ impl CompositionState {
/// dead key combinations and IMEs.
///
/// A composition session is always started by a [`CompositionState::Start`]
/// event followed my zero or more [`CompositionState::Update`] events
/// event followed by zero or more [`CompositionState::Update`] events
/// and terminated by a single [`CompositionState::End`] event.
#[derive(Clone, Debug, Eq, Hash, PartialEq, PartialOrd, Ord)]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
Expand All @@ -171,7 +171,7 @@ pub enum Key {
Named(NamedKey),
}

/// Parse from string error, returned when string does not match to any Key variant.
/// Parse from string error, returned when string does not match to any [`Key`] variant.
#[derive(Clone, Debug)]
pub struct UnrecognizedKeyError;

Expand Down
2 changes: 1 addition & 1 deletion src/named_key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1307,7 +1307,7 @@ impl FromStr for NamedKey {
}
}

/// Parse from string error, returned when string does not match to any Key variant.
/// Parse from string error, returned when string does not match to any [`NamedKey`] variant.
#[derive(Clone, Debug)]
pub struct UnrecognizedNamedKeyError;

Expand Down
2 changes: 1 addition & 1 deletion src/shortcuts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ impl<T> ShortcutMatcher<T> {

/// Test a keyboard shortcut.
///
/// If the modifiers are active and the key is pressed
/// If the modifiers are active and the key is pressed,
/// execute the provided function.
///
/// ```rust
Expand Down