NSScript::ScriptSnippet Class Reference

A snippet of QScript-code. More...

#include <scriptsnippet.h>

Inheritance diagram for NSScript::ScriptSnippet:

QWidget
Collaboration diagram for NSScript::ScriptSnippet:

Collaboration graph
[legend]

List of all members.

Public Types

enum  SaveLocation { SystemWide = 0, OwnJsFile = 1, PathXML = 2 }

Public Slots

void on_btnExec_clicked ()
void on_btnUndo_clicked ()
void on_btnRedo_clicked ()
void on_btnSave_clicked ()
void on_comboBoxLocation_activated (int)

Signals

void execScript (QString)
 Emit the code that is to be executed.
void destroyed (ScriptSnippet *)
 This Snippet is destroyed.
void systemSaveRequest ()
 Request the system ( normally the ScriptEnvironment ) to save the code.

Public Member Functions

 ScriptSnippet (QWidget *p)
 constructor
 ~ScriptSnippet ()
 destructor
QString saveCode () const
 Return the current code.
void setCode (QString)
 Set the code.
SaveLocation getSaveLocation () const
 Return the kind of snippet.
void setSaveLocation (SaveLocation)
 Set the kind of snippet.
QString name () const
 Return the name of this snippet.
void setName (QString)
 Set the name of this snippet.

Private Attributes

ScriptSnippet_Private_p
SaveLocation _location


Detailed Description

A snippet of QScript-code.

Todo:
Implement undo/redo

Member Enumeration Documentation

Enumerator:
SystemWide 
OwnJsFile 
PathXML 


Constructor & Destructor Documentation

NSScript::ScriptSnippet::ScriptSnippet ( QWidget p  ) 

constructor

Parameters:
p Parent QWidget

NSScript::ScriptSnippet::~ScriptSnippet (  ) 

destructor


Member Function Documentation

QString NSScript::ScriptSnippet::saveCode (  )  const

Return the current code.

void NSScript::ScriptSnippet::setCode ( QString   ) 

Set the code.

SaveLocation NSScript::ScriptSnippet::getSaveLocation (  )  const [inline]

Return the kind of snippet.

References _location.

void NSScript::ScriptSnippet::setSaveLocation ( SaveLocation   ) 

Set the kind of snippet.

QString NSScript::ScriptSnippet::name (  )  const

Return the name of this snippet.

void NSScript::ScriptSnippet::setName ( QString   ) 

Set the name of this snippet.

void NSScript::ScriptSnippet::on_btnExec_clicked (  )  [slot]

void NSScript::ScriptSnippet::on_btnUndo_clicked (  )  [slot]

void NSScript::ScriptSnippet::on_btnRedo_clicked (  )  [slot]

void NSScript::ScriptSnippet::on_btnSave_clicked (  )  [slot]

void NSScript::ScriptSnippet::on_comboBoxLocation_activated ( int   )  [slot]

void NSScript::ScriptSnippet::execScript ( QString   )  [signal]

Emit the code that is to be executed.

void NSScript::ScriptSnippet::destroyed ( ScriptSnippet  )  [signal]

This Snippet is destroyed.

Same as QObject::destroyed except for the arguments type. Because the QObjects signal is emitted in ~QObject there is no ScriptSnippet anymore and every upcast fails.

void NSScript::ScriptSnippet::systemSaveRequest (  )  [signal]

Request the system ( normally the ScriptEnvironment ) to save the code.


Member Data Documentation

Referenced by getSaveLocation().


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

Generated on Tue Apr 12 02:10:37 2011 for epos by  doxygen 1.5.5