diff options
author | Darrell Anderson <humanreadable@yahoo.com> | 2013-03-02 15:57:34 -0600 |
---|---|---|
committer | Darrell Anderson <humanreadable@yahoo.com> | 2013-03-02 15:57:34 -0600 |
commit | 7c0b0c9dc9fcbe9c198925bdc7ee18ac6be49f4f (patch) | |
tree | c76702a7f6310fbe9d437e347535422e836e94e9 /tdeparts/tests/notepad.h | |
parent | a2a38be7600e2a2c2b49c66902d912ca036a2c0f (diff) | |
parent | 27bbee9a5f9dcda53d8eb23863ee670ad1360e41 (diff) | |
download | tdelibs-7c0b0c9dc9fcbe9c198925bdc7ee18ac6be49f4f.tar.gz tdelibs-7c0b0c9dc9fcbe9c198925bdc7ee18ac6be49f4f.zip |
Merge branch 'master' of http://scm.trinitydesktop.org/scm/git/tdelibs
Diffstat (limited to 'tdeparts/tests/notepad.h')
-rw-r--r-- | tdeparts/tests/notepad.h | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/tdeparts/tests/notepad.h b/tdeparts/tests/notepad.h new file mode 100644 index 000000000..bd502599b --- /dev/null +++ b/tdeparts/tests/notepad.h @@ -0,0 +1,42 @@ + +#ifndef __notepad_h__ +#define __notepad_h__ + +#include <tdeparts/genericfactory.h> +#include <tdeparts/part.h> + +class TDEAboutData; +class TQMultiLineEdit; + +/** + * Who said writing a part should be complex ? :-) + * Here is a very simple kedit-like part + * @internal + */ +class NotepadPart : public KParts::ReadWritePart +{ + Q_OBJECT +public: + NotepadPart( TQWidget*, const char* widgetName, + TQObject* parent, const char* name, + const TQStringList& args = TQStringList() ); + virtual ~NotepadPart(); + + virtual void setReadWrite( bool rw ); + + static TDEAboutData* createAboutData(); + +protected: + virtual bool openFile(); + virtual bool saveFile(); + +protected slots: + void slotSearchReplace(); + +protected: + TQMultiLineEdit * m_edit; +}; + +typedef KParts::GenericFactory<NotepadPart> NotepadFactory; + +#endif |