View on GitHub

Font-FreeType-raku

Read font files and render glyphs using FreeType2

[Raku PDF Project] / [Font-FreeType Module] / Font::FreeType :: NamedInfo

class Font::FreeType::NamedInfo

Information from ‘names table’ in font file

Synopsis

use Font::FreeType;

my Font::FreeType $freetype .= new;
my $face = $freetype.face('Vera.ttf');
my $infos = $face.named-infos;
if $infos {
  say .Str for @$infos;
}

Description

The TrueType and OpenType specifications allow the inclusion of a special names table in font files. This table contains textual (and internationalized) information regarding the font, like family name, copyright, version, etc.

Possible values for platform-id, encoding-id, language-id, and name_id are given in the file ttnameid.h from FreeType distribution. For details please refer to the TrueType or OpenType specification.

Methods

platform-id

encoding-id

language-id

name-id

Str

The name string. Note that its format differs depending on the (platform, encoding) pair. It can be a Pascal String, a UTF-16 one, etc.

Authors

Geoff Richards qef@laxan.com

David Warring david.warring@gmail.com (Raku Port)

Copyright 2004, Geoff Richards.

Ported from Perl to Raku by David Warring david.warring@gmail.com