Re: where does fc-query get its fontversion from?

Khaled Hosny <[email protected]>
Newsgroups gmane.comp.fonts.fontconfig
Message-ID <20170427011705.GB1537@macbook>
On Thu, Apr 27, 2017 at 10:34:48AM +1000, Nigel Tao wrote:
> A user of the Go Fonts asks me (at
> https://github.com/golang/image/commit/f03a046406d4d7fbfd4ed29f554da8f6114049fc#commitcomment-21898082):
> 
> Fontconfig says that the font version is "2.2.12" but the git commit
> message says the font version is 2.008. Why the difference?
> 
> $ printf "0x%x\n" $(fc-query -f '%{fontversion}' Go-Smallcaps.ttf)
> 0x2020c

It comes from the head table and is encoded as 16.16 fixed-point number:
https://www.microsoft.com/typography/otspec/head.htm

So 131596 / 65536.0 = 2.008.

Regards,
Khaled
_______________________________________________
Fontconfig mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/fontconfig
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.