[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Font packaging and Unicode Private Use Areas



Hello mentors,

I think I encountered a corner case about font packaging.

I have to view lots of pictures through SSH without X forwarding during my
work for machine learning purpose. The best software for this purpose, I
think, is chafa[1], which performs much better than catimg.
However I'm still not satisfied with chafa's resolution so I tired to
generate a set of glyphs specific for Unicode art, leveraging K-Means
clustering algorithm. The result[2] surprised me and it looks promising.
The latest result is far much better than what I posted in the pull
request page.

As the chafa package maintainer I have to face the following
issue when my custom font is merged into upstream code:

1. What's the best practice for fonts that occupies PUA plane?

   The number of glyphs is controled by the manually-set hyper-parameter
   "K" ("K"-Means). And I personally don't mind using up the whole PUA plane
   16 [3] for printing pictures. Unicode art will be better if more
   custom glyphs are avaiable.

   That means the resulting font, if I didn't manage to reduce the "K"
   coefficient, will conflict all fonts that uses PUA plane 16 .

   My personall opinion is to do nothing more than adding a notice to
   package description, saying that "this package ships a font that
   occupies the whole Unicode PUA plane 16".

Thanks.

[1] https://github.com/hpjansson/chafa
[2] https://github.com/hpjansson/chafa/pull/22
[3] 0x100000 - 0x10FFFD, capable of nearly 65536 glyphs
    https://en.wikipedia.org/wiki/Private_Use_Areas


Reply to: