]>
Commit | Line | Data |
---|---|---|
90b1b133 | 1 | ///////////////////////////////////////////////////////////////////////////// |
8ef94bfc | 2 | // Name: wx/gtk1/tooltip.h |
ff8bfdbb | 3 | // Purpose: wxToolTip class |
90b1b133 | 4 | // Author: Robert Roebling |
371a5b4e | 5 | // Copyright: (c) 1998 Robert Roebling |
65571936 | 6 | // Licence: wxWindows licence |
90b1b133 RR |
7 | ///////////////////////////////////////////////////////////////////////////// |
8 | ||
9 | #ifndef __GTKTOOLTIPH__ | |
10 | #define __GTKTOOLTIPH__ | |
11 | ||
90b1b133 | 12 | #include "wx/defs.h" |
ff8bfdbb | 13 | #include "wx/string.h" |
90b1b133 | 14 | #include "wx/object.h" |
90b1b133 RR |
15 | |
16 | //----------------------------------------------------------------------------- | |
ff8bfdbb | 17 | // forward declarations |
90b1b133 RR |
18 | //----------------------------------------------------------------------------- |
19 | ||
b5dbe15d VS |
20 | class WXDLLIMPEXP_FWD_CORE wxToolTip; |
21 | class WXDLLIMPEXP_FWD_CORE wxWindow; | |
90b1b133 RR |
22 | |
23 | //----------------------------------------------------------------------------- | |
24 | // wxToolTip | |
25 | //----------------------------------------------------------------------------- | |
26 | ||
20123d49 | 27 | class WXDLLIMPEXP_CORE wxToolTip : public wxObject |
90b1b133 RR |
28 | { |
29 | public: | |
ff8bfdbb | 30 | // globally change the tooltip parameters |
301cd871 RR |
31 | static void Enable( bool flag ); |
32 | static void SetDelay( long msecs ); | |
becac1ef VZ |
33 | // set the delay after which the tooltip disappears or how long the tooltip remains visible |
34 | static void SetAutoPop(long msecs); | |
35 | // set the delay between subsequent tooltips to appear | |
36 | static void SetReshow(long msecs); | |
90b1b133 | 37 | |
ff8bfdbb VZ |
38 | wxToolTip( const wxString &tip ); |
39 | ||
40 | // get/set the tooltip text | |
41 | void SetTip( const wxString &tip ); | |
42 | wxString GetTip() const { return m_text; } | |
43 | ||
44 | wxWindow *GetWindow() const { return m_window; } | |
45 | bool IsOk() const { return m_window != NULL; } | |
46 | ||
47 | // implementation | |
48 | void Apply( wxWindow *win ); | |
49 | ||
50 | private: | |
b1170810 | 51 | wxString m_text; |
301cd871 | 52 | wxWindow *m_window; |
b342f8f0 RD |
53 | |
54 | DECLARE_ABSTRACT_CLASS(wxToolTip) | |
90b1b133 RR |
55 | }; |
56 | ||
57 | #endif // __GTKTOOLTIPH__ |