Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

CEGUI::ImagesetManager Class Reference

Class providing a shared library of Imageset objects to the system. More...

#include <CEGUIImagesetManager.h>

Inheritance diagram for CEGUI::ImagesetManager:

Inheritance graph
[legend]
Collaboration diagram for CEGUI::ImagesetManager:

Collaboration graph
[legend]
List of all members.

Public Types

typedef ConstBaseIterator<
ImagesetRegistry > 
ImagesetIterator

Public Member Functions

 ImagesetManager (void)
 Constructor for ImagesetManager objects.
 ~ImagesetManager (void)
 Destructor for ImagesetManager objects.
ImagesetcreateImageset (const String &name, Texture *texture)
 Create a Imageset object with the given name and Texture.
ImagesetcreateImageset (const String &filename, const String &resourceGroup="")
 Create an Imageset object from the specified file.
void destroyImageset (const String &name)
 Destroys the Imageset with the specified name.
void destroyImageset (Imageset *imageset)
 Destroys the given Imageset object.
void destroyAllImagesets (void)
 Destroys all Imageset objects registered in the system.
ImagesetgetImageset (const String &name) const
 Returns a pointer to the Imageset object with the specified name.
bool isImagesetPresent (const String &name) const
 Check for the existence of a named Imageset.
void notifyScreenResolution (const Size &size)
 Notify the ImagesetManager of the current (usually new) display resolution.
ImagesetIterator getIterator (void) const
 Return a ImagesetManager::ImagesetIterator object to iterate over the available Imageset objects.

Static Public Member Functions

ImagesetManagergetSingleton (void)
 Return singleton ImagesetManager object.
ImagesetManagergetSingletonPtr (void)
 Return pointer to singleton ImagesetManager object.

Static Protected Attributes

ImagesetManagerms_Singleton = NULL

Detailed Description

Class providing a shared library of Imageset objects to the system.

The ImagesetManager is used to create, access, and destroy Imageset objects. The idea is that the ImagesetManager will function as a central repository for imagery used within the GUI system, and that such imagery can be accessed, via a unique name, by any interested party within the system.

Definition at line 54 of file CEGUIImagesetManager.h.


Member Typedef Documentation

typedef ConstBaseIterator<ImagesetRegistry> CEGUI::ImagesetManager::ImagesetIterator
 

Definition at line 217 of file CEGUIImagesetManager.h.

Referenced by getIterator().


Constructor & Destructor Documentation

CEGUI::ImagesetManager::ImagesetManager void   ) 
 

Constructor for ImagesetManager objects.

Definition at line 44 of file CEGUIImagesetManager.cpp.

References CEGUI::utf8.

CEGUI::ImagesetManager::~ImagesetManager void   ) 
 

Destructor for ImagesetManager objects.

Definition at line 53 of file CEGUIImagesetManager.cpp.

References destroyAllImagesets(), and CEGUI::utf8.


Member Function Documentation

Imageset * CEGUI::ImagesetManager::createImageset const String filename,
const String resourceGroup = ""
 

Create an Imageset object from the specified file.

Parameters:
filename String object holding the name of the Imageset definition file which should be used to create the Imageset
resourceGroup Resource group identifier to be passed to the resource manager. NB: This affects the imageset xml file only, the texture loaded may have its own group specified in the XML file.
Returns:
Pointer to the newly created Imageset object
Exceptions:
AlreadyExistsException Thrown if an Imageset named name is already present in the system.
FileIOException Thrown if something goes wrong while processing the file filename.

Definition at line 86 of file CEGUIImagesetManager.cpp.

References CEGUI::Imageset::getName(), isImagesetPresent(), and CEGUI::utf8.

Imageset * CEGUI::ImagesetManager::createImageset const String name,
Texture texture
 

Create a Imageset object with the given name and Texture.

The created Imageset will be of limited use, and will require one or more images to be defined for the set.

Parameters:
name String object containing the unique name for the Imageset being created.
texture Texture object to be associated with the Imageset
Returns:
Pointer to the newly created Imageset object
Exceptions:
AlreadyExistsException Thrown if an Imageset named name is already present in the system.

