Skip to content
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

feat: Hide spelling issues while typing. #3233

Merged
merged 2 commits into from May 6, 2024
Merged

feat: Hide spelling issues while typing. #3233

merged 2 commits into from May 6, 2024

Conversation

Jason3S
Copy link
Collaborator

@Jason3S Jason3S commented May 6, 2024

Because of the custom decorators in v4, it is possible to control when issues are displayed.

v4 comes with a command to show/hide issues. This is different than the enable/disable command. That command turns the spell checker on/off, almost like shutting it down and restarting it.

Added a couple of settings:

export interface SpellCheckerBehaviorSettings {
    /**
     * Control how spelling issues are displayed while typing.
     * See: `#cSpell.revealIssuesAfterMS#` to control when issues are revealed.
     * @title Hide Issues While Typing
     * @scope machine
     * @since 4.0.0
     * @default "Word"
     * @enumDescriptions [
     *  "Show issues while typing",
     *  "Hide issues in the current word",
     *  "Hide issues on the line",
     *  "Hide all issues in the document"]
     */
    hideIssuesWhileTyping?: 'Off' | 'Word' | 'Line' | 'Document';

    /**
     * Reveal hidden issues related to `#cSpell.hideIssuesWhileTyping#` after a delay in milliseconds.
     * @title Reveal Issues After a Delay in Milliseconds
     * @scope machine
     * @since 4.0.0
     * @default 1500
     * @enumDescriptions [
     *  "Show issues while typing",
     *  "Hide issues in the current word",
     *  "Hide issues on the line",
     *  "Hide all issues in the document"]
     */
    revealIssuesAfterDelayMS?: number;
}

@Jason3S Jason3S marked this pull request as ready for review May 6, 2024 18:54
@Jason3S Jason3S merged commit fbd5134 into main May 6, 2024
16 checks passed
@Jason3S Jason3S deleted the dev-statusbar branch May 6, 2024 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Trigger check after adding/ignoring word Don't check ongoing word
1 participant