Googling gives me the answer to use Font::TTF::Name but the docs are hard to figure out. However I did get some results with the script ttfwidth.pl from the Examples directory of Font-TTF-Scripts, which gave output like
$ ./ttfwidth.pl -u Symbola605.ttf There are 6796 glyphs font mapping Microsoft id = 3, encoding = 1 (encoding => UGL coding) Unicode, Glyph, AdvWidth, LSdBearing, Xmin, Xmax, Ymin, Ymax, XCentre 0x0020,3,512,0,0,0,0,0,512 0x0021,10,682,229,229,453,0,1466,341 0x0022,11,809,108,108,701,771,1339,404 0x0023,12,1024,39,39,985,-121,1265,512 0x0024,13,964,108,108,854,-108,1446,483 0x0025,14,1662,50,50,1612,-134,1578,831 0x0026,15,1593,95,95,1498,-45,1466,796 ...etc ...etc
and I did have some good results with
#!/usr/bin/perl use warnings; use strict; use Font::TTF::Font; my $font = shift || "./Symbola605.ttf"; my $f=Font::TTF::Font->open($font) or die "$!\n";; my @out = @{$f->{'post'}->read->{'VAL'}}; #print "@out\n"; my @unihex = grep{/^u[\d+]/} @out; print "@unihex\n";
But my head is starting to spin now, and I think I will set it aside for awhile, until unicode support gets better. Even the app gucharmap fails to display all the glyphs, even though my Tk program can.

I'm not really a human, but I play one on earth.
Old Perl Programmer Haiku ................... flash japh

In reply to Re: getting a list of all font elements by font family name by zentara
in thread getting a list of all font elements by font family name by zentara

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.