1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
|
#ifndef CLEDITORBAR_H
#define CLEDITORBAR_H
#include "drawingutils.h"
#include "wxcrafter_plugin.h"
#include <vector>
#include <wx/colour.h>
#include <wx/font.h>
class WXDLLIMPEXP_SDK clEditorBar : public clEditorBarBase
{
wxString m_classname;
wxString m_function;
wxColour m_functionColour;
wxColour m_classColour;
wxColour m_defaultColour;
wxColour m_bgColour;
wxFont m_textFont;
wxRect m_scopeRect;
eButtonState m_scopeButtonState;
wxBitmap m_functionBmp;
// Breadcrumbs
wxString m_filename;
wxString m_filenameRelative;
wxString m_projectFile;
wxString m_projectName;
wxArrayString m_breadcrumbs;
wxRect m_filenameRect;
eButtonState m_state;
// Bookmarks button
wxBitmap m_bookmarksBmp;
wxRect m_bookmarksRect;
eButtonState m_bookmarksButtonState;
std::vector<std::pair<int, wxString> > m_bookmarks;
private:
void DoRefreshColoursAndFonts();
void DoRefresh();
void CreateBookmarksBitmap();
public:
clEditorBar(wxWindow* parent);
virtual ~clEditorBar();
void SetMessage(const wxString& className, const wxString& function);
void DoShow(bool s);
protected:
void OnMarkerChanged(clCommandEvent& event);
void OnEditorSize(wxSizeEvent& e);
void OnEraseBG(wxEraseEvent& e);
void OnPaint(wxPaintEvent& e);
void OnEditorChanged(wxCommandEvent& e);
void OnLeftDown(wxMouseEvent& e);
void OnLeftUp(wxMouseEvent& e);
void OnThemeChanged(wxCommandEvent& e);
void OnIdle(wxIdleEvent& event);
};
#endif // CLEDITORBAR_H
|