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

Spell-checking in command arguments #117

Open
pcdi opened this issue Jan 13, 2025 · 0 comments
Open

Spell-checking in command arguments #117

pcdi opened this issue Jan 13, 2025 · 0 comments
Assignees
Labels
1-feature-request ✨ Issue type: Request for a desirable, nice-to-have feature

Comments

@pcdi
Copy link

pcdi commented Jan 13, 2025

Is your feature request related to a problem? Please describe.
When using the integrated quotation commands from the csquotes package, certain command arguments contain regular text and should be spell-checked, while other arguments should not be spell-checked.
Currently, it is only possible to turn spell-checking on and off for commands as a whole, not for their respective arguments in isolation.

Example:

% Interface provided by csquotes:
\blockcquote[⟨prenote⟩][⟨postnote⟩]{⟨bib key⟩}[⟨punctuation⟩]{⟨quotation text⟩}
% Real life example:
\blockcquote[see also][27]{GreenhalghGoverningChinasPopulation}[.]{politically productive, working to constitute population, programs, politics, and power itself}

In this case, all arguments of \blockcquote are checked by LTeX.
Therefore, the bib key GreenhalghGoverningChinasPopulation is identified as a spelling mistake.

Currently it is only possible to ignore commands as a whole, that is all their arguments, via setting the option ltex.latex.commands to ignore.
However, since ⟨quotation text⟩ (as well as possibly ⟨prenote⟩ or ⟨postnote⟩) contain regular text and should therefore be spell-checked, it is not sensible to ignore the command with all its arguments.

Describe the solution you'd like
Be able to ignore individual arguments of commands.
In the above example, ignore the command name \blockcquote and {⟨bib key⟩}[⟨punctuation⟩] arguments, while spell-checking [⟨prenote⟩][⟨postnote⟩] and {⟨quotation text⟩}.

Describe alternatives you've considered
Setting the commands of csquotes to ignore.
While in this case, the bib keys are not spell-checked and thus do not appear as spelling mistakes, this has the disadvantage that the regular text in the other arguments is also not spell-checked whereas this would be desirable.

Additional context
N/A

@pcdi pcdi added the 1-feature-request ✨ Issue type: Request for a desirable, nice-to-have feature label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1-feature-request ✨ Issue type: Request for a desirable, nice-to-have feature
Projects
None yet
Development

No branches or pull requests

2 participants