goat icon indicating copy to clipboard operation
goat copied to clipboard

How to Change Font of the Text in the Output SVG File

Open cricrazy opened this issue 1 year ago • 4 comments

For the given ASCIIArt, if I have some Text, I would like to have this Text in the output image as Regular Fonts and Not Monospaced fonts. How can I change the font setting for the output image file?

 Step 1
   |
   v
 Step 2
   |
   v
  End

gives this output.

image

cricrazy avatar May 10 '24 18:05 cricrazy

This would be of very narrow application, since any graphics to the right of such text would fall out of X-axis alignment with rows above and below.

Recommend "won't fix".

dmullis avatar Jun 17 '24 23:06 dmullis

Reopening based on title of issue, not specific variable pitch fonts, which remain impractical, due to alignment issues.

Alternate fixed pitch fonts however are practical; there's no reason not to allow their specification as configuration options.

dmullis avatar Jul 10 '24 21:07 dmullis

Thank you for building this cool library.

Is there a way to fix kerning?

I am using goat inside Hugo for a blog post, and the letters seem squished together.

Image

baghaii avatar Mar 20 '25 22:03 baghaii

Unfortunately setting of the font size to '1em' is hard-wired into the current source code.

dmullis avatar Apr 06 '25 00:04 dmullis