Adobe.com
Contents Suites Classes Class Index Member Index

ATE::ICompFont Class Reference

Encapsulates a composite font as a text resource. More...

#include <IText.h>

List of all members.

Public Member Functions

 ICompFont ()
 Constructor.
 ICompFont (const ICompFont &src)
 Copy constructor.
ICompFontoperator= (const ICompFont &rhs)
 Assignment operator.
bool operator== (const ICompFont &rhs) const
 Comparison operator tests for equality.
bool operator!= (const ICompFont &rhs) const
 Comparison operator tests for inequality.
 ICompFont (CompFontRef compfont)
 Constructs this C++ object from the corresponding C object returned by an ATE suite function.
virtual ~ICompFont ()
 Destructor.
CompFontRef GetRef () const
 Retrieves a reference to this object.
bool IsNull () const
 Reports whether this is a null object.
 ICompFont (ITextResources pResources)
 Constructor: Creates a composite font from a text resources object.
void GetNativeName (ATETextDOM::Unicode *name, ATETextDOM::Int32 maxLength) const
 Retrieves the platform-specific name of this font.
void SetNativeName (const ATETextDOM::Unicode *name)
 Sets the platform-specific name of this font.
void GetPostScriptName (ATETextDOM::Unicode *name, ATETextDOM::Int32 maxLength) const
 Retrieves the PostScript name of this font as Unicode.
void GetPostScriptName (char *name, ATETextDOM::Int32 maxLength) const
 Retrieves the PostScript name of this font as a C string.
void SetFontDictionary (void *fontDictionary)
 Sets the font dictionary for this font.
void * GetFontDictionary () const
 Retrieves the font dictionary for this font.
ICompFont Duplicate () const
 Duplicates this font.
bool IsModified () const
 Reports whether the resource been modified since it became editable.
bool IsEditable () const
 Reports whether the resource is currently editable.
bool IsCommitted () const
 Reports whether changes to the resource have been committed.
bool VerifyState () const
 Reports whether the resource is in a valid state, either editable or committed.
bool IsATCFileLoaded () const
 Reports whether the ATC file for the font is currently loaded.
ATETextDOM::Int32 GetComponentCount () const
 Retrieves the number of components of this font.
ICompFontComponent GetComponent (ATETextDOM::Int32 index) const
 Retrieves a component from this font by index position.
ATETextDOM::Int32 Find (ICompFontComponent component) const
 Retrieves a specific component from this font.
bool RemoveComponent (ATETextDOM::Int32 index)
 Removes a component from this font.
ATETextDOM::Int32 AddComponent (ICompFontComponent component)
 Appends a component to this font.
bool ReplaceComponent (ATETextDOM::Int32 index, ICompFontComponent component)
 Replaces a component in this font.

Detailed Description

Encapsulates a composite font as a text resource.

The methods allow you to add, access, and manipulate fonts for use with the Adobe Text Engine (ATE). This font contains ICompFontComponent objects.


Constructor & Destructor Documentation

ATE::ICompFont::ICompFont (  ) 

Constructor.

Returns:
The new object.

Referenced by Duplicate().

ATE::ICompFont::ICompFont ( const ICompFont src  ) 

Copy constructor.

Parameters:
src The object to copy.
Returns:
The new object.

References ATE::sCompFont.

ATE::ICompFont::ICompFont ( CompFontRef  compfont  )  [explicit]

Constructs this C++ object from the corresponding C object returned by an ATE suite function.

The C++ object manages reference counting.

Parameters:
compfont The C object.
Returns:
The new C++ object.
ATE::ICompFont::~ICompFont (  )  [virtual]

Destructor.

References ATE::sCompFont.

ATE::ICompFont::ICompFont ( ITextResources  pResources  ) 

Constructor: Creates a composite font from a text resources object.

Parameters:
pResources The text resources object.
Returns:
The new object.

References ATE::ITextResources::GetRef(), ATE::sCompFont, and ATE::Throw_ATE_Exception().


Member Function Documentation

ATETextDOM::Int32 ATE::ICompFont::AddComponent ( ICompFontComponent  component  ) 

Appends a component to this font.

Parameters:
component The component object.
Returns:
The 0-based position index of the successfully added component, or -1 if the component could not be appended.

References ATE::ICompFontComponent::GetRef(), ATE::sCompFont, and ATE::Throw_ATE_Exception().

ICompFont ATE::ICompFont::Duplicate (  )  const

Duplicates this font.

Returns:
The new font object.

References ICompFont(), ATE::sCompFont, and ATE::Throw_ATE_Exception().

ATETextDOM::Int32 ATE::ICompFont::Find ( ICompFontComponent  component  )  const

Retrieves a specific component from this font.

Parameters:
component The component object.
Returns:
The index position of the component, or -1 if the component is not in this font.

References ATE::ICompFontComponent::GetRef(), ATE::sCompFont, and ATE::Throw_ATE_Exception().

