Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages | Examples

DWFToolkit::DWFEmbeddedFont Class Reference
[DWF Publisher API]

#include "dwf/publisher/EmbeddedFont.h"

Inheritance diagram for DWFToolkit::DWFEmbeddedFont:

Inheritance graph
[legend]
Collaboration diagram for DWFToolkit::DWFEmbeddedFont:

Collaboration graph
[legend]
List of all members.

Detailed Description

A general representation of a TrueType font that can be published.
Since:
7.0.1.

This object should remain platform-independent and delegate any specialized embedding technology to the implementation engines.

This class can be used both to generate an embedded font representation as well as realize that representation in the font engine [provided by the implementation.]

Examples:

3DPublish/3DPublish_UTF8.cpp.

Definition at line 205 of file EmbeddedFont.h.

Public Types

typedef vector< DWFEmbeddedFont * > tList
 This type defines a list of DWFEmbeddedFont pointers.

Public Member Functions

_DWFTK_API DWFEmbeddedFont (DWFEmbeddedFontImpl *pImpl) throw ()
_DWFTK_API ~DWFEmbeddedFont () throw ()
_DWFTK_API void addCharacters (const DWFString &rCharacters) throw ( DWFException )
_DWFTK_API void embed () throw ( DWFException )
_DWFTK_API DWFInputStreamgetInputStream () throw ( DWFException )
_DWFTK_API const DWFStringgetFaceName () throw ( DWFException )
_DWFTK_API const DWFStringgetLogfontName () throw ( DWFException )
_DWFTK_API int getRequest () throw ( DWFException )
_DWFTK_API DWFFontResource::tePrivilege getPrivilege () throw ( DWFException )
_DWFTK_API DWFFontResource::teCharacterCode getCharacterCode () throw ( DWFException )
_DWFTK_API void load (bool bForceRename=true) throw ( DWFException )
_DWFTK_API const DWFStringloadedFontName () const throw ( DWFException )
_DWFTK_API void unload () throw ( DWFException )


Constructor & Destructor Documentation

_DWFTK_API DWFToolkit::DWFEmbeddedFont::DWFEmbeddedFont DWFEmbeddedFontImpl pImpl  )  throw ()
 

Constructor

Parameters:
pImpl A pointer to a font embedding engine. This pointer will be deleted with DWFCORE_FREE_OBJECT.
Exceptions:
None 

_DWFTK_API DWFToolkit::DWFEmbeddedFont::~DWFEmbeddedFont  )  throw ()
 

Destructor

Exceptions:
None 


Member Function Documentation

_DWFTK_API void DWFToolkit::DWFEmbeddedFont::addCharacters const DWFString rCharacters  )  throw ( DWFException )
 

Identifies which character glyphs to embed.

This is an additive operation. Generally, an embedded font object is created for each TrueType font that should be published. For every string (or character) that is added to the scene that must be rendered in an embedded font, that string (or character) is sent to this method. If possible, only those data for the final character subset should be embedded.

The following are equivalent:

  1.                     pFont->addCharacters( L"This is some text" );
                        pFont->addCharacters( L"Doors and Windows" );
    
  2.                     pFont->addCharacters( L"adehimnorstwxDTW" );
    

Parameters:
rCharacters The Unicode character string.
Exceptions:
DWFException 
Examples:
3DPublish/3DPublish_UTF8.cpp.

_DWFTK_API void DWFToolkit::DWFEmbeddedFont::embed  )  throw ( DWFException )
 

Captures the embeddable font data.

This method should be invoked once after addCharacters() to use the engine implementation to perform it's work and extract, compress, etc. the font data. The next call to getInputStream() will provide the data generated from this operation.

Exceptions:
DWFException 

_DWFTK_API DWFFontResource::teCharacterCode DWFToolkit::DWFEmbeddedFont::getCharacterCode  )  throw ( DWFException )
 

Returns the character code for the embedded font

Returns:
The character code enumeration.
Exceptions:
DWFException 

_DWFTK_API const DWFString& DWFToolkit::DWFEmbeddedFont::getFaceName  )  throw ( DWFException )
 

Returns the canonical face name of the font.

Returns:
The font name.
Exceptions:
DWFException 

_DWFTK_API DWFInputStream* DWFToolkit::DWFEmbeddedFont::getInputStream  )  throw ( DWFException )
 

Provides a stream to read the embeddable font data obtained from a previous call to embed().

Returns:
A pointer to a data stream. The caller is responsible for deleting the pointer with DWFCORE_FREE_OBJECT.
Exceptions:
DWFException 

_DWFTK_API const DWFString& DWFToolkit::DWFEmbeddedFont::getLogfontName  )  throw ( DWFException )
 

Returns the logfont face name of the font.

Returns:
The font name.
Exceptions:
DWFException 

_DWFTK_API DWFFontResource::tePrivilege DWFToolkit::DWFEmbeddedFont::getPrivilege  )  throw ( DWFException )
 

Returns the privilege with which the font was embedded

Returns:
The privilege enumeration.
Exceptions:
DWFException 

_DWFTK_API int DWFToolkit::DWFEmbeddedFont::getRequest  )  throw ( DWFException )
 

Returns the request flag with which the font was embedded.

Returns:
The request flag.
Exceptions:
DWFException 

_DWFTK_API void DWFToolkit::DWFEmbeddedFont::load bool  bForceRename = true  )  throw ( DWFException )
 

Loads the given font from an embedded data representation into the font engine.

Exceptions:
DWFException 

_DWFTK_API const DWFString& DWFToolkit::DWFEmbeddedFont::loadedFontName  )  const throw ( DWFException )
 

Returns the name under which the font was loaded.

Returns:
The (temporary) font name.
Exceptions:
DWFException 

_DWFTK_API void DWFToolkit::DWFEmbeddedFont::unload  )  throw ( DWFException )
 

Unloads the embedded font from the font engine.

Exceptions:
DWFException 


The documentation for this class was generated from the following file:
Generated on Tue May 17 12:39:12 2005 for Autodesk DWF Toolkit by  doxygen 1.4.1