CSdiEditWindow Class Reference

SDI editor window class. More...

#include <editwindow.h>

Inheritance diagram for CSdiEditWindow:

CBaseEditWindow

List of all members.

Public Member Functions

 CSdiEditWindow (IShader *shader, int shaderType)
 Constructor.
bool maybeSave (void)
 Asks the user to save all modified shaders.
void loadInitialShaderSource (void)
 Loads the initial shader sources into the editor.
void uploadShaderSource (IShader *shader)
 Uploads the source code to an IShader object.
void loadSourceFile (const QString &fileName)
 Loads a source code file for the shader type this edit window represents.
QString fileName (void) const
 Returns the file name if the currently opened file.


Detailed Description

SDI editor window class.

An instance of CSdiEditWindow class contains only one text editor. You need a separate window for each shader type!


Constructor & Destructor Documentation

CSdiEditWindow::CSdiEditWindow ( IShader shader,
int  shaderType 
)

Constructor.

Parameters:
shader IShader object to qurey state from. Assumes the object is already initialized.
shaderType What shader type should be supported by this window.


Member Function Documentation

bool CSdiEditWindow::maybeSave ( void   )  [virtual]

Asks the user to save all modified shaders.

Returns:
True, if the calling operation can safely continue (no data is lost). False, if the calling operation should be canceled.

Implements CBaseEditWindow.

void CSdiEditWindow::uploadShaderSource ( IShader shader  )  [virtual]

Uploads the source code to an IShader object.

Parameters:
shader IShader object where the source code should be stored.

Implements CBaseEditWindow.

void CSdiEditWindow::loadSourceFile ( const QString &  fileName  ) 

Loads a source code file for the shader type this edit window represents.

Parameters:
fileName Source code file name. If this is an emoty string, the default shader source code will be loaded.

QString CSdiEditWindow::fileName ( void   )  const

Returns the file name if the currently opened file.

If the current shader is not assigned to a file ( still 'untitled' ), this method returns an emtpty string.


The documentation for this class was generated from the following files:
Generated on Sun Mar 2 17:12:32 2008 for Shader Maker by  doxygen 1.5.4