/***************************************************************************
                          dcqtextedit.h  -  description
                             -------------------
    begin                : Don Aug 21 2003
    copyright            : (C) 2003 by Mathias Küster
    email                : mathen@users.berlios.de
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef DCQTEXTEDIT_H
#define DCQTEXTEDIT_H

#include <QWidget>
#include <QTextEdit>
#include <QMouseEvent>

/**
  *@author Mathias Küster
  */

class DCQTextEdit : public QTextEdit {
Q_OBJECT

public:
	/** construtor */
	DCQTextEdit( QWidget * parent = 0 );
	/** destructor */
	virtual ~DCQTextEdit();

	/** Return nick of user that was get by mice middle button click*/
	QString getMBNick();

protected:
	/** */
	virtual void mouseReleaseEvent( QMouseEvent * event );
	/** */
	virtual void mouseDoubleClickEvent( QMouseEvent * event );

signals:
	/** */
	void clicked();
	/** */
	void doubleClicked();

private:

        QString _mbnick;
};

#endif
