21 #ifndef __ANTARES_TOOLBOX_COMPONENT_MAPNOTEBOOK_H__
22 #define __ANTARES_TOOLBOX_COMPONENT_MAPNOTEBOOK_H__
25 #include <wx/textctrl.h>
26 #include <antares/logs/logs.h>
27 namespace Antares::Component
54 bool remove(
Page* page);
61 wxTextCtrl((wxWindow*)parent,
64 wxPoint(pageToRename->pBoundingBox.x, pageToRename->pBoundingBox.y),
65 pageToRename->pBoundingBox.GetSize(),
68 pNotebook(&(parent->pNotebook))
74 void OnTextEnter(wxCommandEvent& evt);
82 Move(pPage->pBoundingBox.x, pPage->pBoundingBox.y);
83 SetSize(pPage->pBoundingBox.GetSize());
114 tabButton(std::string imagePath,
117 const char* hoverImagePath =
nullptr);
119 void drawButton(wxDC& dc,
int x,
int y);
123 void onClick(wxMouseEvent&, BtnType t);
127 wxBitmap* buttonImage =
nullptr;
128 wxBitmap* hoverImage =
nullptr;
129 wxRect* pBoundingBox =
nullptr;
130 MapTabs* parentTabFrame =
nullptr;
132 bool drawHover =
false;
137 int remainingRightTabs;
138 tabButton* rightTabScroll;
139 tabButton* leftTabScroll;
140 tabButton* addPageButton;
148 delete rightTabScroll;
149 delete leftTabScroll;
150 delete addPageButton;
153 void onDraw(wxPaintEvent&);
154 void drawOrientationTop(wxDC& dc);
163 void drawItemTop(wxDC& dc,
Page* page,
int& pos, Notebook::Alignment align);
165 void onMouseMove(wxMouseEvent&);
173 DECLARE_EVENT_TABLE()
177 wxRect closePageBoundingBox;
Definition: mapnotebook.h:100
void onMouseUp(wxMouseEvent &)
Click up.
Definition: mapnotebook.cpp:476
Yuni::Event< void(int &, int &)> onMouseMotion
Event: adding a page.
Definition: mapnotebook.h:171
void doSizing(wxDC &dc)
compute the offset and draw tab scrolling button if tabs don't fit in the window \
Definition: mapnotebook.cpp:324
Definition: mapnotebook.h:58
MapNotebook.
Definition: mapnotebook.h:33
Yuni::Event< void(Page &)> onPageDelete
Event: Page deletion.
Definition: mapnotebook.h:192
void onMapLayerChanged(const wxString *text)
remove a page by its name
Definition: mapnotebook.cpp:88
Yuni::Event onAddPage
Event: adding a page.
Definition: mapnotebook.h:183
MapNotebook(wxWindow *parent, Notebook::Orientation orientation=orLeft)
Default constructor.
Definition: mapnotebook.cpp:47
Definition: notebook.h:61
const wxString & caption() const
Get the caption of the page.
Definition: notebook.hxx:36
Definition: notebook.h:348
Notebook.
Definition: notebook.h:36
Orientation orientation() const
Get the orientation of the notebook.
Definition: notebook.hxx:111
virtual void onMouseEnter()
The mouse has entered.
Definition: panel.h:69
virtual void onMouseLeave()
The mouse has leaved.
Definition: panel.h:74