00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _KTEXT_BROWSER_H_
00021 #define _KTEXT_BROWSER_H_
00022
00023 #include <qtextbrowser.h>
00024
00038 class KTextBrowser : public QTextBrowser
00039 {
00040 Q_OBJECT
00041 Q_PROPERTY( bool notifyClick READ isNotifyClick WRITE setNotifyClick )
00042
00043 public:
00051 KTextBrowser( QWidget *parent=0, const char *name=0,
00052 bool notifyClick=false );
00053
00057 ~KTextBrowser( void );
00058
00065 void setNotifyClick( bool notifyClick );
00070 bool isNotifyClick() const;
00071
00072 protected:
00077 void setSource(const QString& name);
00078
00082 virtual void keyPressEvent(QKeyEvent *e);
00083
00087 virtual void viewportMouseMoveEvent( QMouseEvent* e);
00088
00092 virtual void contentsWheelEvent( QWheelEvent *e );
00093
00094 signals:
00102 void mailClick( const QString &name, const QString &address );
00103
00110 void urlClick( const QString &url );
00111
00112 private:
00113 bool mNotifyClick;
00114
00115 protected:
00116 virtual void virtual_hook( int id, void* data );
00117 private:
00118 class KTextBrowserPrivate;
00119 KTextBrowserPrivate *d;
00120 };
00121
00122 #endif