diff options
Diffstat (limited to 'lib/kofficeui/KoContextCelp.h')
-rw-r--r-- | lib/kofficeui/KoContextCelp.h | 141 |
1 files changed, 75 insertions, 66 deletions
diff --git a/lib/kofficeui/KoContextCelp.h b/lib/kofficeui/KoContextCelp.h index 07f80d8f..36c51366 100644 --- a/lib/kofficeui/KoContextCelp.h +++ b/lib/kofficeui/KoContextCelp.h @@ -20,37 +20,39 @@ #ifndef __KOCONTEXTHELPACTION_H__ #define __KOCONTEXTHELPACTION_H__ -#include <qwidget.h> -#include <qbitmap.h> -#include <qdockwindow.h> +#include <tqwidget.h> +#include <tqbitmap.h> +#include <tqdockwindow.h> #include <kaction.h> #include <koffice_export.h> -class QPixmap; -class QLabel; -class QSimpleRichText; +class TQPixmap; +class TQLabel; +class TQSimpleRichText; -class KoVerticalLabel : public QWidget +class KoVerticalLabel : public TQWidget { Q_OBJECT + TQ_OBJECT public: - KoVerticalLabel( QWidget* parent = 0, const char* name = 0 ); + KoVerticalLabel( TQWidget* tqparent = 0, const char* name = 0 ); ~KoVerticalLabel(); public slots: - void setText( const QString& text ); + void setText( const TQString& text ); protected: - void paintEvent( QPaintEvent* ); + void paintEvent( TQPaintEvent* ); private: - QString m_text; + TQString m_text; }; // KoVerticalLabel -class KoHelpNavButton : public QWidget +class KoHelpNavButton : public TQWidget { Q_OBJECT + TQ_OBJECT public: enum NavDirection { @@ -58,25 +60,26 @@ class KoHelpNavButton : public QWidget Down }; - KoHelpNavButton( NavDirection d, QWidget* parent ); + KoHelpNavButton( NavDirection d, TQWidget* tqparent ); signals: void pressed(); void released(); protected: - void paintEvent( QPaintEvent* ); - void enterEvent( QEvent* ); - void leaveEvent( QEvent* ); + void paintEvent( TQPaintEvent* ); + void enterEvent( TQEvent* ); + void leaveEvent( TQEvent* ); private: - QBitmap m_bitmap; + TQBitmap m_bitmap; bool m_pressed; }; // KoHelpNavButton -class KoTinyButton : public QWidget +class KoTinyButton : public TQWidget { Q_OBJECT + TQ_OBJECT public: enum Action { @@ -84,62 +87,64 @@ class KoTinyButton : public QWidget Sticky }; - KoTinyButton( Action a, QWidget* parent ); + KoTinyButton( Action a, TQWidget* tqparent ); signals: void clicked(); void toggled( bool ); protected: - void paintEvent( QPaintEvent* ); - void mousePressEvent( QMouseEvent* ); - void mouseReleaseEvent( QMouseEvent* ); + void paintEvent( TQPaintEvent* ); + void mousePressEvent( TQMouseEvent* ); + void mouseReleaseEvent( TQMouseEvent* ); private: - QBitmap m_bitmap; + TQBitmap m_bitmap; bool m_pressed; Action m_action; bool m_toggled; }; // KoTinyButton -class KoHelpView : public QWidget +class KoHelpView : public TQWidget { Q_OBJECT + TQ_OBJECT public: - KoHelpView( QWidget* parent ); + KoHelpView( TQWidget* tqparent ); ~KoHelpView(); - void setText( const QString& text ); - bool eventFilter( QObject* watched, QEvent* e ); + void setText( const TQString& text ); + bool eventFilter( TQObject* watched, TQEvent* e ); signals: - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); protected: - virtual void mousePressEvent( QMouseEvent* e ); - virtual void mouseReleaseEvent( QMouseEvent* e ); - virtual void mouseMoveEvent( QMouseEvent* e ); - virtual void paintEvent( QPaintEvent* e ); + virtual void mousePressEvent( TQMouseEvent* e ); + virtual void mouseReleaseEvent( TQMouseEvent* e ); + virtual void mouseMoveEvent( TQMouseEvent* e ); + virtual void paintEvent( TQPaintEvent* e ); private: - QSimpleRichText* currentText; - QString currentAnchor; + TQSimpleRichText* currentText; + TQString currentAnchor; }; // KoHelpView -class KoHelpWidget : public QWidget +class KoHelpWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - KoHelpWidget( QString help, QWidget* parent ); + KoHelpWidget( TQString help, TQWidget* tqparent ); - void setText( QString text ); - void timerEvent( QTimerEvent* ); + void setText( TQString text ); + void timerEvent( TQTimerEvent* ); void updateButtons(); signals: - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); public slots: void scrollUp(); @@ -149,12 +154,12 @@ class KoHelpWidget : public QWidget void stopScrolling(); protected: - void resizeEvent( QResizeEvent* ); + void resizeEvent( TQResizeEvent* ); private: int m_ypos; bool m_scrollDown; - QWidget* m_helpViewport; + TQWidget* m_helpViewport; KoHelpView* m_helpView; KoHelpNavButton* m_upButton; KoHelpNavButton* m_downButton; @@ -163,42 +168,43 @@ class KoHelpWidget : public QWidget /** * KoContextHelpPopup is the popup displayed by ContextHelpAction. */ -class KoContextHelpPopup : public QWidget +class KoContextHelpPopup : public TQWidget { Q_OBJECT + TQ_OBJECT public: - KoContextHelpPopup( QWidget* parent = 0 ); + KoContextHelpPopup( TQWidget* tqparent = 0 ); ~KoContextHelpPopup(); public slots: - void setContextHelp( const QString& title, const QString& text, const QPixmap* icon = 0 ); + void setContextHelp( const TQString& title, const TQString& text, const TQPixmap* icon = 0 ); void setSticky( bool sticky ) { m_isSticky = sticky; } protected: - virtual void mousePressEvent( QMouseEvent* ); - virtual void mouseMoveEvent( QMouseEvent* ); - virtual void resizeEvent( QResizeEvent* ); - virtual void paintEvent( QPaintEvent* ); + virtual void mousePressEvent( TQMouseEvent* ); + virtual void mouseMoveEvent( TQMouseEvent* ); + virtual void resizeEvent( TQResizeEvent* ); + virtual void paintEvent( TQPaintEvent* ); virtual void windowActivationChange( bool ); - virtual void keyPressEvent ( QKeyEvent* ); - virtual void keyReleaseEvent ( QKeyEvent* ); + virtual void keyPressEvent ( TQKeyEvent* ); + virtual void keyReleaseEvent ( TQKeyEvent* ); signals: void wantsToBeClosed(); /** * Connect to this signal to receive the href value of the links clicked. */ - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); private: KoHelpWidget* m_helpViewer; KoVerticalLabel* m_helpTitle; - QLabel* m_helpIcon; + TQLabel* m_helpIcon; KoTinyButton* m_close; KoTinyButton* m_sticky; - QPoint m_mousePos; + TQPoint m_mousePos; bool m_isSticky; }; // KoContextHelpPopup @@ -211,69 +217,72 @@ class KoContextHelpPopup : public QWidget class KOFFICEUI_EXPORT KoContextHelpAction : public KToggleAction { Q_OBJECT + TQ_OBJECT public: - KoContextHelpAction( KActionCollection* parentCollection, QWidget* parent = 0 ); + KoContextHelpAction( KActionCollection* tqparentCollection, TQWidget* tqparent = 0 ); virtual ~KoContextHelpAction(); public slots: - void updateHelp( const QString& title, const QString& text, const QPixmap* icon = 0 ); + void updateHelp( const TQString& title, const TQString& text, const TQPixmap* icon = 0 ); void closePopup(); signals: /** * Connect to this signal to receive the href value of the links clicked. */ - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); private: KoContextHelpPopup* m_popup; }; // KoContextHelpAction -class KoContextHelpWidget : public QWidget +class KoContextHelpWidget : public TQWidget { Q_OBJECT + TQ_OBJECT public: - KoContextHelpWidget( QWidget* parent = 0, const char* name = 0 ); + KoContextHelpWidget( TQWidget* tqparent = 0, const char* name = 0 ); ~KoContextHelpWidget(); public slots: - void setContextHelp( const QString& title, const QString& text, const QPixmap* icon = 0 ); + void setContextHelp( const TQString& title, const TQString& text, const TQPixmap* icon = 0 ); signals: /** * Connect to this signal to receive the href value of the links clicked. */ - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); private: KoHelpWidget* m_helpViewer; KoVerticalLabel* m_helpTitle; - QLabel* m_helpIcon; + TQLabel* m_helpIcon; }; // KoContextHelpWidget -class KoContextHelpDocker : public QDockWindow +class KoContextHelpDocker : public TQDockWindow { Q_OBJECT + TQ_OBJECT public: - KoContextHelpDocker( QWidget* parent = 0, const char* name = 0 ); + KoContextHelpDocker( TQWidget* tqparent = 0, const char* name = 0 ); ~KoContextHelpDocker(); public slots: - void setContextHelp( const QString& title, const QString& text, const QPixmap* icon = 0 ); + void setContextHelp( const TQString& title, const TQString& text, const TQPixmap* icon = 0 ); signals: /** * Connect to this signal to receive the href value of the links clicked. */ - void linkClicked( const QString& link ); + void linkClicked( const TQString& link ); private: KoHelpWidget* m_helpViewer; KoVerticalLabel* m_helpTitle; - QLabel* m_helpIcon; + TQLabel* m_helpIcon; }; // KoContextHelpDocker #endif /* __KOCONTEXTHELPACTION_H__ */ |