Enum FontEmbedding
The embedding permissions a face declares in its OS/2 fsType field. Egami reports them and never enforces them; a caller that embeds fonts, such as a PDF writer, decides what to do.
[Flags]
public enum FontEmbedding
Fields
BitmapOnly = 512Only bitmaps may be embedded, not outlines (bit 9).
Editable = 8The face may be embedded in documents that are edited (bit 3).
Installable = 0No restriction: the face may be embedded and installed (fsType 0).
NoSubsetting = 256The face must not be subsetted before embedding (bit 8).
PreviewAndPrint = 4The face may be embedded for previewing and printing only (bit 2).
Restricted = 2The face must not be embedded, changed or exchanged without the owner's permission (bit 1).
Examples
// Keep only the glyphs a page uses, as a PDF writer embeds them: renumbered from 0, with the map to write the text with.
GlyphRun run = new Font(face, 12).Shape("Invoice 2026-10");
FontSubset subset = FontSubsetter.Subset(face, run.Glyphs.ToArray(), new SubsetOptions
{
FontNamePrefix = "ABCDEF+",
KeepCmap = false,
});
byte[] fontFile2 = subset.Data.ToArray();
ushort first = subset.GlyphMap[run.Glyphs[0]];
// The face's embedding permissions are reported, never enforced: the writer decides.
bool restricted = face.Embedding.HasFlag(FontEmbedding.Restricted);