- 
          
- 
                Notifications
    You must be signed in to change notification settings 
- Fork 171
math2svg.lua filter #118
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
math2svg.lua filter #118
Conversation
new file: displaymath2svg.lua
modified: displaymath2svg.lua
modified: displaymath2svg.lua
        new file:   .gitignore
        modified:   README.md
        modified:   displaymath2svg.lua
    modified: displaymath2svg.lua
        new file:   Makefile
        new file:   expected.html
        new file:   sample.md
    modified: README.md
modified: displaymath2svg.lua
| Thank you for the PR. The documentation looks nice, tests are good, and
the filter seems useful.
There are a couple of questions and issues which we should check to make
the filter maintainable as well as useful for other users.
A problem I see is that the docs are focused on Ubuntu/Debian and the
path to `tex2svg` is hard-coded in the filter. We should either have
clear instructions for all major platforms, or just link to instructions
provided elsewhere.
The lua-filters repo is under the MIT license; I'd like to prevent a
jumble of filter licenses. For that reason we can't include code
licensed under the GPL-3.
The addition of the additional LaTeX commands is opinionated; can we
find a way to make that more general?
Could you also add an explanation to the docs why only display math
equations are handled, but not inline math? I assume it is because of
baseline alignment issues? How does Mathjax handle that normally?
The filter currently adds raw SVG code to all formats, which is most
likely not what we want. Maybe we could store the images in the mediabag
in these cases?
Cheers! | 
| Thank you for the very constructive comments. | 
        modified:   README.md
        modified:   displaymath2svg.lua
    | Dear Albert, I think I have been able to attend to all your concerns: 
 | 
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.
Thank you for the quick update. There are a few things which I forgot to include in my first comment, and was not specific enough about others. See below for a couple of inline comments.
Cheers!
modified: math2svg.lua
| 
 Done. It seems to be working. I also cleaned up a bit the YAML indenting as per Travis CI documentation. 
 Done. The key is now called  
 Reducing the lines below 80 columns is simply not possible because some of the hyperlinks in  
 To set the record straight: More than a year before John was even considering this, others and myself were already playing with math SVG. Credits for suggesting the current solution go out to Nikolay "Lierdakil" Yakimov. Anyhow, no, I do not think this needs mentioning. What I do think is that our Lua filters deserve BETTER MARKETING. 
 Won't fix. In the  
 
 Work in progress. I already fixed it with a  | 
| I opened #121 concerning better Lua filter marketing. | 
| The additional, non-essential changes to  The 80 char-per-line rule is rooted in two principles: (1) The README should be easy to read, no matter whether viewed as rendered HTML in a browser, or as plaintext on a console. (2) research showed that text is easiest to read if there a 60 to 66 characters per line. 80 is still acceptable, anything above 100 is seriously bad. If you don't like how links look when forcing shorter lines, use reference links. | 
Co-authored-by: Christophe Dervieux <[email protected]>
| We had to switch from Travis CI, so now all tests are run in GitHub Actions. This led to a merge conflict which has to be resolved before we can finally merge. The additional packages now need to be added in  | 
| @tarleb Dear Albert, I have modified  
 The packages  | 
| All open issues have been resolved. | 
| Thanks! | 
This Lua filter converts LaTeX math to MathJax generated SVG in any of the available MathJax fonts.