INTI-CMNB / KiBot

KiCad automation utility
GNU Affero General Public License v3.0
562 stars 66 forks source link

[FEATURE] Set default font for schematic PDF #691

Open nguyen-v opened 4 days ago

nguyen-v commented 4 days ago

Fill as much as you can, remove the rest

Is your feature request related to a problem? Please describe. I have a custom template which uses the default KiCad font for most of the components (useful when working on it, as the default font is much faster to render than other fonts). When printing the schematic to PDF, I like to change the default KiCad font (in the Preferences) to 'Times New Roman' so that the output looks more like Altium.

Describe the solution you'd like A way to set the default KiCad font to a user-specified one, similar to the color_theme option in the pdf_schematic output. Currently I have my fonts in the kibot_resources/fonts folder in TTF format.

Describe alternatives you've considered An alternative solution is to manually change all of the text fields in my schematic where the default font is used to 'Times New Roman'. This is not very efficient and I use multiple fonts across the schematic (Arial and Times New Roman), so the 'Edit Text and Graphic Properties' tool wouldn't work well.

Another way to do it manually would be to write a script to add '(face "fontname")' directly in the .kicad_sch files

Additional context Current output: image

Desired output: image

set-soft commented 4 days ago

Lamentably this isn't currently possible because the kicad-cli tool just ignores the default font.

https://gitlab.com/kicad/code/kicad/-/issues/17715

I could use the GUI, like in old times, but maintaining a GUI export just for this looks a major overkill. To anybody wanting this feature I'll suggest putting pressure to KiCad maintainers by commenting on the above issue.

nguyen-v commented 4 days ago

This is a shame, but thanks for having a look at it!