ICompFontComponent ATE::ICompFont::GetComponent ( ATETextDOM::Int32  index  )  const

Retrieves a component from this font by index position.

Use with GetComponentCount() to iterate through components.

Parameters:
index The 0-based position index.
Returns:
The component object.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

ATETextDOM::Int32 ATE::ICompFont::GetComponentCount (  )  const

Retrieves the number of components of this font.

Use with GetComponent() to iterate through components.

Returns:
The number of components.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

void * ATE::ICompFont::GetFontDictionary (  )  const

Retrieves the font dictionary for this font.

Returns:
A pointer to the dictionary..
See also:
AIDictionarySuite

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

void ATE::ICompFont::GetNativeName ( ATETextDOM::Unicode name,
ATETextDOM::Int32  maxLength 
) const

Retrieves the platform-specific name of this font.

Parameters:
name A buffer in which to return the name string.
maxLength The number of characters in the passed buffer. The name is truncated to this length if necessary.
Returns:
Nothing.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

void ATE::ICompFont::GetPostScriptName ( char *  name,
ATETextDOM::Int32  maxLength 
) const

Retrieves the PostScript name of this font as a C string.

Parameters:
name A char buffer in which to return the name string.
maxLength The number of characters in the passed buffer. The name is truncated to this length if necessary.
Returns:
Nothing.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

void ATE::ICompFont::GetPostScriptName ( ATETextDOM::Unicode name,
ATETextDOM::Int32  maxLength 
) const

Retrieves the PostScript name of this font as Unicode.

Parameters:
name A Unicode character buffer in which to return the name string.
maxLength The number of characters in the passed buffer. The name is truncated to this length if necessary.
Returns:
Nothing.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

CompFontRef ATE::ICompFont::GetRef (  )  const

Retrieves a reference to this object.

Returns:
The object reference.

Referenced by ATE::ICompFontSet::Add(), ATE::ICompFontSet::Find(), and ATE::ICompFontSet::Replace().

bool ATE::ICompFont::IsATCFileLoaded (  )  const

Reports whether the ATC file for the font is currently loaded.

Returns:
True if the font file is loaded.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::IsCommitted (  )  const

Reports whether changes to the resource have been committed.

Returns:
True if changes have been committed.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::IsEditable (  )  const

Reports whether the resource is currently editable.

Returns:
True if the resource is editable.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::IsModified (  )  const

Reports whether the resource been modified since it became editable.

Returns:
True if the resource has been modified.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::IsNull (  )  const

Reports whether this is a null object.

Returns:
True if this is a null object.

References ATE::sCompFont.

bool ATE::ICompFont::operator!= ( const ICompFont rhs  )  const

Comparison operator tests for inequality.

Parameters:
rhs The object to compare to this one.
Returns:
True if the two objects are not the same.
ICompFont & ATE::ICompFont::operator= ( const ICompFont rhs  ) 

Assignment operator.

Parameters:
rhs The object to assign to this one.
Returns:
A reference to this object.

References ATE::sCompFont.

bool ATE::ICompFont::operator== ( const ICompFont rhs  )  const

Comparison operator tests for equality.

Parameters:
rhs The object to compare to this one.
Returns:
True if the two objects are the same.
bool ATE::ICompFont::RemoveComponent ( ATETextDOM::Int32  index  ) 

Removes a component from this font.

Parameters:
index The 0-based position index of the component to remove.
Returns:
True if a component was successfully removed.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::ReplaceComponent ( ATETextDOM::Int32  index,
ICompFontComponent  component 
)

Replaces a component in this font.

Parameters:
index The 0-based position index of the component to replace.
component The replacement component object.
Returns:
True if a component was successfully replaced.

References ATE::ICompFontComponent::GetRef(), ATE::sCompFont, and ATE::Throw_ATE_Exception().

void ATE::ICompFont::SetFontDictionary ( void *  fontDictionary  ) 

Sets the font dictionary for this font.

Parameters:
fontDictionary A pointer to the new dictionary.
Returns:
Nothing.
See also:
AIDictionarySuite

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

void ATE::ICompFont::SetNativeName ( const ATETextDOM::Unicode name  ) 

Sets the platform-specific name of this font.

The PostScript name is automatically derived from this name.

Parameters:
name The new name string.
Returns:
Nothing.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().

bool ATE::ICompFont::VerifyState (  )  const

Reports whether the resource is in a valid state, either editable or committed.

Returns:
True if the resource is in a valid state.

References ATE::sCompFont, and ATE::Throw_ATE_Exception().


The documentation for this class was generated from the following files:


Contents Suites Classes Class Index Member Index
Adobe Solutions Network
 
Copyright © 2014 Adobe Systems Incorporated. All rights reserved.
Terms of Use Online Privacy Policy Adobe and accessibility Avoid software piracy Permissions and Trademarks