20#ifndef KICAD_WX_COLLAPSIBLE_PANE_H
21#define KICAD_WX_COLLAPSIBLE_PANE_H
23#include <wx/control.h>
24#include <wx/containr.h>
25#include <wx/statbox.h>
47 const wxPoint& aPos = wxDefaultPosition,
48 const wxSize& aSize = wxDefaultSize,
long aStyle = wxBORDER_NONE,
49 const wxValidator& aValidator = wxDefaultValidator,
50 const wxString& aName = wxT(
"COLLAPSIBLE_PANE_HEADER" ) )
54 Create( aParent, aId, aLabel, aPos, aSize, aStyle, aValidator, aName );
57 bool Create( wxWindow* aParent, wxWindowID aId,
const wxString& aLabel,
58 const wxPoint& aPos = wxDefaultPosition,
59 const wxSize& aSize = wxDefaultSize,
long aStyle = wxBORDER_NONE,
60 const wxValidator& aValidator = wxDefaultValidator,
61 const wxString& aName = wxT(
"COLLAPSIBLE_PANE_HEADER" ) );
81 void onPaint( wxPaintEvent& aEvent );
83 void onFocus( wxFocusEvent& aEvent );
89 void onLeftUp( wxMouseEvent& aEvent );
91 void onChar( wxKeyEvent& aEvent );
95 void drawArrow( wxDC& aDC, wxRect aRect,
bool aIsActive );
114 const wxPoint& aPos = wxDefaultPosition,
115 const wxSize& aSize = wxDefaultSize,
long aStyle = wxBORDER_NONE,
116 const wxValidator& aValidator = wxDefaultValidator,
117 const wxString& aName = wxT(
"COLLAPSIBLE_PANE_HEADER" ) )
121 Create( aParent, aId, aLabel, aPos, aSize, aStyle, aValidator, aName );
126 bool Create( wxWindow* aParent, wxWindowID aId,
const wxString& aLabel,
127 const wxPoint& aPos = wxDefaultPosition,
128 const wxSize& aSize = wxDefaultSize,
long aStyle = wxBORDER_NONE,
129 const wxValidator& aValidator = wxDefaultValidator,
130 const wxString& aName = wxT(
"COLLAPSIBLE_PANE_HEADER" ) );
132 void Collapse(
bool aCollapse =
true );
153 void SetLabel(
const wxString& aLabel )
override;
172 void onSize( wxSizeEvent& aEvent );
A better wxCollapsiblePane that.
wxSize DoGetBestClientSize() const override
void Collapse(bool aCollapse=true)
void onSize(wxSizeEvent &aEvent)
void onHeaderClicked(wxCommandEvent &aEvent)
WX_COLLAPSIBLE_PANE_HEADER * m_header
WX_COLLAPSIBLE_PANE(wxWindow *aParent, wxWindowID aId, const wxString &aLabel, const wxPoint &aPos=wxDefaultPosition, const wxSize &aSize=wxDefaultSize, long aStyle=wxBORDER_NONE, const wxValidator &aValidator=wxDefaultValidator, const wxString &aName=wxT("COLLAPSIBLE_PANE_HEADER"))
void SetLabel(const wxString &aLabel) override
bool InformFirstDirection(int aDirection, int aSize, int aAvailableOtherDir) override
wxString GetLabel() const override
bool Create(wxWindow *aParent, wxWindowID aId, const wxString &aLabel, const wxPoint &aPos=wxDefaultPosition, const wxSize &aSize=wxDefaultSize, long aStyle=wxBORDER_NONE, const wxValidator &aValidator=wxDefaultValidator, const wxString &aName=wxT("COLLAPSIBLE_PANE_HEADER"))
bool SetBackgroundColour(const wxColour &aColor) override
wxDECLARE_EVENT(WX_COLLAPSIBLE_PANE_HEADER_CHANGED, wxCommandEvent)