Hello, I am really in the dark here. The tools I have at my disposal are Python and PIL''s ImageFont module. I can open a ttf/otf or Type1 font (thank goodness) and I can (it seems) specify the index, but how do I get the family name (and style, if that''s even separate) from those sub faces? I was wondering if there was some fc-* incantation that would help here? \d
Follow-up. I tried this script to search all known font files (I manually varied the wildcard). So far I have not found one example of a font file that has an index > 0, but I''m very likely misinterpreting things. for f in `locate .otf`; do i=`fc-match -v "$f" | grep index | cut -c 9`; [[ $i -ne 0 ]] && echo "$f"; done \d
>>>>> "Donn" == Donn <donn.ingle at gmail.com> writes:Donn> So far I have not found one example of a font file that Donn> has an index > 0, ... Donn> for f in `locate .otf`; ... I doubt there are many (any?) files in the wild with both multiple faces and an .otf filename extension. (It can be done, but is at best rare.) Most of the fonts with multiple faces will have either a .ttf or (more likely) a .ttc filename extension. And don''t forget to do a case- insensitive search (eg `locate -i .ttc`) since most such fonts were intended for doze and may have upercase filenames. Based on some notes from my laptop''s OEM filesystem, the TTC fonts which shipped with doze XP were: batang.ttc, gulim.ttc, mingliu.ttc, msgothic.ttc, msmincho.ttc, simsun.ttc TTC, incendently, comes from the name True Type Collection. -JimC -- James Cloos <cloos at jhcloos.com> OpenPGP: 1024D/ED7DAEA6
> I doubt there are many (any?) files in the wild with both multiple faces > and an .otf filename extension. (It can be done, but is at best rare.)Oh, I did change the wildcard to test ''em all.> batang.ttc, gulim.ttc, mingliu.ttc, msgothic.ttc, msmincho.ttc, simsun.ttc > TTC, incendently, comes from the name True Type Collection.Thanks for this info - it will help me out! I''ll try batang from the Ubuntu repos - I think I recall the word flying past some time recently. \d
> batang.ttc, gulim.ttc, mingliu.ttc, msgothic.ttc, msmincho.ttc, simsun.ttc > TTC, incendently, comes from the name True Type Collection.I don''t know the legality, but I have not managed to find any ttc fonts via the Ubuntu repos. Would it be possible for you to send me a couple so I can get my app to use them? Or point me to the right place on the web? I won''t use the actual faces in my app, just get it opening and viewing them. \d
I found this redistributable .ttc font: http://distro.ibiblio.org/pub/linux/distributions/gentoo/distfiles/mikachan-font-9.1.tar.bz2 It is about a 12 MB download. mikachanall.ttc has four fonts and mikachan_puchi.ttc has two. In case any are closer, these are the listed mirrors for that file: http://distro.ibiblio.org/pub/linux/distributions/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo/distfiles/mikachan-font-9.1.tar.bz2 http://gentoo.osuosl.org/distfiles/mikachan-font-9.1.tar.bz2 ftp://ftp.oregonstate.edu/pub/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://ftp.tu-clausthal.de/pub/linux/gentoo/distfiles/mikachan-font-9.1.tar.bz2 http://ftp.gentoo.or.kr/distfiles/mikachan-font-9.1.tar.bz2 http://ftp.snt.utwente.nl/pub/os/linux/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://ftp.snt.utwente.nl/pub/os/linux/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://ftp.rez-gif.supelec.fr/pub/Linux/distrib/gentoo/distfiles/mikachan-font-9.1.tar.bz2 http://mirrors.tds.net/gentoo/distfiles/mikachan-font-9.1.tar.bz2 http://open-systems.ufl.edu/mirrors/gentoo/distfiles/mikachan-font-9.1.tar.bz2 http://gentoo.mirrors.pair.com/distfiles/mikachan-font-9.1.tar.bz2 http://cudlug.cudenver.edu/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://cudlug.cudenver.edu/pub/mirrors/distributions/gentoo/distfiles/mikachan-font-9.1.tar.bz2 ftp://lug.mtu.edu/gentoo/source/distfiles/mikachan-font-9.1.tar.bz2 -JimC -- James Cloos <cloos at jhcloos.com> OpenPGP: 1024D/ED7DAEA6