fontfile not doing anything?
question
<!-- If this issue relates to installation, please use https://github.com/lovell/sharp/issues/new?labels=installation&template=installation.md instead. -->
## Question about an existing feature
Im trying to get the fontfile parameter to work on the text image but it doesnt seem to do anything?
### What are you trying to achieve?
I would like a basic raster image of a string with a specific tff
<!-- Please provide context here. -->
I have a font file, that does work, called regular.tff
when I add it to the fontfile path nothing happens, it stays in the same default font. even when changing the font parameter. its important that I dont need to install the font on my system to maintain standalone portability of the tool im working on.
### When you searched for similar issues, what did you find that might be related?
I only found stuff about svg's and not the regular just make an image with font.
<img width="1422" height="454" alt="Image" src="https://github.com/user-attachments/assets/e3697024-ee51-4c59-ba61-0bd8f1d26d48" />
关闭于 2026-04-20 2 条评论