2008-03-08 08:52:38 -05:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: tooltip.h
|
2008-03-10 11:24:38 -04:00
|
|
|
// Purpose: interface of wxToolTip
|
2008-03-08 08:52:38 -05:00
|
|
|
// Author: wxWidgets team
|
|
|
|
// RCS-ID: $Id$
|
|
|
|
// Licence: wxWindows license
|
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
/**
|
|
|
|
@class wxToolTip
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-05-08 16:46:34 -04:00
|
|
|
This class holds information about a tooltip associated with a window (see
|
|
|
|
wxWindow::SetToolTip()).
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-05-08 16:46:34 -04:00
|
|
|
The four static methods, wxToolTip::Enable(), wxToolTip::SetDelay()
|
|
|
|
wxToolTip::SetAutoPop() and wxToolTip::SetReshow() can be used to globally
|
2008-03-08 08:52:38 -05:00
|
|
|
alter tooltips behaviour.
|
2008-03-08 09:43:31 -05:00
|
|
|
|
2008-03-08 08:52:38 -05:00
|
|
|
@library{wxcore}
|
|
|
|
@category{help}
|
|
|
|
*/
|
|
|
|
class wxToolTip : public wxObject
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
/**
|
|
|
|
Constructor.
|
|
|
|
*/
|
|
|
|
wxToolTip(const wxString& tip);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Enable or disable tooltips globally.
|
2008-05-08 16:46:34 -04:00
|
|
|
|
|
|
|
@note May not be supported on all platforms (eg. wxCocoa).
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
static void Enable(bool flag);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Get the tooltip text.
|
|
|
|
*/
|
2008-03-09 12:24:26 -04:00
|
|
|
wxString GetTip() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
Get the associated window.
|
|
|
|
*/
|
2008-03-09 12:24:26 -04:00
|
|
|
wxWindow* GetWindow() const;
|
2008-03-08 08:52:38 -05:00
|
|
|
|
|
|
|
/**
|
2008-05-08 16:46:34 -04:00
|
|
|
Set the delay after which the tooltip disappears or how long a tooltip
|
|
|
|
remains visible.
|
|
|
|
|
|
|
|
@note May not be supported on all platforms (eg. wxCocoa, GTK, Palmos).
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
static void SetAutoPop(long msecs);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Set the delay after which the tooltip appears.
|
2008-05-08 16:46:34 -04:00
|
|
|
|
|
|
|
@note May not be supported on all platforms (eg. wxCocoa).
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
static void SetDelay(long msecs);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Set the delay between subsequent tooltips to appear.
|
2008-05-08 16:46:34 -04:00
|
|
|
|
|
|
|
@note May not be supported on all platforms (eg. wxCocoa, GTK, Palmos).
|
2008-03-08 08:52:38 -05:00
|
|
|
*/
|
|
|
|
static void SetReshow(long msecs);
|
|
|
|
|
|
|
|
/**
|
|
|
|
Set the tooltip text.
|
|
|
|
*/
|
|
|
|
void SetTip(const wxString& tip);
|
|
|
|
};
|
2008-03-10 11:24:38 -04:00
|
|
|
|