You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
svg backend has limited encoding support with usetex #8068
As reported on Launchpad, the combination of text.usetex=True, text.latex.unicode=True, and the svg backend can produce files with missing or wrong characters. A warning does get printed.
The svg file lacks the won character. A warning like the following is printed:
../lib/matplotlib/textpath.py:389: UserWarning: The glyph (142) of font (/usr/local/texlive/2016/texmf-dist/fonts/type1/public/cm-super/sfss3583.pfb) cannot be converted with the encoding. Glyph may be wrong
"be wrong" % (glyph, font_bunch.filename))
Expected outcome
The svg file should include the won character (₩), as the pdf and png files do. I don't think we document usetex as being supported in the svg backend, but for several use cases it works.
Matplotlib version
Current master (3d99e43) installed from git with pip install -e .
I believe I'm also experiencing this issue. In my case, I'm completely missing "fl" from a word in the SVG. I suspect this "fl" is a ligature in LaTeX and thus, possibly, treated as a special character (like the original report). In the generated SVG file, I can see
This issue has been marked "inactive" because it has been 365 days since the last comment. If this issue is still present in recent Matplotlib releases, or the feature request is still wanted, please leave a comment and this label will be removed. If there are no updates in another 30 days, this issue will be automatically closed, but you are free to re-open or create a new issue if needed. We value issue reports, and this procedure is meant to help us resurface and prioritize issues that have not been addressed yet, not make them disappear. Thanks for your help!
Activity
tacaswell commentedon Feb 12, 2017
Labeling this as hard as fixing it will likely involve understanding a whole lot about text encoding.
slochower commentedon Mar 7, 2018
I believe I'm also experiencing this issue. In my case, I'm completely missing "fl" from a word in the SVG. I suspect this "fl" is a ligature in LaTeX and thus, possibly, treated as a special character (like the original report). In the generated SVG file, I can see
which is correct.
Using matplotlib version 2.1.2 installed via conda, with the following settings:
github-actions commentedon Apr 7, 2023
This issue has been marked "inactive" because it has been 365 days since the last comment. If this issue is still present in recent Matplotlib releases, or the feature request is still wanted, please leave a comment and this label will be removed. If there are no updates in another 30 days, this issue will be automatically closed, but you are free to re-open or create a new issue if needed. We value issue reports, and this procedure is meant to help us resurface and prioritize issues that have not been addressed yet, not make them disappear. Thanks for your help!
QuLogic commentedon Apr 7, 2023
This was fixed by #12928 + #14156.
slochower commentedon Apr 8, 2023
Thanks for the update @QuLogic