Code::Blocks  SVN r11506
Classes | Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
InfoPane Class Reference

#include <infopane.h>

Inheritance diagram for InfoPane:
Collaboration diagram for InfoPane:

Classes

struct  Page
 

Public Member Functions

 InfoPane (wxWindow *parent)
 
virtual ~InfoPane ()
 
void Show (size_t index)
 
void Show (Logger *logger)
 
void Hide (Logger *logger)
 
void ShowNonLogger (wxWindow *p)
 
void HideNonLogger (wxWindow *p)
 
int GetPageIndexByWindow (wxWindow *win)
 
int GetCurrentPage (bool &is_logger)
 
LoggerGetLogger (int index)
 
wxWindowGetWindow (int index)
 
void UpdateEffectiveTabOrder ()
 
void LoadTabOrder (wxString layout)
 
wxString SaveTabOrder ()
 
bool AddLogger (Logger *logger, wxWindow *p, const wxString &title, wxBitmap *icon=nullptr)
 
bool DeleteLogger (Logger *l)
 
bool AddNonLogger (wxWindow *p, const wxString &title, wxBitmap *icon=nullptr)
 
bool RemoveNonLogger (wxWindow *p)
 
bool DeleteNonLogger (wxWindow *p)
 
- Public Member Functions inherited from cbAuiNotebook
 cbAuiNotebook (wxWindow *pParent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxAUI_NB_DEFAULT_STYLE)
 cbAuiNotebook constructor More...
 
 ~cbAuiNotebook () override
 cbAuiNotebook destructor More...
 
void AdvanceSelection (bool forward=true)
 Advances the selection. More...
 
wxString SavePerspective (const wxString projectTitle=wxEmptyString)
 Save layout of the notebook. More...
 
bool LoadPerspective (const wxString &layout, bool mergeLayouts=false)
 Loads serialized notebook layout. More...
 
int GetTabIndexFromTooltip (const wxString &text)
 Get the tab index from tooltiptext. More...
 
int GetTabPositionFromIndex (int index)
 Get the tab position. More...
 
void MinimizeFreeSpace ()
 Minmize free horizontal page. More...
 
bool DeletePage (size_t page)
 Delete Page. More...
 
bool RemovePage (size_t page)
 Remove Page. More...
 
bool MovePage (wxWindow *page, size_t new_idx)
 Move page. More...
 
bool AddPage (wxWindow *page, const wxString &caption, bool select=false, const wxBitmap &bitmap=wxNullBitmap)
 Add Page. More...
 
bool InsertPage (size_t page_idx, wxWindow *page, const wxString &caption, bool select=false, const wxBitmap &bitmap=wxNullBitmap)
 Insert Page. More...
 
void SetZoom (int zoom)
 Set zoomfactor for builtin editors. More...
 
void FocusActiveTabCtrl ()
 Set Focus on the tabCtrl belonging to the active tab. More...
 
wxAuiTabCtrl * GetTabCtrl (wxWindow *page)
 Returns a pointer to the page's tab control or nullptr. More...
 
void GetPagesInTabCtrl (std::vector< wxWindow *> &result, wxWindow *page)
 Return a vector containing all pages that are in the same tab control as the page passed as parameter. More...
 
- Public Member Functions inherited from wxAuiNotebook
 wxAuiNotebook ()
 
 wxAuiNotebook (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxAUI_NB_DEFAULT_STYLE)
 
bool AddPage (wxWindow *page, const wxString &caption, bool select=false, const wxBitmap &bitmap=wxNullBitmap)
 
virtual bool AddPage (wxWindow *page, const wxString &text, bool select, int imageId)
 
void AdvanceSelection (bool forward=true)
 
virtual int ChangeSelection (size_t n)
 
bool Create (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0)
 
virtual bool DeleteAllPages ()
 
wxAuiTabArtGetArtProvider () const
 
wxWindowGetCurrentPage () const
 
int GetHeightForPageHeight (int pageHeight)
 
wxWindowGetPage (size_t page_idx) const
 
wxBitmap GetPageBitmap (size_t page) const
 
size_t GetPageCount () const
 
int GetPageIndex (wxWindow *page_wnd) const
 
wxString GetPageText (size_t page) const
 
wxString GetPageToolTip (size_t pageIdx) const
 
