Main Page   Class Hierarchy   Compound List   File List   Compound Members  

iConsoleOutput Struct Reference

This is the Crystal Space Console interface. More...

#include <conout.h>

Inheritance diagram for iConsoleOutput:

iBase List of all members.

Public Methods

virtual void PutText (const char *iText,...)=0
 Put some text to the console. More...

virtual void PutTextV (const char *iText, va_list args)=0
 Var_args version of PutText.

virtual const char* GetLine (int iLine=-1) const=0
 Return a line from the buffer (-1 = current line).

virtual void Draw2D (csRect *oRect=NULL)=0
 Display the console and return the dirty rectangle. More...

virtual void Draw3D (csRect *oRect=NULL)=0
 Update the 3D part of the console on the window. More...

virtual void Clear (bool iWipe=false)=0
 Clear console. More...

virtual void SetBufferSize (int iMaxLines)=0
 Set the buffer size in lines.

virtual bool GetTransparency () const=0
 Retrieve the transparency setting.

virtual void SetTransparency (bool iTransp)=0
 Set transparency.

virtual iFontGetFont () const=0
 Gets the current font.

virtual void SetFont (iFont *Font)=0
 Sets the type of the font.

virtual int GetTopLine () const=0
 Get the current top line being displayed.

virtual void ScrollTo (int iTopLine, bool iSnap=true)=0
 Set the current top line, or use of the constants above for scrolling. More...

virtual int GetCursorStyle () const=0
 Retrieve the cursor style.

virtual void SetCursorStyle (int iStyle)=0
 Assign the cursor style.

virtual void SetVisible (bool iShow)=0
 Show/hide the console. More...

virtual bool GetVisible ()=0
 Query whether the console is visible or hidden.

virtual void AutoUpdate (bool iAutoUpdate)=0
 Enable or disable automatic console updates. More...

virtual void SetCursorPos (int iCharNo)=0
 Set cursor horizontal position (-1 == follow output).

virtual int GetMaxLineWidth ()=0
 Query maximal line width in characters.

virtual void RegisterWatcher (iConsoleWatcher *)=0
 Tell console that this object should be notified when console visibility status changes.

virtual bool PerformExtension (const char *iCommand,...)=0
 Implement simple extension commands.

virtual bool PerformExtensionV (const char *iCommand, va_list)=0
 Implement simple extension commands.

Detailed Description

This is the Crystal Space Console interface.

It is an output only system. It can be used in conjunction with the iConsoleInput interface to form an interactive console.

Member Function Documentation

void iConsoleOutput::AutoUpdate ( bool iAutoUpdate ) [pure virtual]

Enable or disable automatic console updates.

When the console is in console auto-update mode, it automatically calls BeginDraw/Console->Draw methods on every PutText call. Otherwise it is your responsability to call Draw() at appropiate times. Initially this mode is enabled.

void iConsoleOutput::Clear ( bool iWipe = false ) [pure virtual]

Clear console.

If wipe = false, it just moves the top line to the current line; if wipe is true, it clears the buffer completely.

void iConsoleOutput::Draw2D ( csRect * oRect = NULL ) [pure virtual]

Display the console and return the dirty rectangle.

The graphics driver should be in 2D draw mode.

void iConsoleOutput::Draw3D ( csRect * oRect = NULL ) [pure virtual]

Update the 3D part of the console on the window.

The graphics driver should be in 3D draw mode.

void iConsoleOutput::PutText ( const char * iText,
... ) [pure virtual]

Put some text to the console.

Console acts like a simple TTY and should interpret basical symbols like '
' and '\b'. The '\r' character has a special meaning: it sets a flag that tells console to clear the current line before next character is output. That is, you can emmit non-persistent messages this way: PutText ("some text\r"); This message will disappear as soon as any other message will be sent to console.

void iConsoleOutput::ScrollTo ( int iTopLine,
bool iSnap = true ) [pure virtual]

Set the current top line, or use of the constants above for scrolling.

If snap is true, the console returns to the very bottom of the display when a new line is printed.

void iConsoleOutput::SetVisible ( bool iShow ) [pure virtual]

Show/hide the console.

In 'hidden' state console should not display anything at all (when Draw() is called) or draw some minimal information

The documentation for this struct was generated from the following file:
Generated for Crystal Space by doxygen 1.2.5 written by Dimitri van Heesch, ©1997-2000