IHTMLFontNamesCollection

IHTMLFontNamesCollection


This interface is for the collection of all the font names supported by the system, created by using the system font enumeration calls. The collection is maintained by the IHTMLOptionsHolder object, which returns this interface for collection access.

IHTMLFontNamesCollection Methods
get_length   get__newEnum   item  

IHTMLFontNamesCollection::get_length

HRESULT get_length(
    long *p
);

Retrieves the number of elements in a collection.

p
Address of a variable that receives the number of elements.

IHTMLFontNamesCollection::get__newEnum

HRESULT get__newEnum(
    IUnknown **p
);

Returns an OLE enumeration interface. This will enumerate over the names in this collection.

p
Address of a variable that receives the IUnknown interface pointer.

IHTMLFontNamesCollection::item

HRESULT item(
    long index, 
    BSTR *pBstr
);

Retrieves an element or a collection from the collection. The index determines which action to take.

index
Address of a variable specifying the element or collection to retrieve. If this parameter is a number, the method returns the element in the collection at the given position, where the first element has value 0, the second has 1, and so on. If this parameter is a string, the method returns a collection of elements, where the value of the name or id property for each element is equal to the string.
pBstr
Address of a variable that receives an element object or a collection of element objects if successful, or null otherwise.

© 1997 Microsoft Corporation. All rights reserved. Terms of Use.