-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
Find a way to support custom Math expressions #1096
Comments
Sample output of the portuguese Wiktionary:
|
If we find something, we should also update the Wiki. |
Mediawiki does some nasty tricks: |
\Z is not defined, it needs to be replaced : https://github.com/maxbuchan/viv/blob/0a90c08be554c069b43798db495d45666c893c9c/apps/mediawiki/htdocs/extensions/Math/math/texutil.ml#L425
|
Most of the errors can be fixed with simple string substitutions based on the list provided above. Just a couple are more problematic:
Portuguese, French, the remaining english ones etc... they work ok with the PR to come. |
Note for later, to debug latex output, add |
I found why the few words using See https://comp.text.tex.narkive.com/zTTDqtBD/help-with-amsmath-align-not-possible render_expr = f"{expr}" if expr.startswith("\\begin{align}") else f"${expr}$" would fix it but we need to change the IMAGE_CSS... Needs more work. |
Even if this is closed, let me add the ones my renderer found in the DE Wiktionary:
Mostly due to |
You need to replace these : ebook-reader-dict/wikidict/utils.py Lines 478 to 486 in 8eb9ca4
See #1096 (comment) Though, I feel like we are doing double work here... |
Sample output of the english Wiktionary parsing:
I guess Mediawiki is using custom symbols somehow. We should find a way to handle them.
The text was updated successfully, but these errors were encountered: