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

Suppress checking in latex syntax #258

Closed
duhd1993 opened this issue Mar 18, 2019 · 9 comments
Closed

Suppress checking in latex syntax #258

duhd1993 opened this issue Mar 18, 2019 · 9 comments

Comments

@duhd1993
Copy link

Can I somehow only let it check for the plain text part of the latex file?
image

@bartosz-antosik
Copy link
Owner

I will look into this.

bartosz-antosik added a commit that referenced this issue Mar 24, 2019
@bartosz-antosik
Copy link
Owner

It should be fixed in the just release version 3.0.30. Please let me know if it is indeed.

It was introduced in the recent attempt to make LaTeX parser speedier.

@duhd1993
Copy link
Author

duhd1993 commented Mar 24, 2019

Thank you! It's working as expected. The only problem now is that it's still complaining about part of the equations. e.g. the mgy in W=mgy. This is acceptable. I just add them to workspace dict.

Maybe only check for spelling in \text{} or similar environments in equation mode. I'm not sure whether this is a good idea.

Edit: I just find I can put a space between letters to avoid those errors.

@bartosz-antosik
Copy link
Owner

Math should not be spelled. Could you please show me an example (copy-able, not screenshot, preferably)?

@duhd1993
Copy link
Author

See this demo.tex
\documentclass[12pt]{extarticle}
\begin{document}
\begin{equation}
V=mgy
\end{equation}
\end{document}

"mgy": suggestions: my, mg, may, mgs, muggy

@bartosz-antosik
Copy link
Owner

bartosz-antosik commented Mar 24, 2019

Then no! What it does skip is:

$ math $
\( math \)
\[ math \]

I will have to think about the syntax you mention. It's probably worth adding to Spell Right. Anyway it can probably be added using regular expressions (see README.md).

@duhd1993
Copy link
Author

Thank you. something like \\begin{equation}[^]*?\\end{equation} will do.
it would be even better to be able to check within \text{} in equations though.

@bartosz-antosik
Copy link
Owner

Also \begin|\end{align*} maybe. To check within \text{} I have to recognize equation block first anyway...

@Bakerbakura
Copy link

Please do add detection of equation blocks! Some equation-type environments which should not be spelled when inside a begin/end block are:

  • equation
  • equation*
  • align
  • align*
  • gather
  • gather*
  • flalign
  • flalign*
  • multline
  • multline*
  • alignat
  • alignat*

Some text inside these environments which should be spelled include stuff inside \text{}, \intertext{}, and \shortintertext{}.

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

No branches or pull requests

3 participants