}
if (embeddingMode == EmbeddingMode.SUBSET) {
throw new IllegalArgumentException(
"Subset embedding for Type 1 fonts is not supported");
}
loader = new Type1FontLoader(fontFileURI, embedded, useKerning, resolver);
} else {
loader = new TTFFontLoader(fontFileURI, subFontName,
embedded, embeddingMode, encodingMode, useKerning, useAdvanced, resolver);
}
return loader.getFont();