int GetSelection () const
 
int GetTabCtrlHeight () const
 
bool InsertPage (size_t page_idx, wxWindow *page, const wxString &caption, bool select=false, const wxBitmap &bitmap=wxNullBitmap)
 
virtual bool InsertPage (size_t index, wxWindow *page, const wxString &text, bool select=false, int imageId=NO_IMAGE)
 
void SetArtProvider (wxAuiTabArt *art)
 
virtual bool SetFont (const wxFont &font)
 
void SetMeasuringFont (const wxFont &font)
 
void SetNormalFont (const wxFont &font)
 
bool SetPageBitmap (size_t page, const wxBitmap &bitmap)
 
virtual bool SetPageImage (size_t n, int imageId)
 
bool SetPageText (size_t page, const wxString &text)
 
bool SetPageToolTip (size_t page, const wxString &text)
 
void SetSelectedFont (const wxFont &font)
 
size_t SetSelection (size_t new_page)
 
virtual void SetTabCtrlHeight (int height)
 
bool ShowWindowMenu ()
 
virtual void SetUniformBitmapSize (const wxSize &size)
 
virtual void Split (size_t page, int direction)
 
 wxBookCtrlBase ()
 
 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 void SetPageSize (const wxSize &size)
 
virtual int HitTest (const wxPoint &pt, long *flags=NULL) const
 
virtual int GetPageImage (size_t nPage) const=0
 
wxWindowGetCurrentPage () const
 
void AdvanceSelection (bool forward=true)
 
int FindPage (const wxWindow *page) const
 
wxWindowGetPage (size_t page) const
 
 wxWithImages ()
 
virtual ~wxWithImages ()
 
void AssignImageList (wxImageList *imageList)
 
virtual void SetImageList (wxImageList *imageList)
 
wxImageListGetImageList () const
 

Private Types

typedef int(* CompareFunction) (Page **, Page **)
 

Private Member Functions

void ReorderTabs (CompareFunction cmp_f)
 
 WX_DEFINE_ARRAY (Page *, wxArrayOfPage)
 
void Toggle (size_t index)
 
void Hide (size_t i)
 
void OnMenu (wxCommandEvent &event)
 
void OnCopy (wxCommandEvent &event)
 
void OnWrapMode (wxCommandEvent &event)
 
void OnClear (wxCommandEvent &event)
 
void ContextMenu (wxContextMenuEvent &event)
 
void OnTabContextMenu (wxAuiNotebookEvent &event)
 
void OnCloseClicked (wxAuiNotebookEvent &event)
 
void OnTabPosition (wxCommandEvent &event)
 
void DoShowContextMenu ()
 
int AddPagePrivate (wxWindow *p, const wxString &title, wxBitmap *icon=nullptr)
 
bool InsertPagePrivate (wxWindow *p, const wxString &title, wxBitmap *icon=nullptr, int index=-1)
 

Static Private Member Functions

static int CompareIndexes (Page **p1, Page **p2)
 

Private Attributes

wxBitmap m_DefaultBitmap
 
wxArrayOfPage m_Pages
 

Additional Inherited Members

- Static Public Member Functions inherited from cbAuiNotebook
static void UseToolTips (bool use=true)
 Enable or disable tabtooltips globally. More...
 
static void AllowScrolling (bool allow=true)
 Enable or disable tab-scrolling with mousewheel. More...
 
static void SetModKeys (wxString keys=_T("Strg"))
 Sets the modifier keys for scrolling. More...
 
static void UseModToAdvance (bool use=false)
 Use modkey to advance through tabs with mousewheel. More...
 
static void InvertAdvanceDirection (bool invert=false)
 Change direction of tab-advancing with mousewheel. More...
 
static void InvertMoveDirection (bool invert=false)
 Change direction of tab-moving with mousewheel. More...
 
- Protected Member Functions inherited from cbAuiNotebook
wxString UniqueIdFromTooltip (const wxString &text)
 Create a unique id from the tooltip-text. More...
 
void MinimizeFreeSpace (wxAuiTabCtrl *tabCtrl)
 Minmize free horizontal page of tabCtrl. More...
 
void OnNavigationKeyNotebook (wxNavigationKeyEvent &event)
 Handle the navigation key event. More...
 
