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

Add math environment DispWithArrows from package witharrows #2755

Closed
Nora-n opened this issue Jul 10, 2023 · 2 comments
Closed

Add math environment DispWithArrows from package witharrows #2755

Nora-n opened this issue Jul 10, 2023 · 2 comments

Comments

@Nora-n
Copy link

Nora-n commented Jul 10, 2023

Currently, the environment DispWithArrows loaded from the package witharrows (see ctan) is not considered a math environment.

\usepackage{physics}
\usepackage{witharrows}
\begin{DispWithArrows}
  \dv{i_2}{t} &= - \frac{M}{L_2} \dv{i_1}{t}
  \Arrow{\text{par intégration}} \\
  \Rightarrow
  i_2 &= -\frac{M}{L_2}i_1 + \mathrm{cte}
\end{DispWithArrows}

It would be a huge help to have this environment read as a mathzone with vimtex#syntax#in_mathzone

lervag added a commit that referenced this issue Jul 11, 2023
@lervag
Copy link
Owner

lervag commented Jul 11, 2023

I've added initial support for the witharrows package now. It currently only does this:

  • Recognizes DispWithArrows as a math environment, and
  • Recognizes that \Arrow will take a text argument (notice that the text{...} inside your \Arrow{...} is not necessary).

@lervag
Copy link
Owner

lervag commented Jul 11, 2023

The witharrows documentation was 100 pages long, so I'm sure there are improvements to be had here. But I'll leave it to you/users to raise issues for that. If you find something missing, feel free to reopen the issue or open a new issue. If so, please provide an example (preferably a minimal one that I can compile) on which I can reproduce the missing feature.

And thanks for contributing to the project by suggesting improvements! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants