Version: 3.1.0
wxTaskBarButton Class Reference

#include <wx/taskbarbutton.h>

Detailed Description

A taskbar button that associated with the window under Windows 7 or later.

It is used to access the functionality including thumbnail representations, thumbnail toolbars, notification and status overlays, and progress indicators.

Note
This class is only created and initialized in the internal implementation of wxFrame by design. You can only get the pointer of the instance which associated with the frame by calling wxFrame::MSWGetTaskBarButton().

Library:  wxCore
Category:  Miscellaneous
Implementations:  native under wxMSW port; a generic implementation is used elsewhere.
Availability:  only available for the wxMSW port.
See also
wxFrame::MSWGetTaskBarButton()
Since
3.1.0

Public Member Functions

virtual void SetProgressRange (int range)
 Starts showing a determinate progress indicator. More...
 
virtual void SetProgressValue (int value)
 Update the progress indicator, setting the progress to the new value . More...
 
virtual void PulseProgress ()
 Makes the progress indicator run in indeterminate mode. More...
 
virtual void Show (bool show=true)
 Show in the taskbar. More...
 
virtual void Hide ()
 Hide in the taskbar. More...
 
virtual void SetThumbnailTooltip (const wxString &tooltip)
 Specifies or updates the text of the tooltip that is displayed when the mouse pointer rests on an individual preview thumbnail in a taskbar button flyout. More...
 
virtual void SetProgressState (wxTaskBarButtonState state)
 Set the state of the progress indicator displayed on a taskbar button. More...
 
virtual void SetOverlayIcon (const wxIcon &icon, const wxString &description=wxString())
 Set an overlay icon to indicate application status or a notification top the user. More...
 
virtual void SetThumbnailClip (const wxRect &rect)
 Selects a portion of a window's client area to display as that window's thumbnail in the taskbar. More...
 
virtual void SetThumbnailContents (const wxWindow *child)
 Selects the child window area to display as that window's thumbnail in the taskbar. More...
 
virtual bool InsertThumbBarButton (size_t pos, wxThumbBarButton *button)
 Inserts the given button before the position pos to the taskbar thumbnail toolbar. More...
 
virtual bool AppendThumbBarButton (wxThumbBarButton *button)
 Appends a button to the taskbar thumbnail toolbar. More...
 
virtual bool AppendSeparatorInThumbBar ()
 Appends a separator to the taskbar thumbnail toolbar. More...
 
virtual wxThumbBarButtonRemoveThumbBarButton (wxThumbBarButton *button)
 Removes the thumbnail toolbar button from the taskbar button but doesn't delete the associated c++ object. More...
 
virtual wxThumbBarButtonRemoveThumbBarButton (int id)
 Removes the thumbnail toolbar button from the taskbar button but doesn't delete the associated c++ object. More...
 

Member Function Documentation

virtual bool wxTaskBarButton::AppendSeparatorInThumbBar ( )
virtual

Appends a separator to the taskbar thumbnail toolbar.

Note
The number of buttons and separators is limited to 7.
See also
AppendThumbBarButton(), InsertThumbBarButton()
virtual bool wxTaskBarButton::AppendThumbBarButton ( wxThumbBarButton button)
virtual

Appends a button to the taskbar thumbnail toolbar.

Note
The number of buttons and separators is limited to 7.
See also
InsertThumbBarButton(), AppendSeparatorInThumbBar()
virtual void wxTaskBarButton::Hide ( )
virtual

Hide in the taskbar.

virtual bool wxTaskBarButton::InsertThumbBarButton ( size_t  pos,
wxThumbBarButton button 
)
virtual

Inserts the given button before the position pos to the taskbar thumbnail toolbar.

Note
The number of buttons and separators is limited to 7.
See also
AppendThumbBarButton(), AppendSeparatorInThumbBar()
virtual void wxTaskBarButton::PulseProgress ( )
virtual

Makes the progress indicator run in indeterminate mode.

The first call to this method starts showing the indeterminate progress indicator if it hadn't been shown yet.

Call SetProgressRange(0) to stop showing the progress indicator.

virtual wxThumbBarButton* wxTaskBarButton::RemoveThumbBarButton ( wxThumbBarButton button)
virtual

Removes the thumbnail toolbar button from the taskbar button but doesn't delete the associated c++ object.

Parameters
buttonThe thumbnail toolbar button to remove.
Returns
A pointer to the button which was detached from the taskbar button.
virtual wxThumbBarButton* wxTaskBarButton::RemoveThumbBarButton ( int  id)
virtual

Removes the thumbnail toolbar button from the taskbar button but doesn't delete the associated c++ object.

Parameters
idThe identifier of the thumbnail toolbar button to remove.
Returns
A pointer to the button which was detached from the taskbar button.
virtual void wxTaskBarButton::SetOverlayIcon ( const wxIcon icon,
const wxString description = wxString() 
)
virtual

Set an overlay icon to indicate application status or a notification top the user.

Parameters
iconThis should be a small icon, measuring 16x16 pixels at 96 dpi. If an overlay icon is already applied to the taskbar button, that existing overlay is replaced. Setting with wxNullIcon to remove.
descriptionThe property holds the description of the overlay for accessibility purposes.
virtual void wxTaskBarButton::SetProgressRange ( int  range)
virtual

Starts showing a determinate progress indicator.

Call SetProgressValue() after this call to update the progress indicator.

If range is 0, the progress indicator is dismissed.

virtual void wxTaskBarButton::SetProgressState ( wxTaskBarButtonState  state)
virtual

Set the state of the progress indicator displayed on a taskbar button.

See also
wxTaskBarButtonState
virtual void wxTaskBarButton::SetProgressValue ( int  value)
virtual

Update the progress indicator, setting the progress to the new value .

Parameters
valueMust be in the range from 0 to the argument to the last SetProgressRange() call. When it is equal to the range, the progress bar is dismissed.
virtual void wxTaskBarButton::SetThumbnailClip ( const wxRect rect)
virtual

Selects a portion of a window's client area to display as that window's thumbnail in the taskbar.

Parameters
rectThe portion inside of the window. Setting with an empty wxRect will restore the default diaplay of the thumbnail.
virtual void wxTaskBarButton::SetThumbnailContents ( const wxWindow child)
virtual

Selects the child window area to display as that window's thumbnail in the taskbar.

virtual void wxTaskBarButton::SetThumbnailTooltip ( const wxString tooltip)
virtual

Specifies or updates the text of the tooltip that is displayed when the mouse pointer rests on an individual preview thumbnail in a taskbar button flyout.

virtual void wxTaskBarButton::Show ( bool  show = true)
virtual

Show in the taskbar.