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

pglog.h File Reference

ParaGUI logging facility. More...

#include <stdarg.h>
#include "SDL.h"
#include "paragui.h"
#include "pglabel.h"

Include dependency graph for pglog.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define PG_LOGMTH_STDOUT   1
 Logmethod: STDOUT.
#define PG_LOGMTH_STDERR   2
 Logmethod: STDERR.
#define PG_LOGMTH_CONSOLE   4
 Logmethod: CONSOLE.

Enumerations

enum  PG_LOG_LEVEL {
  PG_LOG_NONE, PG_LOG_ERR, PG_LOG_WRN, PG_LOG_MSG,
  PG_LOG_DBG
}
 ParaGUI logging level. More...

Functions

DECLSPEC void PG_Log (PG_LOG_LEVEL id, const char *Text,...)
 Log a message.
DECLSPEC void PG_LogMSG (const char *fmt,...)
 Log a message with log level "message".
DECLSPEC void PG_LogERR (const char *fmt,...)
 Log a message with log level "error".
DECLSPEC void PG_LogWRN (const char *fmt,...)
 Log a message with log level "warning".
DECLSPEC void PG_LogDBG (const char *fmt,...)
 Log a message with log level "debug".


Detailed Description

ParaGUI logging facility.

This header declares the PG_LogConsole namespace and all functions for log processing.

Definition in file pglog.h.


Define Documentation

#define PG_LOGMTH_CONSOLE   4
 

Logmethod: CONSOLE.

Send all log messages to the console window.

Definition at line 66 of file pglog.h.

Referenced by PG_Application::InitScreen().

#define PG_LOGMTH_STDERR   2
 

Logmethod: STDERR.

Send all log messages to stderr.

Definition at line 61 of file pglog.h.

#define PG_LOGMTH_STDOUT   1
 

Logmethod: STDOUT.

Send all log messages to stdout.

Definition at line 56 of file pglog.h.


Enumeration Type Documentation

enum PG_LOG_LEVEL
 

ParaGUI logging level.

Enumeration values:
PG_LOG_NONE  log nothing
PG_LOG_ERR  only errors
PG_LOG_WRN  errors and warnings
PG_LOG_MSG  display errors, warnings and messages
PG_LOG_DBG  log everything

Definition at line 44 of file pglog.h.


Function Documentation

DECLSPEC void PG_Log PG_LOG_LEVEL  id,
const char *  Text,
  ...
 

Log a message.

Parameters:
id the log level id of the message
Text a printf format string, arbitrary arguments may follow

Definition at line 271 of file pglog.cpp.

DECLSPEC void PG_LogDBG const char *  fmt,
  ...
 

Log a message with log level "debug".

Parameters:
fmt printf format string

Definition at line 300 of file pglog.cpp.

References PG_LOG_DBG.

Referenced by PG_SurfaceCache::AddSurface(), PG_Widget::eventBlit(), PG_Application::InitScreen(), PG_Application::LoadTheme(), PG_Widget::Update(), and XMLStartDoc().

DECLSPEC void PG_LogERR const char *  fmt,
  ...
 

Log a message with log level "error".

Parameters:
fmt printf format string

Definition at line 286 of file pglog.cpp.

References PG_LOG_ERR.

Referenced by PG_Application::InitScreen(), PG_Theme::Load(), PG_FileArchive::LoadSurface(), PG_Font::PG_Font(), PG_main(), PG_Font::SetName(), PG_Font::SetSize(), and XMLStartDoc().

DECLSPEC void PG_LogMSG const char *  fmt,
  ...
 

Log a message with log level "message".

Parameters:
fmt printf format log string

Definition at line 279 of file pglog.cpp.

References PG_LOG_MSG.

Referenced by PG_Theme::Load(), PG_Application::LoadTheme(), and PG_Info::PrintInfo().

DECLSPEC void PG_LogWRN const char *  fmt,
  ...
 

Log a message with log level "warning".

Parameters:
fmt printf format string

Definition at line 293 of file pglog.cpp.

References PG_LOG_WRN.

Referenced by PG_RectList::Add(), PG_FontEngine::BlitFTBitmap(), PG_FontEngine::FontEngineError(), PG_Theme::Load(), PG_FileArchive::LoadSurface(), PG_Application::LoadTheme(), PG_Application::PG_Application(), PG_Draw::CreateRGBSurface(), PG_Layout::Load(), PG_Widget::PG_Widget(), PG_FileArchive::RemoveAllArchives(), PG_Application::SetBackground(), PG_Application::SetIcon(), XMLStartDoc(), and PG_Widget::~PG_Widget().


Generated on Tue Jun 24 01:59:53 2008 for Advanced Strategic Command by  doxygen 1.4.2