Definition at line 67 of file CEGUIImagesetManager.cpp.

References isImagesetPresent(), and CEGUI::utf8.

Referenced by CEGUI::Scheme::loadResources().

void CEGUI::ImagesetManager::destroyAllImagesets void   ) 
 

Destroys all Imageset objects registered in the system.

Returns:
Nothing

Definition at line 143 of file CEGUIImagesetManager.cpp.

References destroyImageset().

Referenced by ~ImagesetManager().

void CEGUI::ImagesetManager::destroyImageset Imageset imageset  ) 
 

Destroys the given Imageset object.

Parameters:
imageset Pointer to the Imageset to be destroyed. If no such Imageset exists, nothing happens.
Returns:
Nothing.

Definition at line 130 of file CEGUIImagesetManager.cpp.

References destroyImageset(), and CEGUI::Imageset::getName().

void CEGUI::ImagesetManager::destroyImageset const String name  ) 
 

Destroys the Imageset with the specified name.

Parameters:
name String object containing the name of the Imageset to be destroyed. If no such Imageset exists, nothing happens.
Returns:
Nothing.

Definition at line 110 of file CEGUIImagesetManager.cpp.

References CEGUI::Informative, and CEGUI::utf8.

Referenced by destroyAllImagesets(), destroyImageset(), CEGUI::Scheme::loadResources(), and CEGUI::Scheme::unloadResources().

Imageset * CEGUI::ImagesetManager::getImageset const String name  )  const
 

Returns a pointer to the Imageset object with the specified name.

Parameters:
name String object containing the name of the Imageset to return a pointer to
Returns:
Pointer to the requested Imageset object
Exceptions:
UnknownObjectException Thrown if no Imageset named name is present in within the system

Definition at line 154 of file CEGUIImagesetManager.cpp.

ImagesetManager::ImagesetIterator CEGUI::ImagesetManager::getIterator void   )  const
 

Return a ImagesetManager::ImagesetIterator object to iterate over the available Imageset objects.

Definition at line 200 of file CEGUIImagesetManager.cpp.

References ImagesetIterator.

ImagesetManager & CEGUI::ImagesetManager::getSingleton void   )  [static]
 

Return singleton ImagesetManager object.

Returns:
Singleton ImagesetManager object

Reimplemented from CEGUI::Singleton< ImagesetManager >.

Definition at line 184 of file CEGUIImagesetManager.cpp.

ImagesetManager * CEGUI::ImagesetManager::getSingletonPtr void   )  [static]
 

Return pointer to singleton ImagesetManager object.

Returns:
Pointer to singleton ImagesetManager object

Reimplemented from CEGUI::Singleton< ImagesetManager >.

Definition at line 190 of file CEGUIImagesetManager.cpp.

bool CEGUI::ImagesetManager::isImagesetPresent const String name  )  const [inline]
 

Check for the existence of a named Imageset.

Parameters:
name String object containing the name of the Imageset to look for
Returns:
true if an Imageset named name is presently loaded in the system, else false.

Definition at line 190 of file CEGUIImagesetManager.h.

Referenced by createImageset(), CEGUI::Scheme::loadResources(), and CEGUI::Scheme::resourcesLoaded().

void CEGUI::ImagesetManager::notifyScreenResolution const Size size  ) 
 

Notify the ImagesetManager of the current (usually new) display resolution.

Parameters:
size Size object describing the display resolution
Returns:
Nothing

Definition at line 171 of file CEGUIImagesetManager.cpp.

References CEGUI::Imageset::notifyScreenResolution().


Member Data Documentation

ImagesetManager * CEGUI::Singleton< ImagesetManager >::ms_Singleton = NULL [static, protected, inherited]
 

Definition at line 38 of file CEGUIImagesetManager.cpp.


The documentation for this class was generated from the following files:
Generated on Wed Feb 16 12:41:10 2005 for Crazy Eddies GUI System by  doxygen 1.3.9.1