summaryrefslogblamecommitdiffstats
path: root/desktop-widgets/textedit.h
blob: 1b90c02489844d512e8085e0e58c0851448f6c55 (plain) (tree)


















                                                                               
// SPDX-License-Identifier: GPL-2.0
#ifndef TEXTEDIT_H
#define TEXTEDIT_H

#include <QTextEdit>

// QTextEdit does not possess a signal that fires when the user finished
// editing the text. This subclass therefore overrides the focusOutEvent
// and sends the textEdited signal.
class TextEdit : public QTextEdit {
	Q_OBJECT
public:
	using QTextEdit::QTextEdit; // Make constructors of QTextEdit available
signals:
	void editingFinished();
private:
	void focusOutEvent(QFocusEvent *ev) override;
};

#endif