Skip to content

Allow optional group and more than one mandatory argument in nospell commands#2118

Closed
tornaria wants to merge 2 commits intolervag:masterfrom
tornaria:nospell_commands
Closed

Allow optional group and more than one mandatory argument in nospell commands#2118
tornaria wants to merge 2 commits intolervag:masterfrom
tornaria:nospell_commands

Conversation

@tornaria
Copy link
Copy Markdown
Contributor

When a command is in g:vimtex_syntax_nospell_commands, its argument is excluded from spell checking; after the first patch this also works for commands with an optional argument.

After the second patch, a command in g:vimtex_syntax_nospell_commands can have more than one mandatory argument; spell check is disabled for all of them.

I use this for custom commands with optional arguments; also for some standard commands like \numberwithin (2 mandatory arguments).

Copy link
Copy Markdown
Owner

@lervag lervag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks. I don't see any reason not to accept this, except my minor comment.

tornaria added 2 commits July 27, 2021 13:07
When a command is in g:vimtex_syntax_nospell_commands,
its argument is excluded from spell checking; after this
patch this also works for commands with an optional argument.
After this patch, a command in g:vimtex_syntax_nospell_commands
can have more than one mandatory argument; spell check is
disabled for all of them.
@lervag
Copy link
Copy Markdown
Owner

lervag commented Jul 28, 2021

Thanks!

@lervag lervag closed this Jul 28, 2021
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.

2 participants