FontSubsetter
Overview
FontSubsetter is a class in Aspose.Font FOSS for Python.
Methods
| Signature | Description |
|---|---|
available_presets() → tuple[str, ...] | |
subset(font: Font, codepoints: set[int]) → Font | |
subset_by_text(font: Font, text: str) → Font | |
subset_by_gids(font: Font, gids: set[int]) → Font | |
subset_by_presets(font: Font, presets: str | Iterable[str]) → Font | |
subset_for_web(font: Font, presets: str | Iterable[str], text: str, codepoints: Iterable[int], ranges: Iterable[tuple[int, int] | range]) → Font | |
subset_with_coverage(font: Font, codepoints: set[int]) → SubsetResult | Subset by codepoints and return both the new font and coverage diagnostics. |
subset_for_web_with_coverage(font: Font, presets: str | Iterable[str], text: str, codepoints: Iterable[int], ranges: Iterable[tuple[int, int] | range]) → SubsetResult | Subset from web selection inputs and include grouped coverage diagnostics. |
analyze_coverage(font: Font, codepoints: Iterable[int], groups: Iterable[CoverageGroup]) → SubsetCoverage | Report which requested Unicode codepoints the font can encode. |
analyze_web_coverage(font: Font, presets: str | Iterable[str], text: str, codepoints: Iterable[int], ranges: Iterable[tuple[int, int] | range]) → SubsetCoverage | Report coverage for combined preset, text, codepoint, and range inputs. |
resolve_codepoints(presets: str | Iterable[str], text: str, codepoints: Iterable[int], ranges: Iterable[tuple[int, int] | range]) → set[int] |