FontCollection
Overview
FontCollection is a class in Aspose.PDF FOSS for .NET.
Inherits from: IEnumerable<Font>.
Collection of fonts referenced by a page.
This class declares 6 methods for FontCollection objects in .NET programs.
Available methods include: Add, Contains, CopyTo, GetEnumerator, Remove.
Public members are accessible to any .NET application after installing the Aspose.PDF FOSS for .NET package.
Properties: Count, IsReadOnly, IsSynchronized, SyncRoot.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
Count | int | Read | Gets the number of fonts in the collection. |
IsReadOnly | bool | Read | Gets the is read only. |
IsSynchronized | bool | Read | Gets the is synchronized. |
SyncRoot | object | Read | Gets the sync root. |
Methods
| Signature | Description |
|---|---|
GetEnumerator() | Calls GetEnumerator on this FontCollection instance. |
Contains(item: Font) | Returns true when the collection contains the given font object. |
Contains(name: string) | Returns true when a font in the collection has the given resource name (e.g. |
CopyTo(array: Font[], index: int) | Copies the fonts into array, starting at the zero-based index. |
Remove(item: Font) | Removes the given font from this collection only (the page’s resources are not changed); returns true when it was found. |
Add(newFont: Font, resName: string) | Add a font and emit the PDF resource name assigned to it (e.g. |