Laxkit  0.0.7.1
Public Member Functions
Laxkit::FontManagerCairo Class Reference

The font manager used by anXApp to simplify keeping track of what fonts are loaded. More...

Inheritance diagram for Laxkit::FontManagerCairo:
Inheritance graph
[legend]

List of all members.

Public Member Functions

virtual LaxFontMakeFontFromFile (const char *file, double size, int nid)
 Create and return a LaxFont, but do not store it within the fontmanager.
virtual LaxFontMakeFontFromStr (const char *fcstr, int nid)
 Add a font to the manager, based on an X Logical Font Description string.
virtual LaxFontMakeFont (const char *family, const char *style, double size, int nid)
 Create and return a LaxFont, but do not store it within the fontmanager.
virtual LaxFontAdd (LaxFont *font, int nid)
 Add an already created LaxFont to the manager.
virtual LaxFontCheckOut (int id)
 Add a count of 1 to the LaxFont with the given id, and return the corresponding font object.

Additional Inherited Members

- Protected Member Functions inherited from Laxkit::RefPtrStack< LaxFont >
 RefPtrStack (char nar=3)
virtual void flush ()
virtual int push (LaxFont *nd, char local=-1, int where=-1)
virtual int pushnodup (LaxFont *nd, char local=-1, int where=-1)
virtual int remove (int which=-1)
- Protected Member Functions inherited from Laxkit::PtrStack< LaxFont >
 PtrStack (char nar=1)
virtual LaxFontoperator[] (int i)
virtual int howmany ()
virtual void swap (int i1, int i2)
virtual int popp (LaxFont *topop, int *local=NULL)
virtual int pop (LaxFont *&popped, int which=-1, int *local=NULL)
virtual LaxFontpop (int which=-1, int *local=NULL)
virtual int findindex (LaxFont *t)
virtual void Delta (int ndelta)
virtual int Delta ()
virtual LaxFont ** extractArrays (char **local=NULL, int *nn=NULL)
virtual int insertArrays (LaxFont **a, char *nl, int nn)

Detailed Description

The font manager used by anXApp to simplify keeping track of what fonts are loaded.


Member Function Documentation

LaxFont * Laxkit::FontManagerCairo::Add ( LaxFont font,
int  nid 
)
virtual

Add an already created LaxFont to the manager.

If nid<0 then the id is from getUniqueNumber().

If the font is already on the stack, nothing is done.

The font's count is incremented. Returns the font object or NULL on error.

Implements Laxkit::FontManager.

References Laxkit::getUniqueNumber().

LaxFont * Laxkit::FontManagerCairo::CheckOut ( int  id)
virtual

Add a count of 1 to the LaxFont with the given id, and return the corresponding font object.

Returns the LaxFont object, or NULL if object not found.

Please remember that when you are all done with the font, you must decrement its count.

Implements Laxkit::FontManager.

References Laxkit::PtrStack< LaxFont >::e, Laxkit::anObject::inc_count(), and Laxkit::PtrStack< LaxFont >::n.

LaxFont * Laxkit::FontManagerCairo::MakeFont ( const char family,
const char style,
double  size,
int  nid 
)
virtual

Create and return a LaxFont, but do not store it within the fontmanager.

This family, style, and size are passed along to fontconfig. If fontconfig cannot do anything with it, NULL is returned.

Implements Laxkit::FontManager.

LaxFont * Laxkit::FontManagerCairo::MakeFontFromFile ( const char file,
double  size,
int  nid 
)
virtual

Create and return a LaxFont, but do not store it within the fontmanager.

This file and size are passed along to fontconfig. If fontconfig cannot do anything with it, NULL is returned.

Implements Laxkit::FontManager.

LaxFont * Laxkit::FontManagerCairo::MakeFontFromStr ( const char fcstr,
int  nid 
)
virtual

Add a font to the manager, based on an X Logical Font Description string.

If nid<0 then the id is from getUniqueNumber().

Implements Laxkit::FontManager.

References Laxkit::anObject::dec_count(), Laxkit::getUniqueNumber(), and Laxkit::RefPtrStack< LaxFont >::push().


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

Mon Feb 17 2014 11:52:59, Laxkit