pe 29. marrask. 2019 klo 20.28 Ruth Ivimey-Cook (r...@ivimey.org) kirjoitti:
> I would be interested to know why it is not possible/good to use "normal" > outline fonts (ttf, otf et al) on a PCB.... what are the issues? > That's an easy one to answer, at least partially. PCB needs graphics which can be exported to gerber graphics. In practice this means that font characters (I think the correct word is "glyph") should be converted to polygonal outlines. It wouldn't be impossible, but would require writing a conversion library (or finding an existing one) and integrating into KiCad. I guess it would be quite resource heavy run time because each character would be one or several complex polygons. Using a simple font like Arial would be most realistic - it has lots of straight lines instead of curves. Serif fonts like Times aren't so fitting for a PCB board anyways because they wouldn't be so clear in small sizes and because of bad resolution (I mean the resolution of the physical board, especially silk). Another option would be to pre-convert some font to polygons and use them, a bit like the current font system in pcbnew. It now has a font where each character is a bunch of segments. Only handling polygons instead of segments would be required. However, it's not quite that simple. For good results the characters must be kerned, i.e. the space between any two characters must be decided case by case bases. Otherwise non-monospace fonts don't look good. That's one reason why complex font engines are needed in the first place. Just drawing characters would be relatively easy (except for antialiasing etc. but KiCad doesn't need to worry about that). So, either the characters should be drawn without kerning or there should be some way to do the kerning. Maybe adding kerning to text handling code wouldn't be impossible. I don't know how the font engines work, but maybe it could be possible to let an external font engine do the layout to a dummy backend without it knowing about the actual visual output and then find the locations of characters. Another thing to think of is the physical quality of the manufactured board which should be the greatest concern. Silk screen resolution is bad. That means that the text would look decent only in large size, especially when made by cheap technologies. Text in copper or mask is better. But in any case it would be much work which would benefit little. Still I think it would great to have it in KiCad. Maybe someone could write a python plugin? It would be possible to create text as graphic polygons, although it wouldn't be possible to handle it as normal native text. But it would help if someone needs nice text for end users of a board. Eeli Kaikkonen
_______________________________________________ Mailing list: https://launchpad.net/~kicad-developers Post to : kicad-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~kicad-developers More help : https://help.launchpad.net/ListHelp