Comments (10)
We probably should add some kind of command that shows all of the fonts that svg2pdf
can find.
from svg2pdf.
I mean the font you are seeing is in fact the same as in the reference picture (Dharma Gothic E), the only problem seems to be that for some reason it chooses the italic version of the font instead of the regular one. I can reproduce this on my system if I add the italic font to my system fonts as well, but if I only add the regular one I get the same result as in the reference picture. Not sure what is happening here, will try to investigate.
from svg2pdf.
True, in this case it is the same font in italic, but in the flyer it is a completely different one:
It renders like this:
While it should be like that:
from svg2pdf.
I have the same issue on Ubuntu 22.04.3 LTS. The font is installed correctly:
But the generated pdf renders the text that is supposed to be Dharma Gothic E with a different font. Also, the pdf's properties only show the following fonts being used:
- Montserrat-Medium
- Montserrat-SemiBold
- Montserrat-ExtraLight
- Montserrat-Bold
But I guess I should see one more font listed (the one used to render "Canberra", the numbers, etc.).
from svg2pdf.
In case that helps to remove potential setup problems, the python tool cairosvg, converts the svg file to PDF with the right fonts.
from svg2pdf.
We probably should add some kind of command that shows all of the fonts that
svg2pdf
can find.
I took a quick stab at it. PR #45 takes care of it.
from svg2pdf.
@LaurenzV Now that #45 got merged, how can we proceed to work on this issue? What type of info or help would you need from me?
from svg2pdf.
You could probably try to render your SVG using resvg (which is the underlying library we use for conversion, including for the text). If doesn't work correctly there either, it's probably an upstream issue. If it works there but not with svg2pdf
, then I'll try to investigate what we're doing wrong.
from svg2pdf.
@LaurenzV I did find out that the problem was happening with ReSVG too, so I reported the issue upstream as well: RazrFalcon/resvg#702
from svg2pdf.
This has already been fixed upstream IIRC. And I also created a new issue for font fallback (#65), so I'm closing this.
from svg2pdf.
Related Issues (20)
- PDF content generated from SVG <pattern> jumps when zoom in/out in Safari HOT 3
- [feature] Shell completion
- CLI compilation error
- Weird behavior when embedding image in SVG and specifying width/height in a unit other than px HOT 1
- Example for `convert_tree_into` does not compile HOT 1
- Make converted SVGs use up less space
- Add support for the `spreadMethod` attribute in gradients
- no any text HOT 3
- Wavedrom diagram rendering issues (font, dotted lines) HOT 7
- Colors are not represented accurately
- More CLI options HOT 1
- `convert_tree_into` doesn't work HOT 2
- Error in `dpi_ratio` HOT 3
- Embedded fonts have inconsistent text positions HOT 2
- CLI: Image transformation not being applied, and text not loading despite being system fonts HOT 11
- svg input differs to pdf output HOT 13
- Add support for better font fallback
- Improve file size when embedding CFF fonts
- Masked SVG rendered inconsistently
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from svg2pdf.