]> git.saurik.com Git - wxWidgets.git/blame_incremental - include/wx/gtk/tooltip.h
(blind) compilation fixes after latest changes
[wxWidgets.git] / include / wx / gtk / tooltip.h
... / ...
CommitLineData
1/////////////////////////////////////////////////////////////////////////////
2// Name: tooltip.h
3// Purpose: wxToolTip class
4// Author: Robert Roebling
5// Id: $Id$
6// Copyright: (c) 1998 Robert Roebling
7// Licence: wxWindows licence
8/////////////////////////////////////////////////////////////////////////////
9
10#ifndef __GTKTOOLTIPH__
11#define __GTKTOOLTIPH__
12
13#include "wx/defs.h"
14#include "wx/string.h"
15#include "wx/object.h"
16
17//-----------------------------------------------------------------------------
18// forward declarations
19//-----------------------------------------------------------------------------
20
21class WXDLLIMPEXP_CORE wxToolTip;
22class WXDLLIMPEXP_CORE wxWindow;
23
24//-----------------------------------------------------------------------------
25// wxToolTip
26//-----------------------------------------------------------------------------
27
28class WXDLLIMPEXP_CORE wxToolTip : public wxObject
29{
30public:
31 wxToolTip( const wxString &tip );
32
33 // globally change the tooltip parameters
34 static void Enable( bool flag );
35 static void SetDelay( long msecs );
36
37 // get/set the tooltip text
38 void SetTip( const wxString &tip );
39 wxString GetTip() const { return m_text; }
40
41 wxWindow *GetWindow() const { return m_window; }
42 bool IsOk() const { return m_window != NULL; }
43
44
45 // wxGTK-only from now on
46
47 // this forwards back to wxWindow::ApplyToolTip()
48 void Apply( wxWindow *win );
49
50 // this just sets the given tooltip for the specified widget
51 //
52 // tip must be already UTF-8 encoded
53 static void Apply(GtkWidget *w, const wxCharBuffer& tip);
54
55private:
56 wxString m_text;
57 wxWindow *m_window;
58
59 DECLARE_ABSTRACT_CLASS(wxToolTip)
60};
61
62#endif // __GTKTOOLTIPH__