void OnIdle (cb_unused wxIdleEvent &event)
 OnIdle. More...
 
void OnTabCtrlDblClick (wxMouseEvent &event)
 Catch doubleclick-events from wxTabCtrl. More...
 
void OnTabCtrlMouseWheel (wxMouseEvent &event)
 Catch mousewheel-events from wxTabCtrl. More...
 
void OnResize (wxSizeEvent &event)
 Catch resize-events and call MinimizeFreeSpace() More...
 
void OnDragDone (wxAuiNotebookEvent &event)
 Catch dragdone-events from wxTabCtrl. More...
 
void OnEnterTabCtrl (wxMouseEvent &event)
 Catch mouseenter-events from wxTabCtrl. More...
 
void OnLeaveTabCtrl (wxMouseEvent &event)
 Catch mouseleave-events from wxTabCtrl. More...
 
bool IsFocusStored (wxWindow *page)
 Checks the old focus. More...
 
void StoreFocus ()
 Save old focus. More...
 
void RestoreFocus ()
 Restore old focus. More...
 
void ResetTabCtrlEvents ()
 Reset tabctrl events. More...
 
void UpdateTabControlsArray ()
 Updates the array, that holds the wxTabCtrls. More...
 
bool CheckKeyModifier ()
 Check for pressed modifier-keys. More...
 
- Protected Member Functions inherited from wxAuiNotebook
bool HasImageList () const
 
wxIcon GetImage (int iconIndex) const
 
- Protected Attributes inherited from cbAuiNotebook
cbAuiTabCtrlArray m_TabCtrls
 Holds the wxTabCtrls used by the notebook. More...
 
int m_LastSelected
 Last selected tab. More...
 
long m_LastId
 Id of last focused window. More...
 
bool m_SetZoomOnIdle
 If true, zoom for all editors is set in next OnIdle-call. More...
 
bool m_MinimizeFreeSpaceOnIdle
 If true, MinimizeFreeSpace is called in next OnIdle-call. More...
 
wxSize m_TabCtrlSize
 Holds the size of a tabCtrl after a resize event. More...
 
- Static Protected Attributes inherited from cbAuiNotebook
static bool s_UseTabTooltips
 Enable or disable tab tooltips. More...
 
static bool s_AllowMousewheel = true
 Enable or disable scrolling tabs with mousewheel. More...
 
static cbAuiNotebookArray s_cbAuiNotebookArray
 Holds an array of all existing cbAuiNotebooks. More...
 
static wxString s_modKeys = _T("Ctrl")
 Holds the modifier keys for scrolling. More...
 
static bool s_modToAdvance = false
 Use modkey to advance through tabs with mousewheel. More...
 
static int s_moveDirection = 1
 Mousewheel move direction: negative => invert. More...
 
static int s_advanceDirection = 1
 Mouseweheel advance direction: negative => invert. More...
 

Detailed Description

Definition at line 25 of file infopane.h.

Member Typedef Documentation

◆ CompareFunction

typedef int(* InfoPane::CompareFunction) (Page **, Page **)
private

Definition at line 41 of file infopane.h.

Constructor & Destructor Documentation

◆ InfoPane()

InfoPane::InfoPane ( wxWindow parent)

Definition at line 56 of file infopane.cpp.

References _T, cbLoadBitmap(), ConfigManager::GetDataFolder(), and wxBITMAP_TYPE_PNG.

◆ ~InfoPane()

InfoPane::~InfoPane ( )
virtual

Definition at line 61 of file infopane.cpp.

References m_Pages.

Member Function Documentation

◆ AddLogger()

bool InfoPane::AddLogger ( Logger logger,
wxWindow p,
const wxString title,
wxBitmap icon = nullptr 
)

◆ AddNonLogger()

bool InfoPane::AddNonLogger ( wxWindow p,
const wxString title,
wxBitmap icon = nullptr 
)

◆ AddPagePrivate()

int InfoPane::AddPagePrivate ( wxWindow p,
const wxString title,
wxBitmap icon = nullptr 
)
private

◆ CompareIndexes()

int InfoPane::CompareIndexes ( Page **  p1,
Page **  p2 
)
staticprivate

Definition at line 116 of file infopane.cpp.

Referenced by DoShowContextMenu(), LoadTabOrder(), and SaveTabOrder().

