diff -r 1cc73bd7ee1f -r e95081c21da2 texteditor.h --- a/texteditor.h Tue Sep 05 09:47:13 2006 +0000 +++ b/texteditor.h Tue Sep 05 09:47:14 2006 +0000 @@ -1,12 +1,11 @@ -/* emacs: -*- Mode: C; c-style: "bsd"; c-basic-offset: 4; c-recognize-knr-p: nil; -*- */ #ifndef TEXTEDITOR_H #define TEXTEDITOR_H -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include enum EditorState {inactiveEditor,emptyEditor,filledEditor}; @@ -29,7 +28,7 @@ QString getFilename (); void setFilenameHint (const QString&); QString getFilenameHint (); - bool findText(const QString &, const bool &); // find Text + bool findText(const QString &, const QTextDocument::FindFlags &); // find Text protected: void setupFileActions(); @@ -79,6 +78,7 @@ void verticalAlignmentChanged(int a); void enableActions(); void disableActions(); + void setState (EditorState); private: QPrinter *printer; @@ -127,7 +127,7 @@ *actionAlignSuperScript; }; -/* Wraps currentVerticalAlignmentChanged(VerticalAlignment) +/* FIXME Wraps currentVerticalAlignmentChanged(VerticalAlignment) * to currentVerticalAlignmentChanged(int) * this way the signal can be used without use of the internal * VerticalAlignment enum of QTextEdit @@ -139,22 +139,27 @@ { Q_OBJECT; public: - MyTextEdit(QWidget *parent, const char *name) : QTextEdit(parent, name) { - connect(this, - SIGNAL(currentVerticalAlignmentChanged(VerticalAlignment)), - this, - SLOT(verticalAlignmentChanged(VerticalAlignment))); + MyTextEdit(QWidget *parent, const char *name) : QTextEdit(parent, name) + { + /* + connect( + this, SIGNAL(currentVerticalAlignmentChanged(VerticalAlignment)), + this, SLOT(verticalAlignmentChanged(VerticalAlignment))); + */ } - int verticalAlignment() const { return m_verticalAlignment; } +// int verticalAlignment() const { return m_verticalAlignment; } signals: - void currentVerticalAlignmentChanged(int a); +// void currentVerticalAlignmentChanged(int a); public slots: - void verticalAlignmentChanged(VerticalAlignment a) { - m_verticalAlignment = a; - emit currentVerticalAlignmentChanged((int)a); + /* + void verticalAlignmentChanged(VerticalAlignment a) + { + m_verticalAlignment = a; + emit currentVerticalAlignmentChanged((int)a); } +*/ private: - int m_verticalAlignment; +// int m_verticalAlignment; }; #endif