-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Implements the alignedat environment for flexible math spacing #930
Conversation
CLA signature looks good 👍 |
Given how similar Another question: if I understand correctly, |
@edemaine Thank you for your rapid reply!
I think they can share code. I will try.
Ah, I overlooked Anyway, I will resolve these soon. Thanks! |
…gned and alignedat as alignedHandler
I've just renamed |
Cool! @konn would you be able to add a screenshot test for this new environment? |
@kevinbarabash OK, I've just added a code fragment for screenshot testing. Unfortunately, I couldn't run docker image appropriately and couldn't get the diff. |
@konn yeah getting docker set up is a bit of work. I can run the tests and send you a PR with the images. |
alignedat screenshots
The screenshots look great.
Thanks for checking the output against LaTeX's. Since it's an existing issue a separate PR is appropriate. Can you open a new issue for this? |
@konn I'm going try to review this later this week. |
@kevinbarabash Thank you for everything!
OK, I've just separate this as Issue #941.
Thanks! |
…gned and alignedat as alignedHandler
Just to caught up with master branch, I've just made a little rebasing on this PR. |
Sorry for not having reviewed the code for this yet. 😞 I've been rather busy lately. Going to try to get to it this weekend though. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
src/environments/array.js
Outdated
if (numMaths < curMaths) { | ||
throw new ParseError( | ||
"Too many math in a row: expected " | ||
+ numMaths + ", but got " + curMaths, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style nit:
"Too many math in a row: " +
`expected ${numMaths}, but got ${curMaths}`,
might be at little easier to read. Also, the indentation is a little funky here. Can you indent args that occur on new lines, e.g.
throw new ParseError(
"Too many..." +
`expected ${numMaths}...`,
row);
@konn thanks for the PR. Sorry again about the delay. |
@kevinbarabash No problem. Thank you again! |
Implemented
alginat
andalignat*
environments fromamsmath
package.They are display math environments, similar to
align
andalign*
environments, but adds no spacing commands such as\qquad
between maths, which permits users to adjust spacing manually.Use cases:
With LaTeX, we get: