![]() |
wxAccordion
|
#include <wx/accordion/accordion.h>
This class represents an accordion control, which manages multiple windows with associated caption bars. See Wikipedia for more information.
To use the class, create a wxAccordion object and call wxAccordion::AddPage or wxAccordion::InsertPage, passing a window to be used as the page. Do not explicitly delete the window for a page that is currently managed by wxAccordion.
This class supports the following styles:
The following event handler macros redirect the events to member function handlers 'func' with prototypes like:
Event macros for events emitted by this class:
wxEVT_ACCORDION_COLLAPSED
event. wxEVT_ACCORDION_COLLAPSING
event. This event can be vetoed. wxEVT_ACCORDION_EXPANDED
event. wxEVT_ACCORDION_EXPANDING
event. This event can be vetoed. Public Member Functions | |
wxAccordion () | |
Default constructor. | |
wxAccordion (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name="accordion") | |
Constructor. | |
virtual | ~wxAccordion () |
Destructor. | |
bool | Create (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL, const wxString &name="accordion") |
Used for two-step accordion construction. | |
Accordion management functions | |
void | Expand (size_t n) |
Expands the accordion page with index n to show its contents. | |
void | Collapse (size_t n) |
Collapses the accordion page with index n to hide its contents. | |
void | Toggle (size_t n) |
Toggles the accordion page with index n between the expanded and collapsed states. | |
void | Enable (size_t n) |
Sets the accordion page with index n to have the enabled state. | |
void | Disable (size_t n) |
Sets the accordion page with index n to have the disabled state. | |
bool | IsExpanded (size_t n) const |
Checks if the accordion page with index n is expanded. | |
bool | IsCollapsed (size_t n) const |
Checks if the accordion page with index n is collapsed. | |
bool | IsEnabled (size_t n) const |
Checks if the accordion page with index n is in the enabled state. | |
bool | IsDisabled (size_t n) const |
Checks if the accordion page with index n is in the disabled state. | |
void | SetFixedSize (size_t n) |
Sets accordion page with index n to have both a fixed width and a fixed height. | |
void | SetFixedWidth (size_t n) |
Sets accordion page with index n to have a fixed width. | |
void | SetFixedHeight (size_t n) |
Sets accordion page with index n to have a fixed height. | |
int | GetCaptionBarHeight () const |
Returns the current height of the caption bars in the accordion. | |
virtual int | HitTest (const wxPoint &pt, long *flags=NULL) const |
Calculates which (if any) item is under the given point, returning the tree item id at this point plus extra information flags. | |
Accordion style get/set functions | |
int | GetAccordionPadding () const |
Returns the accordion padding size (in pixels). | |
wxBitmap | GetAccordionBGBitmap () const |
Returns a copy of the bitmap being used for the accordion background. | |
wxAccordionToggleStyle | GetToggleStyle () const |
Returns the current toggle style of the accordion. | |
void | SetAccordionPadding (int m) |
Sets the accordion padding size (in pixels). | |
void | SetAccordionBGBitmap (const wxBitmap &) |
Sets the bitmap to be used for the accordion background. | |
void | SetToggleStyle (wxAccordionToggleStyle toggleStyle) |
Sets the toggle style of the accordion. | |
Caption bar style get/set functions | |
double | GetCaptionRadius () const |
Returns the radius of the accordion's caption bars corners (in pixels). | |
double | GetCaptionGradientAngle () const |
Returns the angle (in degrees) that the transition lines will take in the accordion's caption bars. | |
wxAccordionBorderStyle | GetCaptionBorderStyle () const |
Returns the border style for the accordion's caption bars. | |
int | GetMinCaptionHeight () const |
Returns the minimum height of the accordion's caption bars. | |
wxSize | GetIconMargin () const |
Returns the size of the margins (in pixels) used for the icons in the accordion's caption bars. | |
wxSize | GetTextMargin () const |
Returns the size of the margins (in pixels) used for the label on the accordion's caption bars. | |
wxSize | GetButtonMargin () const |
Returns the size of the margins (in pixels) used for the expand and collapse in the accordion's caption bars. | |
wxBitmap | GetCollapseButton () const |
Returns a copy of the bitmap used for the collapse button of the accordion's caption bars. | |
wxBitmap | GetExpandButton () const |
Returns a copy of the bitmap used for the expand button of the accordion's caption bars. | |
wxAccordionHighlighting | GetHighlighting () const |
Returns the current highlighting style for the accordion. | |
wxAccordionDisabledState | GetDisabledState () const |
Returns the the disabled state used for the accordion's caption bars. | |
int | GetDisabledBrightness () const |
Returns the disabled brightness of the accordion's caption bars. | |
wxAccordionStyle & | GetCollapsedStyle () |
Returns the style used for drawing the caption bar in the collapsed state. | |
wxAccordionStyle & | GetExpandedStyle () |
Returns the style used for drawing the caption bar in the expanded state. | |
wxAccordionStyle & | GetCollapsedHLStyle () |
Returns the style used for drawing the caption bar in the collapsed hightlighted state. | |
wxAccordionStyle & | GetExpandedHLStyle () |
Returns the style used for drawing the caption bar in the expanded highlighted state. | |
wxAccordionStyle & | GetDisabledStyle () |
Returns the style used for drawing the caption bar in the disabled state. | |
void | SetCaptionRadius (double d) |
Sets the radius of the accordion's caption bars corners (in pixels). | |
void | SetCaptionGradientAngle (double a) |
Sets the angle (in degrees) that the transition lines will take in the accordion's caption bars. | |
void | SetCaptionBorderStyle (wxAccordionBorderStyle borderStyle) |
Sets the border style for the accordion's caption bars. | |
void | SetMinCaptionHeight (int m) |
Sets the minimum height of the accordion's caption bars. | |
void | SetIconMargin (const wxSize &p) |
Sets the size of the margins (in pixels) used for the icons in the accordion's caption bars. | |
void | SetTextMargin (const wxSize &p) |
Sets the size of the margins (in pixels) used for the label on the accordion's caption bars. | |
void | SetButtonMargin (const wxSize &p) |
Sets the size of the margins (in pixels) used for the expand and collapse in the accordion's caption bars. | |
void | SetCollapseButton (const wxBitmap &b) |
Sets the bitmap used for the collapse button of the accordion's caption bars. | |
void | SetExpandButton (const wxBitmap &b) |
Sets the bitmap used for the expand button of the accordion's caption bars. | |
void | SetHighlighting (wxAccordionHighlighting highlighting) |
Sets the highlighting style for the accordion. | |
void | SetDisabledState (wxAccordionDisabledState state) |
Sets the the disabled state for the accordion's caption bars. | |
void | SetDisabledBrightness (int b) |
Sets the disabled brightness of the accordion's caption bars. | |
void | SetCollapsedStyle (const wxAccordionStyle &) |
Sets the style used for drawing the caption bar in the collapsed state. | |
void | SetExpandedStyle (const wxAccordionStyle &) |
Sets the style used for drawing the caption bar in the expanded state. | |
void | SetCollapsedHLStyle (const wxAccordionStyle &) |
Sets the style used for drawing the caption bar in the collapsed hightlighted state. | |
void | SetExpandedHLStyle (const wxAccordionStyle &) |
Sets the style used for drawing the caption bar in the expanded highlighted state. | |
void | SetDisabledStyle (const wxAccordionStyle &) |
Sets the style used for drawing the caption bar in the disabled state. | |
Page style get/set functions | |
double | GetPageRadius () const |
Returns the radius of the accordion's pages (in pixels). | |
int | GetPagePadding () const |
Returns the padding (in pixels) of the accordion's pages. | |
wxAccordionStyle & | GetPageStyle () |
Returns the style used for drawing the accordion's pages. | |
void | SetPageRadius (double d) |
Sets the radius of the accordion's pages (in pixels). | |
void | SetPagePadding (int m) |
Sets the padding (in pixels) of the accordion's pages. | |
void | SetPageStyle (const wxAccordionStyle &) |
Sets the style used for drawing the background of the accordion's pages. | |
![]() | |
wxBookCtrlBase (wxWindow *parent, wxWindowID winid, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxEmptyString) | |
bool | Create (wxWindow *parent, wxWindowID winid, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxEmptyString) |
virtual size_t | GetPageCount () const |
virtual wxWindow * | GetPage (size_t n) const |
wxWindow * | GetCurrentPage () const |
virtual int | GetSelection () const |
virtual bool | SetPageText (size_t n, const wxString &strText)=0 |
virtual wxString | GetPageText (size_t n) const =0 |
virtual int | GetPageImage (size_t n) const =0 |
virtual bool | SetPageImage (size_t n, int imageId)=0 |
virtual void | SetPageSize (const wxSize &size) |
wxSize | GetControllerSize () const |
virtual wxSize | CalcSizeFromPage (const wxSize &sizePage) const |
unsigned int | GetInternalBorder () const |
void | SetInternalBorder (unsigned int border) |
void | SetControlMargin (int margin) |
int | GetControlMargin () const |
bool | IsVertical () const |
void | SetFitToCurrentPage (bool fit) |
bool | GetFitToCurrentPage () const |
wxSizer * | GetControlSizer () const |
virtual bool | DeletePage (size_t n) |
virtual bool | RemovePage (size_t n) |
virtual bool | DeleteAllPages () |
virtual bool | AddPage (wxWindow *page, const wxString &text, bool bSelect=false, int imageId=NO_IMAGE) |
virtual bool | InsertPage (size_t n, wxWindow *page, const wxString &text, bool bSelect=false, int imageId=NO_IMAGE)=0 |
virtual int | SetSelection (size_t n)=0 |
virtual int | ChangeSelection (size_t n)=0 |
void | AdvanceSelection (bool forward=true) |
int | FindPage (const wxWindow *page) const |
virtual int | HitTest (const wxPoint &WXUNUSED(pt), long *WXUNUSED(flags)=NULL) const |
virtual bool | HasMultiplePages () const |
virtual bool | AcceptsFocus () const |
virtual bool | CanApplyThemeBorder () const |
![]() | |
bool | Create (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxValidator &validator=wxDefaultValidator, const wxString &name=wxControlNameStr) |
int | GetAlignment () const |
virtual void | SetLabel (const wxString &label) |
virtual wxString | GetLabel () const |
virtual void | SetLabelText (const wxString &text) |
virtual wxString | GetLabelText () const |
virtual bool | ShouldInheritColours () const |
virtual void | Command (wxCommandEvent &event) |
virtual bool | SetFont (const wxFont &font) |
virtual void | DoUpdateWindowUI (wxUpdateUIEvent &event) |
wxSize | GetSizeFromTextSize (int xlen, int ylen=-1) const |
wxSize | GetSizeFromTextSize (const wxSize &tsize) const |
![]() | |
bool | Close (bool force=false) |
virtual bool | Destroy () |
bool | DestroyChildren () |
bool | IsBeingDeleted () const |
virtual void | SetName (const wxString &name) |
virtual wxString | GetName () const |
void | SetWindowVariant (wxWindowVariant variant) |
wxWindowVariant | GetWindowVariant () const |
virtual wxLayoutDirection | GetLayoutDirection () const |
virtual void | SetLayoutDirection (wxLayoutDirection WXUNUSED(dir)) |
virtual wxCoord | AdjustForLayoutDirection (wxCoord x, wxCoord width, wxCoord widthTotal) const |
void | SetId (wxWindowID winid) |
wxWindowID | GetId () const |
void | SetSize (int x, int y, int width, int height, int sizeFlags=wxSIZE_AUTO) |
void | SetSize (int width, int height) |
void | SetSize (const wxSize &size) |
void | SetSize (const wxRect &rect, int sizeFlags=wxSIZE_AUTO) |
void | Move (int x, int y, int flags=wxSIZE_USE_EXISTING) |
void | Move (const wxPoint &pt, int flags=wxSIZE_USE_EXISTING) |
void | SetPosition (const wxPoint &pt) |
virtual void | Raise ()=0 |
virtual void | Lower ()=0 |
void | SetClientSize (int width, int height) |
void | SetClientSize (const wxSize &size) |
void | SetClientSize (const wxRect &rect) |
void | GetPosition (int *x, int *y) const |
wxPoint | GetPosition () const |
void | GetScreenPosition (int *x, int *y) const |
wxPoint | GetScreenPosition () const |
void | GetSize (int *w, int *h) const |
wxSize | GetSize () const |
void | GetClientSize (int *w, int *h) const |
wxSize | GetClientSize () const |
wxRect | GetRect () const |
wxRect | GetScreenRect () const |
virtual wxPoint | GetClientAreaOrigin () const |
wxRect | GetClientRect () const |
virtual wxSize | ClientToWindowSize (const wxSize &size) const |
virtual wxSize | WindowToClientSize (const wxSize &size) const |
wxSize | GetBestSize () const |
void | GetBestSize (int *w, int *h) const |
int | GetBestHeight (int width) const |
int | GetBestWidth (int height) const |
void | SetScrollHelper (wxScrollHelper *sh) |
wxScrollHelper * | GetScrollHelper () |
void | InvalidateBestSize () |
void | CacheBestSize (const wxSize &size) const |
virtual wxSize | GetEffectiveMinSize () const |
wxDEPRECATED_MSG ("use GetEffectiveMinSize() instead") wxSize GetBestFittingSize() const | |
wxDEPRECATED_MSG ("use GetEffectiveMinSize() instead") wxSize GetAdjustedMinSize() const | |
void | SetInitialSize (const wxSize &size=wxDefaultSize) |
wxDEPRECATED_MSG ("use SetInitialSize() instead") void SetBestFittingSize(const wxSize &size | |
void | Centre (int dir=wxBOTH) |
void | Center (int dir=wxBOTH) |
void | CentreOnParent (int dir=wxBOTH) |
void | CenterOnParent (int dir=wxBOTH) |
virtual void | Fit () |
virtual void | FitInside () |
virtual void | SetSizeHints (int minW, int minH, int maxW=wxDefaultCoord, int maxH=wxDefaultCoord, int incW=wxDefaultCoord, int incH=wxDefaultCoord) |
void | SetSizeHints (const wxSize &minSize, const wxSize &maxSize=wxDefaultSize, const wxSize &incSize=wxDefaultSize) |
virtual void | SetMinSize (const wxSize &minSize) |
virtual void | SetMaxSize (const wxSize &maxSize) |
virtual void | SetMinClientSize (const wxSize &size) |
virtual void | SetMaxClientSize (const wxSize &size) |
virtual wxSize | GetMinSize () const |
virtual wxSize | GetMaxSize () const |
virtual wxSize | GetMinClientSize () const |
virtual wxSize | GetMaxClientSize () const |
int | GetMinWidth () const |
int | GetMinHeight () const |
int | GetMaxWidth () const |
int | GetMaxHeight () const |
void | SetVirtualSize (const wxSize &size) |
void | SetVirtualSize (int x, int y) |
wxSize | GetVirtualSize () const |
void | GetVirtualSize (int *x, int *y) const |
virtual void | DoSetVirtualSize (int x, int y) |
virtual wxSize | DoGetVirtualSize () const |
virtual wxSize | GetBestVirtualSize () const |
virtual double | GetContentScaleFactor () const |
virtual wxSize | GetWindowBorderSize () const |
virtual bool | InformFirstDirection (int direction, int size, int availableOtherDir) |
virtual void | SendSizeEvent (int flags=0) |
void | SendSizeEventToParent (int flags=0) |
void | PostSizeEvent () |
void | PostSizeEventToParent () |
virtual bool | BeginRepositioningChildren () |
virtual void | EndRepositioningChildren () |
virtual bool | Show (bool show=true) |
bool | Hide () |
virtual bool | ShowWithEffect (wxShowEffect WXUNUSED(effect), unsigned WXUNUSED(timeout)=0) |
virtual bool | HideWithEffect (wxShowEffect WXUNUSED(effect), unsigned WXUNUSED(timeout)=0) |
virtual bool | Enable (bool enable=true) |
bool | Disable () |
virtual bool | IsShown () const |
bool | IsEnabled () const |
bool | IsThisEnabled () const |
virtual bool | IsShownOnScreen () const |
virtual void | SetWindowStyleFlag (long style) |
virtual long | GetWindowStyleFlag () const |
void | SetWindowStyle (long style) |
long | GetWindowStyle () const |
bool | HasFlag (int flag) const |
virtual bool | IsRetained () const |
bool | ToggleWindowStyle (int flag) |
virtual void | SetExtraStyle (long exStyle) |
long | GetExtraStyle () const |
bool | HasExtraStyle (int exFlag) const |
virtual void | SetThemeEnabled (bool enableTheme) |
virtual bool | GetThemeEnabled () const |
virtual void | SetFocus ()=0 |
virtual void | SetFocusFromKbd () |
virtual bool | HasFocus () const |
virtual bool | AcceptsFocusRecursively () const |
virtual bool | AcceptsFocusFromKeyboard () const |
virtual bool | CanBeFocused () const |
bool | IsFocusable () const |
bool | CanAcceptFocus () const |
bool | CanAcceptFocusFromKeyboard () const |
virtual void | SetCanFocus (bool WXUNUSED(canFocus)) |
bool | NavigateIn (int flags=wxNavigationKeyEvent::IsForward) |
bool | Navigate (int flags=wxNavigationKeyEvent::IsForward) |
bool | HandleAsNavigationKey (const wxKeyEvent &event) |
void | MoveBeforeInTabOrder (wxWindow *win) |
void | MoveAfterInTabOrder (wxWindow *win) |
const wxWindowList & | GetChildren () const |
wxWindowList & | GetChildren () |
const wxWindowList & | GetWindowChildren () const |
wxWindow * | GetPrevSibling () const |
wxWindow * | GetNextSibling () const |
wxWindow * | GetParent () const |
wxWindow * | GetGrandParent () const |
virtual bool | IsTopLevel () const |
bool | IsDescendant (wxWindow *win) const |
void | SetParent (wxWindow *parent) |
virtual bool | Reparent (wxWindow *newParent) |
virtual void | AddChild (wxWindow *child) |
virtual void | RemoveChild (wxWindow *child) |
virtual bool | IsClientAreaChild (const wxWindow *WXUNUSED(child)) const |
wxWindow * | FindWindow (long winid) const |
wxWindow * | FindWindow (const wxString &name) const |
wxEvtHandler * | GetEventHandler () const |
void | SetEventHandler (wxEvtHandler *handler) |
void | PushEventHandler (wxEvtHandler *handler) |
wxEvtHandler * | PopEventHandler (bool deleteHandler=false) |
bool | RemoveEventHandler (wxEvtHandler *handler) |
bool | ProcessWindowEvent (wxEvent &event) |
bool | ProcessWindowEventLocally (wxEvent &event) |
bool | HandleWindowEvent (wxEvent &event) const |
virtual void | SetNextHandler (wxEvtHandler *handler) |
virtual void | SetPreviousHandler (wxEvtHandler *handler) |
virtual bool | Validate () |
virtual bool | TransferDataToWindow () |
virtual bool | TransferDataFromWindow () |
virtual void | InitDialog () |
wxPoint | ConvertPixelsToDialog (const wxPoint &pt) const |
wxPoint | ConvertDialogToPixels (const wxPoint &pt) const |
wxSize | ConvertPixelsToDialog (const wxSize &sz) const |
wxSize | ConvertDialogToPixels (const wxSize &sz) const |
virtual void | WarpPointer (int x, int y)=0 |
void | CaptureMouse () |
void | ReleaseMouse () |
virtual bool | HasCapture () const |
virtual void | Refresh (bool eraseBackground=true, const wxRect *rect=(const wxRect *) NULL)=0 |
void | RefreshRect (const wxRect &rect, bool eraseBackground=true) |
virtual void | Update () |
virtual void | ClearBackground () |
void | Freeze () |
void | Thaw () |
bool | IsFrozen () const |
virtual void | PrepareDC (wxDC &WXUNUSED(dc)) |
virtual bool | IsDoubleBuffered () const |
const wxRegion & | GetUpdateRegion () const |
wxRegion & | GetUpdateRegion () |
wxRect | GetUpdateClientRect () const |
virtual bool | DoIsExposed (int x, int y) const |
virtual bool | DoIsExposed (int x, int y, int w, int h) const |
bool | IsExposed (int x, int y) const |
bool | IsExposed (int x, int y, int w, int h) const |
bool | IsExposed (const wxPoint &pt) const |
bool | IsExposed (const wxRect &rect) const |
virtual wxVisualAttributes | GetDefaultAttributes () const |
virtual bool | SetBackgroundColour (const wxColour &colour) |
void | SetOwnBackgroundColour (const wxColour &colour) |
wxColour | GetBackgroundColour () const |
bool | InheritsBackgroundColour () const |
bool | UseBgCol () const |
virtual bool | SetForegroundColour (const wxColour &colour) |
void | SetOwnForegroundColour (const wxColour &colour) |
wxColour | GetForegroundColour () const |
virtual bool | SetBackgroundStyle (wxBackgroundStyle style) |
wxBackgroundStyle | GetBackgroundStyle () const |
virtual bool | HasTransparentBackground () |
virtual bool | IsTransparentBackgroundSupported (wxString *reason=NULL) const |
void | SetOwnFont (const wxFont &font) |
wxFont | GetFont () const |
virtual bool | SetCursor (const wxCursor &cursor) |
const wxCursor & | GetCursor () const |
virtual int | GetCharHeight () const =0 |
virtual int | GetCharWidth () const =0 |
void | GetTextExtent (const wxString &string, int *x, int *y, int *descent=NULL, int *externalLeading=NULL, const wxFont *font=NULL) const |
wxSize | GetTextExtent (const wxString &string) const |
void | ClientToScreen (int *x, int *y) const |
void | ScreenToClient (int *x, int *y) const |
wxPoint | ClientToScreen (const wxPoint &pt) const |
wxPoint | ScreenToClient (const wxPoint &pt) const |
wxHitTest | HitTest (wxCoord x, wxCoord y) const |
wxHitTest | HitTest (const wxPoint &pt) const |
wxBorder | GetBorder (long flags) const |
wxBorder | GetBorder () const |
virtual void | UpdateWindowUI (long flags=wxUPDATE_UI_NONE) |
virtual bool | CanScroll (int orient) const |
bool | HasScrollbar (int orient) const |
virtual void | SetScrollbar (int orient, int pos, int thumbvisible, int range, bool refresh=true)=0 |
virtual void | SetScrollPos (int orient, int pos, bool refresh=true)=0 |
virtual int | GetScrollPos (int orient) const =0 |
virtual int | GetScrollThumb (int orient) const =0 |
virtual int | GetScrollRange (int orient) const =0 |
virtual void | ScrollWindow (int dx, int dy, const wxRect *rect=NULL)=0 |
virtual bool | ScrollLines (int WXUNUSED(lines)) |
virtual bool | ScrollPages (int WXUNUSED(pages)) |
bool | LineUp () |
bool | LineDown () |
bool | PageUp () |
bool | PageDown () |
virtual void | AlwaysShowScrollbars (bool WXUNUSED(horz)=true, bool WXUNUSED(vert)=true) |
virtual bool | IsScrollbarAlwaysShown (int WXUNUSED(orient)) const |
void | SetHelpText (const wxString &WXUNUSED(text)) |
void | SetHelpTextForId (const wxString &WXUNUSED(text)) |
void | SetToolTip (const wxString &WXUNUSED(tip)) |
void | UnsetToolTip () |
void | SetAutoLayout (bool autoLayout) |
bool | GetAutoLayout () const |
virtual bool | Layout () |
void | SetSizer (wxSizer *sizer, bool deleteOld=true) |
void | SetSizerAndFit (wxSizer *sizer, bool deleteOld=true) |
wxSizer * | GetSizer () const |
void | SetContainingSizer (wxSizer *sizer) |
wxSizer * | GetContainingSizer () const |
virtual bool | SetTransparent (wxByte WXUNUSED(alpha)) |
virtual bool | CanSetTransparent () |
void | OnSysColourChanged (wxSysColourChangedEvent &event) |
void | OnInitDialog (wxInitDialogEvent &event) |
void | OnMiddleClick (wxMouseEvent &event) |
virtual void | OnInternalIdle () |
virtual bool | SendIdleEvents (wxIdleEvent &event) |
virtual WXWidget | GetHandle () const =0 |
virtual void | AssociateHandle (WXWidget WXUNUSED(handle)) |
virtual void | DissociateHandle () |
virtual void | InheritAttributes () |
virtual bool | CanBeOutsideClientArea () const |
virtual wxWindow * | GetMainWindowOfCompositeControl () |
virtual bool | IsTopNavigationDomain () const |
![]() | |
wxEvtHandler * | GetNextHandler () const |
wxEvtHandler * | GetPreviousHandler () const |
void | SetEvtHandlerEnabled (bool enabled) |
bool | GetEvtHandlerEnabled () const |
void | Unlink () |
bool | IsUnlinked () const |
virtual bool | ProcessEvent (wxEvent &event) |
bool | SafelyProcessEvent (wxEvent &event) |
bool | ProcessEventLocally (wxEvent &event) |
virtual void | QueueEvent (wxEvent *event) |
virtual void | AddPendingEvent (const wxEvent &event) |
void | ProcessPendingEvents () |
void | DeletePendingEvents () |
template<typename T > | |
void | CallAfter (void(T::*method)()) |
template<typename T , typename T1 , typename P1 > | |
void | CallAfter (void(T::*method)(T1 x1), P1 x1) |
template<typename T , typename T1 , typename T2 , typename P1 , typename P2 > | |
void | CallAfter (void(T::*method)(T1 x1, T2 x2), P1 x1, P2 x2) |
template<typename T > | |
void | CallAfter (const T &fn) |
void | Connect (int winid, int lastId, wxEventType eventType, wxObjectEventFunction func, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
void | Connect (int winid, wxEventType eventType, wxObjectEventFunction func, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
void | Connect (wxEventType eventType, wxObjectEventFunction func, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
bool | Disconnect (int winid, int lastId, wxEventType eventType, wxObjectEventFunction func=NULL, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
bool | Disconnect (int winid=wxID_ANY, wxEventType eventType=wxEVT_NULL, wxObjectEventFunction func=NULL, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
bool | Disconnect (wxEventType eventType, wxObjectEventFunction func, wxObject *userData=NULL, wxEvtHandler *eventSink=NULL) |
wxList * | GetDynamicEventTable () const |
void | SetClientObject (wxClientData *data) |
wxClientData * | GetClientObject () const |
void | SetClientData (void *data) |
void * | GetClientData () const |
virtual bool | SearchEventTable (wxEventTable &table, wxEvent &event) |
bool | SearchDynamicEventTable (wxEvent &event) |
void | ClearEventHashTable () |
void | OnSinkDestroyed (wxEvtHandler *sink) |
![]() | |
wxObject (const wxObject &other) | |
wxObject & | operator= (const wxObject &other) |
bool | IsKindOf (const wxClassInfo *info) const |
wxObjectRefData * | GetRefData () const |
void | SetRefData (wxObjectRefData *data) |
void | Ref (const wxObject &clone) |
void | UnRef () |
void | UnShare () |
bool | IsSameAs (const wxObject &o) const |
![]() | |
void | AddNode (wxTrackerNode *prn) |
void | RemoveNode (wxTrackerNode *prn) |
wxTrackerNode * | GetFirst () const |
![]() | |
virtual void | SetImageList (wxImageList *imageList) |
void | AssignImageList (wxImageList *imageList) |
wxImageList * | GetImageList () const |
Additional Inherited Members | |
![]() | |
enum | { NO_IMAGE = -1 } |
![]() | |
static wxString | GetLabelText (const wxString &label) |
static wxString | RemoveMnemonics (const wxString &str) |
static wxString | EscapeMnemonics (const wxString &str) |
static wxString | Ellipsize (const wxString &label, const wxDC &dc, wxEllipsizeMode mode, int maxWidth, int flags=wxELLIPSIZE_FLAGS_DEFAULT) |
static int | FindAccelIndex (const wxString &label, wxString *labelOnly=NULL) |
static wxVisualAttributes | GetCompositeControlsDefaultAttributes (wxWindowVariant variant) |
wxAccordion::wxAccordion | ( | ) |
Default constructor.
wxAccordion::wxAccordion | ( | wxWindow * | parent, |
wxWindowID | id = wxID_ANY , |
||
const wxPoint & | pos = wxDefaultPosition , |
||
const wxSize & | size = wxDefaultSize , |
||
long | style = wxTAB_TRAVERSAL , |
||
const wxString & | name = "accordion" |
||
) |
Constructor.
parent | The parent window. |
id | An identifier for the accordion. wxID_ANY is taken to mean a default. |
pos | The accordion position. The value wxDefaultPosition indicates a default position, chosen by either the windowing system or wxWidgets, depending on platform. |
size | The accordion size. The value wxDefaultSize indicates a default size, chosen by either the windowing system or wxWidgets, depending on platform. |
style | The accordion style. |
name | The window name. |
|
virtual |
Destructor.
Deletes any child windows before deleting the physical window.
void wxAccordion::Collapse | ( | size_t | n | ) |
Collapses the accordion page with index n to hide its contents.
If the page is already collapsed or n is not a valid page index, this has no effect.
bool wxAccordion::Create | ( | wxWindow * | parent, |
wxWindowID | id = wxID_ANY , |
||
const wxPoint & | pos = wxDefaultPosition , |
||
const wxSize & | size = wxDefaultSize , |
||
long | style = wxTAB_TRAVERSAL , |
||
const wxString & | name = "accordion" |
||
) |
Used for two-step accordion construction.
See wxAccordion() for details.
void wxAccordion::Disable | ( | size_t | n | ) |
Sets the accordion page with index n to have the disabled state.
The caption bar will be drawn as a grayed version of the collapsed state by default or using the disabled style properties if SetDisabledState(wxAC_DISABLED_STATE_CUSTOM) been called. If the page was expanded, it will be collapsed.
void wxAccordion::Enable | ( | size_t | n | ) |
void wxAccordion::Expand | ( | size_t | n | ) |
Expands the accordion page with index n to show its contents.
If the page is already expanded or n is not a valid page index, this has no effect.
wxBitmap wxAccordion::GetAccordionBGBitmap | ( | ) | const |
Returns a copy of the bitmap being used for the accordion background.
int wxAccordion::GetAccordionPadding | ( | ) | const |
Returns the accordion padding size (in pixels).
The accordion padding is the gap between the edge of the accordion and the pages. It's also the gap between pages.
wxSize wxAccordion::GetButtonMargin | ( | ) | const |
Returns the size of the margins (in pixels) used for the expand and collapse in the accordion's caption bars.
int wxAccordion::GetCaptionBarHeight | ( | ) | const |
Returns the current height of the caption bars in the accordion.
The caption bar is set to have the smallest height needed for the text, the icons (if used), and the buttons (if used) plus any margins for those items.
wxAccordionBorderStyle wxAccordion::GetCaptionBorderStyle | ( | ) | const |
Returns the border style for the accordion's caption bars.
The return value will be either wxAC_BORDERS_FULL or wxAC_BORDERS_NO_BOTTOM_WHEN_EXPANDED.
double wxAccordion::GetCaptionGradientAngle | ( | ) | const |
Returns the angle (in degrees) that the transition lines will take in the accordion's caption bars.
double wxAccordion::GetCaptionRadius | ( | ) | const |
Returns the radius of the accordion's caption bars corners (in pixels).
wxBitmap wxAccordion::GetCollapseButton | ( | ) | const |
Returns a copy of the bitmap used for the collapse button of the accordion's caption bars.
wxAccordionStyle & wxAccordion::GetCollapsedHLStyle | ( | ) |
Returns the style used for drawing the caption bar in the collapsed hightlighted state.
Note: these settings are not used unless SetHighlighting(wxAC_HIGHLIGHTING_MOUSEOVER) has been called.
wxAccordionStyle & wxAccordion::GetCollapsedStyle | ( | ) |
Returns the style used for drawing the caption bar in the collapsed state.
int wxAccordion::GetDisabledBrightness | ( | ) | const |
Returns the disabled brightness of the accordion's caption bars.
This setting will not be used if SetDisabledState(wxAC_DISABLED_STATE_CUSTOM) has been called.
wxAccordionDisabledState wxAccordion::GetDisabledState | ( | ) | const |
Returns the the disabled state used for the accordion's caption bars.
The return value will be either wxAC_DISABLED_STATE_DEFAULT or wxAC_DISABLED_STATE_CUSTOM.
wxAccordionStyle & wxAccordion::GetDisabledStyle | ( | ) |
Returns the style used for drawing the caption bar in the disabled state.
Note: These settings are not used unless SetDisabledState(wxAC_DISABLED_STATE_CUSTOM) has been called.
wxBitmap wxAccordion::GetExpandButton | ( | ) | const |
Returns a copy of the bitmap used for the expand button of the accordion's caption bars.
wxAccordionStyle & wxAccordion::GetExpandedHLStyle | ( | ) |
Returns the style used for drawing the caption bar in the expanded highlighted state.
Note: these settings are not used unless SetHighlighting(wxAC_HIGHLIGHTING_MOUSEOVER) has been called.
wxAccordionStyle & wxAccordion::GetExpandedStyle | ( | ) |
Returns the style used for drawing the caption bar in the expanded state.
wxAccordionHighlighting wxAccordion::GetHighlighting | ( | ) | const |
Returns the current highlighting style for the accordion.
The return value will be either wxAC_HIGHLIGHTING_NONE or wxAC_HIGHLIGHTING_MOUSEOVER.
wxSize wxAccordion::GetIconMargin | ( | ) | const |
Returns the size of the margins (in pixels) used for the icons in the accordion's caption bars.
int wxAccordion::GetMinCaptionHeight | ( | ) | const |
Returns the minimum height of the accordion's caption bars.
int wxAccordion::GetPagePadding | ( | ) | const |
Returns the padding (in pixels) of the accordion's pages.
The page padding is the space between the edge of the page and the edge of the window it contains.
double wxAccordion::GetPageRadius | ( | ) | const |
Returns the radius of the accordion's pages (in pixels).
wxAccordionStyle & wxAccordion::GetPageStyle | ( | ) |
Returns the style used for drawing the accordion's pages.
wxSize wxAccordion::GetTextMargin | ( | ) | const |
Returns the size of the margins (in pixels) used for the label on the accordion's caption bars.
wxAccordionToggleStyle wxAccordion::GetToggleStyle | ( | ) | const |
Returns the current toggle style of the accordion.
The return value will be either wxAC_TOGGLE_ONLY_ON_BUTTON_CLICKS or wxTOGGLE_ON_ANY_CLICK
|
virtual |
Calculates which (if any) item is under the given point, returning the tree item id at this point plus extra information flags.
pt | The point to check. |
flags | A long pointer that will be set as described below. |
bool wxAccordion::IsCollapsed | ( | size_t | n | ) | const |
Checks if the accordion page with index n is collapsed.
Note that this will return false if n is not a valid page index.
bool wxAccordion::IsDisabled | ( | size_t | n | ) | const |
Checks if the accordion page with index n is in the disabled state.
Note that this will return false if n is not a valid page index.
bool wxAccordion::IsEnabled | ( | size_t | n | ) | const |
Checks if the accordion page with index n is in the enabled state.
Note that this will return false if n is not a valid page index.
bool wxAccordion::IsExpanded | ( | size_t | n | ) | const |
Checks if the accordion page with index n is expanded.
Note that this will return false if n is not a valid page index.
void wxAccordion::SetAccordionBGBitmap | ( | const wxBitmap & | b | ) |
Sets the bitmap to be used for the accordion background.
To clear the bitmap, call this function with wxNullBitmap as the parameter.
void wxAccordion::SetAccordionPadding | ( | int | m | ) |
Sets the accordion padding size (in pixels).
The accordion padding is the gap between the edge of the accordion and the pages. It's also the gap between pages.
void wxAccordion::SetButtonMargin | ( | const wxSize & | p | ) |
Sets the size of the margins (in pixels) used for the expand and collapse in the accordion's caption bars.
void wxAccordion::SetCaptionBorderStyle | ( | wxAccordionBorderStyle | borderStyle | ) |
Sets the border style for the accordion's caption bars.
The parameter borderStyle can be either wxAC_BORDERS_FULL or wxAC_BORDERS_NO_BOTTOM_WHEN_EXPANDED.
void wxAccordion::SetCaptionGradientAngle | ( | double | a | ) |
Sets the angle (in degrees) that the transition lines will take in the accordion's caption bars.
With an angle of zero, the gradient will run from the top to the bottom. With an angle of 45, the gradient will run from the top left to the bottom right. With an angle of 90, the gradient will run from left to right. And so on.
void wxAccordion::SetCaptionRadius | ( | double | d | ) |
Sets the radius of the accordion's caption bars corners (in pixels).
void wxAccordion::SetCollapseButton | ( | const wxBitmap & | b | ) |
Sets the bitmap used for the collapse button of the accordion's caption bars.
void wxAccordion::SetCollapsedHLStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the caption bar in the collapsed hightlighted state.
Note: these settings are not used unless SetHighlighting(wxAC_HIGHLIGHTING_MOUSEOVER) has been called.
void wxAccordion::SetCollapsedStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the caption bar in the collapsed state.
void wxAccordion::SetDisabledBrightness | ( | int | b | ) |
Sets the disabled brightness of the accordion's caption bars.
By default, the disabled state of a caption bar is a grayed version of the collapsed caption bar style. Values close to 0 will produce a very dark disabled caption bar. Values close to 255 will produce a very light disabled caption bar.
This setting will not be used if SetDisabledState(wxAC_DISABLED_STATE_CUSTOM) has been called.
void wxAccordion::SetDisabledState | ( | wxAccordionDisabledState | state | ) |
Sets the the disabled state for the accordion's caption bars.
The parameter state can be either wxAC_DISABLED_STATE_DEFAULT or wxAC_DISABLED_STATE_CUSTOM.
void wxAccordion::SetDisabledStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the caption bar in the disabled state.
Note: These settings are not used unless SetDisabledState(wxAC_DISABLED_STATE_CUSTOM) has been called.
void wxAccordion::SetExpandButton | ( | const wxBitmap & | b | ) |
Sets the bitmap used for the expand button of the accordion's caption bars.
void wxAccordion::SetExpandedHLStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the caption bar in the expanded highlighted state.
Note: these settings are not used unless SetHighlighting(wxAC_HIGHLIGHTING_MOUSEOVER) has been called.
void wxAccordion::SetExpandedStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the caption bar in the expanded state.
void wxAccordion::SetFixedHeight | ( | size_t | n | ) |
Sets accordion page with index n to have a fixed height.
By default, the window added to the accordion page will be stretched to use as much vertical space as the accordion has available. If the window is meant to have a fixed height (for example, a single line text control), this function can be used.
Note that there isn't any way to undo this other than removing the page and then adding it back.
void wxAccordion::SetFixedSize | ( | size_t | n | ) |
Sets accordion page with index n to have both a fixed width and a fixed height.
By default, the window added to the accordion page will be stretched to be stretched both vertically and horizontally. If the window is meant to have both a fixed width and a fixed height (for example, a button), this function can be used.
Note that there isn't any way to undo this other than removing the page and then adding it back.
void wxAccordion::SetFixedWidth | ( | size_t | n | ) |
Sets accordion page with index n to have a fixed width.
By default, the window added to the accordion page will be stretched to be as wide as the accordion (minus any padding). If the window is meant to have a fixed width (for example, a listbox), this function can be used.
Note that there isn't any way to undo this other than removing the page and then adding it back.
void wxAccordion::SetHighlighting | ( | wxAccordionHighlighting | highlighting | ) |
Sets the highlighting style for the accordion.
The parameter highlighting can be eithe wxAC_HIGHLIGHTING_NONE or wxAC_HIGHLIGHTING_MOUSEOVER.
void wxAccordion::SetIconMargin | ( | const wxSize & | p | ) |
Sets the size of the margins (in pixels) used for the icons in the accordion's caption bars.
void wxAccordion::SetMinCaptionHeight | ( | int | m | ) |
Sets the minimum height of the accordion's caption bars.
void wxAccordion::SetPagePadding | ( | int | m | ) |
Sets the padding (in pixels) of the accordion's pages.
The page padding is the space between the edge of the page and the edge of the window it contains.
void wxAccordion::SetPageRadius | ( | double | d | ) |
Sets the radius of the accordion's pages (in pixels).
This determines the radius used for the bottom corners of a page when it is expanded. The radius of the top corners are set with SetCaptionRadius().
void wxAccordion::SetPageStyle | ( | const wxAccordionStyle & | style | ) |
Sets the style used for drawing the background of the accordion's pages.
void wxAccordion::SetTextMargin | ( | const wxSize & | p | ) |
Sets the size of the margins (in pixels) used for the label on the accordion's caption bars.
void wxAccordion::SetToggleStyle | ( | wxAccordionToggleStyle | toggleStyle | ) |
Sets the toggle style of the accordion.
The parameter toggleStyle can be either wxAC_TOGGLE_ONLY_ON_BUTTON_CLICKS or wxTOGGLE_ON_ANY_CLICK.
This setting will only be used if expand and collapse button have been set for the accordion. If buttons have not been set, the accordion will always toggle in response to a click on the caption bar.