InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
GlyphSet Class Reference

#include <IGlyphUtils.h>

Inheritance diagram for GlyphSet:
K2Vector< GlyphEntry >K2Internals::K2VectorBase< T, Allocator >

Public Types

enum  GlyphSortOrder { kUnicodeOrder, kCIDOrder, kNoOrder }
 

Public Member Functions

int32 NumOfGlyphs () const
 
void AddGlyphEntry (bool checkUnique, Text::GlyphID altID)
 
void Sort (IPMFont *font, GlyphSortOrder order)
 
Text::GlyphID GetGlyphID (int32 index) const
 
UTF32TextChar GetUnicodeGlyphID (int32 index, IPMFont *font) const
 
int32 GetGlyphIndex (Text::GlyphID id) const
 
void ReadWrite (IPMStream *s)
 
- Public Member Functions inherited from K2Vector< GlyphEntry >
 K2Vector ()
 
 K2Vector (typename K2Allocator< GlyphEntry >::size_type count, const GlyphEntry &value)
 
 K2Vector (const K2Vector &rhs)=default
 
 K2Vector (K2Vector &&rhs) noexcept=default
 
 K2Vector (InputIterator first, InputIterator last, const K2Allocator< GlyphEntry > &a)
 
 K2Vector (InputIterator first, InputIterator last)
 
K2Vectoroperator= (const K2Vector &rhs)=default
 
K2Vectoroperator= (K2Vector &&rhs) noexcept=default
 
void swap (K2Vector &other) noexcept
 
- Public Member Functions inherited from K2Internals::K2VectorBase< T, Allocator >
 K2VectorBase (const Allocator &a=Allocator())
 
 K2VectorBase (size_type count, const T &value, const Allocator &a=Allocator())
 
template<class InputIterator >
 K2VectorBase (InputIterator first, InputIterator last, const Allocator &a)
 
template<class InputIterator >
 K2VectorBase (InputIterator first, InputIterator last)
 
void initialize (size_type count, const T &value)
 
void fill_assign (size_type, const T &)
 
void fill_insert (iterator, size_type, const T &)
 
 K2VectorBase (const K2VectorBase &rhs)
 
 K2VectorBase (K2VectorBase &&rhs) noexcept
 
void CopyConstructHelper (const K2VectorBase &rhs)
 
iterator begin ()
 
const_iterator begin () const
 
iterator end ()
 
const_iterator end () const
 
reverse_iterator rbegin ()
 
const_reverse_iterator rbegin () const
 
reverse_iterator rend ()
 
const_reverse_iterator rend () const
 
size_type size () const
 
size_type max_size () const
 
size_type capacity () const
 
bool16 empty () const
 
allocator_type get_allocator () const
 
K2VectorBaseoperator= (const K2VectorBase &rhs)
 
K2VectorBaseoperator= (K2VectorBase &&rhs) noexcept
 
void reserve (size_type capacity)
 
template<class InputIter >
void assign (InputIter first, InputIter last)
 
void assign (size_type count, const T &u)
 
reference operator[] (size_type i)
 
const_reference operator[] (size_type i) const
 
const_reference at (size_type i) const
 
reference at (size_type i)
 
reference front ()
 
const_reference front () const
 
reference back ()
 
const_reference back () const
 
void push_back (const T &x)
 
void pop_back ()
 
iterator insert (iterator position, const T &x)
 
void insert (iterator position, size_type n, const T &x)
 
template<class InputIter >
void insert (iterator pos, InputIter first, InputIter last)
 
iterator erase (iterator position)
 
iterator erase (iterator first, iterator last)
 
void swap (K2VectorBase &) noexcept
 
void clear ()
 
void resize (size_type newsize, const T &value)
 
void DoCleanup ()
 
size_type DoGetCapacity (size_type newLength)
 
void DoReset (pointer newData, size_type newLength, size_type newCap)
 

Additional Inherited Members

- Static Public Member Functions inherited from K2Vector< GlyphEntry >
static Method ForceInstantiation (int n)
 

Detailed Description

GlyphSet. Vector of GlyphEntries

See Also
IGlyphUtils

Member Enumeration Documentation

Sort orders for viewing glyph sets in the main area of the Glyph panel
Enumerator
kUnicodeOrder 

By glyph Unicode value

kCIDOrder 

By glyph CID value (font definition order)

kNoOrder 

Not sorted

Member Function Documentation

void GlyphSet::AddGlyphEntry (bool checkUnique,
Text::GlyphID altID 
)
inline

Add entry to set. Added at end.

Parameters
checkUniqueif kTrue only add if glyph is not already in set
altIDglyph to add
Text::GlyphID GlyphSet::GetGlyphID (int32 index) const
inline

Get glyph id at index.

Parameters
index
Returns
Text::GlyphID
int32 GlyphSet::GetGlyphIndex (Text::GlyphID id) const
inline

Getglyph id index

Parameters
idglyph id to find index for
Returns
int32 index
UTF32TextChar GlyphSet::GetUnicodeGlyphID (int32 index,
IPMFontfont 
) const
inline

Calls GlyphEntry::GetUnicodeGlyphID

Parameters
indexindex to get unicode from
fontfont glyphid is from
Returns
unicode character value. 0 if in PUA area and userArea is not nil.
int32 GlyphSet::NumOfGlyphs () const
inline

Number of glyphs in set

Returns
int32 number of glyphs in set
void GlyphSet::ReadWrite (IPMStreams)
inline

Read write the vector

Parameters
sstream to read write
void GlyphSet::Sort (IPMFontfont,
GlyphSortOrder order 
)
inline

Sort the glyph set into Unicode or CID order.