◆ ContextMenu()

void InfoPane::ContextMenu ( wxContextMenuEvent event)
private

Definition at line 343 of file infopane.cpp.

References DoShowContextMenu().

◆ DeleteLogger()

bool InfoPane::DeleteLogger ( Logger l)

◆ DeleteNonLogger()

bool InfoPane::DeleteNonLogger ( wxWindow p)

◆ DoShowContextMenu()

void InfoPane::DoShowContextMenu ( )
private

◆ GetCurrentPage()

int InfoPane::GetCurrentPage ( bool &  is_logger)

◆ GetLogger()

Logger * InfoPane::GetLogger ( int  index)

Definition at line 216 of file infopane.cpp.

References m_Pages, and NULL.

◆ GetPageIndexByWindow()

int InfoPane::GetPageIndexByWindow ( wxWindow win)

Definition at line 199 of file infopane.cpp.

References m_Pages.

Referenced by DoShowContextMenu(), GetCurrentPage(), OnClear(), OnCloseClicked(), OnCopy(), and OnWrapMode().

◆ GetWindow()

wxWindow * InfoPane::GetWindow ( int  index)

Definition at line 223 of file infopane.cpp.

References m_Pages, and NULL.

◆ Hide() [1/2]

void InfoPane::Hide ( size_t  i)
private

◆ Hide() [2/2]

void InfoPane::Hide ( Logger logger)

Definition at line 241 of file infopane.cpp.

References m_Pages, and Toggle().

◆ HideNonLogger()

void InfoPane::HideNonLogger ( wxWindow p)

Definition at line 269 of file infopane.cpp.

References m_Pages, and Toggle().

◆ InsertPagePrivate()

bool InfoPane::InsertPagePrivate ( wxWindow p,
const wxString title,
wxBitmap icon = nullptr,
int  index = -1 
)
private

Definition at line 160 of file infopane.cpp.

References cbAuiNotebook::InsertPage(), and m_DefaultBitmap.

Referenced by Toggle().

◆ LoadTabOrder()

void InfoPane::LoadTabOrder ( wxString  layout)

◆ OnClear()

void InfoPane::OnClear ( wxCommandEvent event)
private

◆ OnCloseClicked()

void InfoPane::OnCloseClicked ( wxAuiNotebookEvent event)
private

◆ OnCopy()

void InfoPane::OnCopy ( wxCommandEvent event)
private

◆ OnMenu()

void InfoPane::OnMenu ( wxCommandEvent event)
private

Definition at line 327 of file infopane.cpp.

References m_Pages, and Toggle().

◆ OnTabContextMenu()

void InfoPane::OnTabContextMenu ( wxAuiNotebookEvent event)
private

◆ OnTabPosition()

void InfoPane::OnTabPosition ( wxCommandEvent event)
private

Definition at line 435 of file infopane.cpp.

References _T, Manager::Get(), Manager::GetConfigManager(), and ConfigManager::Write().

◆ OnWrapMode()

void InfoPane::OnWrapMode ( wxCommandEvent event)
private

◆ RemoveNonLogger()

bool InfoPane::RemoveNonLogger ( wxWindow p)

◆ ReorderTabs()

void InfoPane::ReorderTabs ( CompareFunction  cmp_f)
private

◆ SaveTabOrder()

wxString InfoPane::SaveTabOrder ( )

◆ Show() [1/2]

void InfoPane::Show ( size_t  index)

◆ Show() [2/2]

void InfoPane::Show ( Logger logger)

◆ ShowNonLogger()

void InfoPane::ShowNonLogger ( wxWindow p)

◆ Toggle()

void InfoPane::Toggle ( size_t  index)
private

◆ UpdateEffectiveTabOrder()

void InfoPane::UpdateEffectiveTabOrder ( )

◆ WX_DEFINE_ARRAY()

InfoPane::WX_DEFINE_ARRAY ( Page ,
wxArrayOfPage   
)
private

Member Data Documentation

◆ m_DefaultBitmap

wxBitmap InfoPane::m_DefaultBitmap
private

Definition at line 45 of file infopane.h.

Referenced by AddPagePrivate(), and InsertPagePrivate().

◆ m_Pages

wxArrayOfPage InfoPane::m_Pages
private

The documentation for this class was generated from the following files: