DRMF / texvcjs

A LaTeX validator/translator for TeX strings embedded in wikitext
0 stars 2 forks source link

Add replacement "\sinh(x)" -> "\sinh@{x}" #17

Closed poortho closed 9 years ago

poortho commented 9 years ago

Adds code to change \sinh(x) to \sinh@{x}. Also added test cases for it and made it so that the output when running bin/texvcjs ends with a newline

poortho commented 9 years ago

I updated this pull request just now. It no longer has a new line at the end of the output (as requested by Moritz) and I also fixed to following bugs in the previous commit regarding the \sinh(x) -> \sinh@{x} replacement. -not accepting multiple literals (for example, it would throw an error when the input was "\sinh(xyz)") -not accepting itself as a valid argument -not accepting empty arguments inside the parenthesis -not accepted as an argument for other LaTeX commands

physikerwelt commented 9 years ago

@ClaudeZou I would not call it bugs in texvcjs ... those "bugs" only occour since we changed the functionality and the purpose of texvcjs

poortho commented 9 years ago

@physikerwelt Ok, I changed it to bugs in the previous commit, is that acceptable?

physikerwelt commented 9 years ago

@ClaudeZou it's not that essential it's just a side remark