Contents Up Previous Next

wxToolWindow

A tool window is a special kind of frame that paints its own title, and can be used to implement small floating windows.

Derived from

wxFrame

Include files

<wx/fl/toolwnd.h>

Data structures

Members

wxToolWindow::wxToolWindow
wxToolWindow::~wxToolWindow
wxToolWindow::AddMiniButton
wxToolWindow::AdjustRectPos
wxToolWindow::CalcResizedRect
wxToolWindow::DrawHintRect
wxToolWindow::GetClient
wxToolWindow::GetMinimalWndDim
wxToolWindow::GetPreferredSize
wxToolWindow::GetScrMousePos
wxToolWindow::GetScrWindowRect
wxToolWindow::HandleTitleClick
wxToolWindow::HitTestWindow
wxToolWindow::LayoutMiniButtons
wxToolWindow::OnEraseBackground
wxToolWindow::OnLeftDown
wxToolWindow::OnLeftUp
wxToolWindow::OnMiniButtonClicked
wxToolWindow::OnMotion
wxToolWindow::OnPaint
wxToolWindow::OnSize
wxToolWindow::SetClient
wxToolWindow::SetHintCursor
wxToolWindow::SetTitleFont


wxToolWindow::wxToolWindow

wxToolWindow()

Default constructor.


wxToolWindow::~wxToolWindow

~wxToolWindow()

Destructor.


wxToolWindow::AddMiniButton

void AddMiniButton(cbMiniButton* pBtn)

Adds a button. Buttons are added in right-to-left order.


wxToolWindow::AdjustRectPos

void AdjustRectPos(const wxRect& original, const wxSize& newDim, wxRect& newRect)

Helper function.


wxToolWindow::CalcResizedRect

void CalcResizedRect(wxRect& rect, wxPoint& delta, const wxSize& minDim)

Calculate resized rectangle.


wxToolWindow::DrawHintRect

void DrawHintRect(const wxRect& r)

Draws the hint rectangle.


wxToolWindow::GetClient

wxWindow* GetClient()

Returns the client window.


wxToolWindow::GetMinimalWndDim

wxSize GetMinimalWndDim()

Helper function.


wxToolWindow::GetPreferredSize

wxSize GetPreferredSize(const wxSize& given)

Returns the preferred size for the window.


wxToolWindow::GetScrMousePos

void GetScrMousePos(wxMouseEvent& event, wxPoint& pos)

Gets the mouse position in screen coordinates.


wxToolWindow::GetScrWindowRect

void GetScrWindowRect(wxRect& r)

Maps client coordinates to screen coordinates.


wxToolWindow::HandleTitleClick

bool HandleTitleClick(wxMouseEvent& event)

Handles clicking on the title. By default, does nothing.


wxToolWindow::HitTestWindow

int HitTestWindow(wxMouseEvent& event)

Tests if the mouse position is in this window.


wxToolWindow::LayoutMiniButtons

void LayoutMiniButtons()

Lays out the buttons.


wxToolWindow::OnEraseBackground

void OnEraseBackground(wxEraseEvent& event)

Responds to an erase background event.


wxToolWindow::OnLeftDown

void OnLeftDown(wxMouseEvent& event)

Responds to a mouse left down event.


wxToolWindow::OnLeftUp

void OnLeftUp(wxMouseEvent& event)

Responds to a mouse left up event.


wxToolWindow::OnMiniButtonClicked

void OnMiniButtonClicked(int btnIdx)

Called when a mini button is clicked. By default, does nothing.


wxToolWindow::OnMotion

void OnMotion(wxMouseEvent& event)

Responds to a mouse move event.


wxToolWindow::OnPaint

void OnPaint(wxPaintEvent& event)

Responds to a paint event.


wxToolWindow::OnSize

void OnSize(wxSizeEvent& event)

Responds to a size event.


wxToolWindow::SetClient

void SetClient(wxWindow* pWnd)

Sets the client for this tool window.


wxToolWindow::SetHintCursor

void SetHintCursor(int type)

Sets the hint cursor.


wxToolWindow::SetTitleFont

void SetTitleFont(wxFont& font)

Sets the title font.