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

Support for "ltex.latex.commands" where the argument is a separate sentence. #254

Closed
flindeberg opened this issue Feb 15, 2021 · 3 comments
Labels
1-feature-request ✨ Issue type: Request for a desirable, nice-to-have feature 3-duplicate Issue resolution: Issue has been submitted before

Comments

@flindeberg
Copy link

Is your feature request related to a problem? Please describe.

I am writing a semi-technical larger text, an interdisciplinary PhD-thesis, in which I need to use a scattering amount of footnotes to make the text legible to readers from different disciplines.

Footnotes, i.e. \footnote{}, do not currently work with spell checking in a good way. Either you have to select ignore and completely ignore to spellcheck the contents of the footnote, or use default which incorporates it into the sentence structure. Neither is optimal.

Describe the solution you'd like

I'd like there to be an option to check the argument separately from the sentence the macro belongs to.

For example:

For \gls{routing}-related\footnote{That is issues pertaining to \gls{numbering} and unique identifiers, but completely separate from the \gls{dns}-system.} issues the following propositions hold:

would be nice to have checked as:

For dummy0-related issues the following propositions hold:

That is issues pertaining to dummy1 and unique identifiers, but completely separate from the dummy2-system.

Right now I get one "spelling request" with either "dummy" (also note the problem of the extra period):

For dummy0-related That is issues pertaining to dummy1 and unique identifiers, but completely separate from the dummy2-system. issues the following propositions hold:

or "ignore":

For dummy0-related issues the following propositions hold:

Neither are perfect, and come with their own issues.

Describe alternatives you've considered

I have tried workarounds, such as putting the content of the footnote in a macro to have it checked separately (and ignore set for footnote), but it is not really up to par with checking them separately.

@flindeberg flindeberg added the 1-feature-request ✨ Issue type: Request for a desirable, nice-to-have feature label Feb 15, 2021
@valentjn
Copy link
Owner

valentjn commented Feb 15, 2021

Footnote are already checked separately, as well as \todo{...} notes. So as a feature request, this would be a duplicate of #42.

For your example, I get zero diagnostics, as LTEX checks the following separately (see LTeX Language Server output):

  • That is issues pertaining to Dummy0 and unique identifiers, but completely separate from the Dummy1-system.
  • For Dummy0-related issues the following propositions hold:

If it's not working for you, then you probably added \footnote{} to ltex.latex.commands. This is a feature that was specifically requested before (see #63).* If you didn't add it to ltex.latex.commands, then this is a bug and I need some more info; it would then be best if you filled in the bug report template and replaced the description of this issue with it.

*) This means that "default" is not necessarily the same as not adding a command to ltex.latex.commands. The docs say “The command is treated like unknown commands are treated by default: The command name itself is ignored, but the arguments are not ignored.” (emphasis mine), but \footnote is not a command unknown to LTEX, as it already does this magic processing.

@flindeberg
Copy link
Author

You are right, I wonder how long I've had it in ltex.latex.commands.

Ty for the quick reply!

@valentjn valentjn added the 3-duplicate Issue resolution: Issue has been submitted before label Feb 16, 2021
@valentjn
Copy link
Owner

valentjn commented May 5, 2021

Duplicate of #42

@valentjn valentjn marked this as a duplicate of #42 May 5, 2021
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 3-duplicate Issue resolution: Issue has been submitted before
Projects
None yet
Development

No branches or pull requests

2 participants