Something went wrong on our end
-
andreas authored
shell / readded direct display of pytho output (this time buffered) git-svn-id: https://dng.biozentrum.unibas.ch/svn/openstructure/trunk@2420 5a81b35b-ba03-0410-adc8-b2c5c5119f08
andreas authoredshell / readded direct display of pytho output (this time buffered) git-svn-id: https://dng.biozentrum.unibas.ch/svn/openstructure/trunk@2420 5a81b35b-ba03-0410-adc8-b2c5c5119f08
transition_guard.hh 1.19 KiB
#ifndef TRANSITION_GUARD_HH
#define TRANSITION_GUARD_HH
#include <QObject>
#include "python_shell_fw.hh"
#include "python_interpreter.hh"
namespace ost { namespace gui {
//fw decl
class ShellHistory;
class PythonShellWidget;
class TransitionGuard: public QObject
{
Q_OBJECT
public:
TransitionGuard();
virtual bool check();
};
class HistoryGuard : public TransitionGuard
{
public:
HistoryGuard(ShellHistory* history, BlockEditMode mode);
virtual bool check();
protected:
ShellHistory* history_;
BlockEditMode mode_;
};
class EditPositionGuard : public TransitionGuard
{
public:
enum FLAGS{
ALWAYSTRUE=0,
SMALLER=1,
EQUAL=2,
BIGGER=4,
ANCHORSMALLER=8,
ANCHOREQUAL=16,
ANCHORBIGGER=32
};
EditPositionGuard(PythonShellWidget* shell,int flags1, int flags2=ALWAYSTRUE);
virtual bool check();
protected:
virtual bool check_flag(int flag);
PythonShellWidget* shell_;
int flags1_;
int flags2_;
};
class BlockStatusGuard : public TransitionGuard
{
public:
BlockStatusGuard(PythonShellWidget* shell, int status);
virtual bool check();
protected:
PythonShellWidget* shell_;
int status_;
};
}} //ns
#endif // TRANSITION_GUARD_HH