2006-06-06 09:12:07 -04:00
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
2006-06-06 11:39:16 -04:00
|
|
|
// Name: wx/aui/dockart.h
|
2006-06-06 09:12:07 -04:00
|
|
|
// Purpose: wxaui: wx advanced user interface - docking window manager
|
|
|
|
// Author: Benjamin I. Williams
|
|
|
|
// Modified by:
|
|
|
|
// Created: 2005-05-17
|
2006-06-06 11:39:16 -04:00
|
|
|
// RCS-ID: $Id$
|
2006-06-06 09:12:07 -04:00
|
|
|
// Copyright: (C) Copyright 2005, Kirix Corporation, All Rights Reserved.
|
|
|
|
// Licence: wxWindows Library Licence, Version 3.1
|
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _WX_DOCKART_H_
|
|
|
|
#define _WX_DOCKART_H_
|
|
|
|
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
// headers
|
|
|
|
// ----------------------------------------------------------------------------
|
|
|
|
|
|
|
|
#include "wx/defs.h"
|
|
|
|
|
|
|
|
#if wxUSE_AUI
|
|
|
|
|
2006-06-06 10:05:11 -04:00
|
|
|
#include "wx/pen.h"
|
|
|
|
#include "wx/brush.h"
|
|
|
|
#include "wx/bitmap.h"
|
|
|
|
#include "wx/colour.h"
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
// dock art provider code - a dock provider provides all drawing
|
|
|
|
// functionality to the wxAui dock manager. This allows the dock
|
|
|
|
// manager to have plugable look-and-feels
|
|
|
|
|
2006-11-01 13:51:44 -05:00
|
|
|
class WXDLLIMPEXP_AUI wxAuiDockArt
|
2006-06-06 09:12:07 -04:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiDockArt() { }
|
|
|
|
virtual ~wxAuiDockArt() { }
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
virtual int GetMetric(int id) = 0;
|
2011-10-30 10:20:03 -04:00
|
|
|
virtual void SetMetric(int id, int newVal) = 0;
|
2006-06-06 09:12:07 -04:00
|
|
|
virtual void SetFont(int id, const wxFont& font) = 0;
|
|
|
|
virtual wxFont GetFont(int id) = 0;
|
|
|
|
virtual wxColour GetColour(int id) = 0;
|
|
|
|
virtual void SetColour(int id, const wxColor& colour) = 0;
|
2006-07-07 13:53:17 -04:00
|
|
|
wxColour GetColor(int id) { return GetColour(id); }
|
|
|
|
void SetColor(int id, const wxColour& color) { SetColour(id, color); }
|
2006-06-06 11:39:16 -04:00
|
|
|
|
2006-06-06 09:12:07 -04:00
|
|
|
virtual void DrawSash(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int orientation,
|
|
|
|
const wxRect& rect) = 0;
|
|
|
|
|
|
|
|
virtual void DrawBackground(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int orientation,
|
|
|
|
const wxRect& rect) = 0;
|
|
|
|
|
|
|
|
virtual void DrawCaption(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxString& text,
|
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane) = 0;
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
virtual void DrawGripper(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane) = 0;
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
virtual void DrawBorder(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane) = 0;
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
virtual void DrawPaneButton(wxDC& dc,
|
2006-11-06 02:09:56 -05:00
|
|
|
wxWindow* window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int button,
|
2011-10-30 10:20:03 -04:00
|
|
|
int buttonState,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane) = 0;
|
2006-06-06 09:12:07 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2006-11-01 13:51:44 -05:00
|
|
|
// this is the default art provider for wxAuiManager. Dock art
|
2006-06-06 09:12:07 -04:00
|
|
|
// can be customized by creating a class derived from this one,
|
|
|
|
// or replacing this class entirely
|
|
|
|
|
2006-11-01 13:51:44 -05:00
|
|
|
class WXDLLIMPEXP_AUI wxAuiDefaultDockArt : public wxAuiDockArt
|
2006-06-06 09:12:07 -04:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiDefaultDockArt();
|
2006-06-06 09:12:07 -04:00
|
|
|
|
2011-10-30 10:20:03 -04:00
|
|
|
int GetMetric(int metricId);
|
|
|
|
void SetMetric(int metricId, int newVal);
|
2006-06-06 09:12:07 -04:00
|
|
|
wxColour GetColour(int id);
|
|
|
|
void SetColour(int id, const wxColor& colour);
|
|
|
|
void SetFont(int id, const wxFont& font);
|
|
|
|
wxFont GetFont(int id);
|
|
|
|
|
|
|
|
void DrawSash(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int orientation,
|
|
|
|
const wxRect& rect);
|
|
|
|
|
|
|
|
void DrawBackground(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int orientation,
|
|
|
|
const wxRect& rect);
|
|
|
|
|
|
|
|
void DrawCaption(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxString& text,
|
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane);
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
void DrawGripper(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane);
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
void DrawBorder(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane);
|
2006-06-06 09:12:07 -04:00
|
|
|
|
|
|
|
void DrawPaneButton(wxDC& dc,
|
2006-09-02 08:37:25 -04:00
|
|
|
wxWindow *window,
|
2006-06-06 09:12:07 -04:00
|
|
|
int button,
|
2011-10-30 10:20:03 -04:00
|
|
|
int buttonState,
|
2006-06-06 09:12:07 -04:00
|
|
|
const wxRect& rect,
|
2006-11-01 13:51:44 -05:00
|
|
|
wxAuiPaneInfo& pane);
|
2006-06-06 09:12:07 -04:00
|
|
|
|
2011-01-12 08:39:36 -05:00
|
|
|
void DrawIcon(wxDC& dc,
|
|
|
|
const wxRect& rect,
|
|
|
|
wxAuiPaneInfo& pane);
|
|
|
|
|
2006-06-06 09:12:07 -04:00
|
|
|
protected:
|
|
|
|
|
|
|
|
void DrawCaptionBackground(wxDC& dc, const wxRect& rect, bool active);
|
|
|
|
|
2010-12-03 07:40:28 -05:00
|
|
|
void InitBitmaps();
|
|
|
|
|
2006-06-06 09:12:07 -04:00
|
|
|
protected:
|
|
|
|
|
2011-10-30 10:20:03 -04:00
|
|
|
wxPen m_borderPen;
|
|
|
|
wxBrush m_sashBrush;
|
|
|
|
wxBrush m_backgroundBrush;
|
|
|
|
wxBrush m_gripperBrush;
|
|
|
|
wxFont m_captionFont;
|
|
|
|
wxBitmap m_inactiveCloseBitmap;
|
|
|
|
wxBitmap m_inactivePinBitmap;
|
|
|
|
wxBitmap m_inactiveMaximizeBitmap;
|
|
|
|
wxBitmap m_inactiveRestoreBitmap;
|
|
|
|
wxBitmap m_activeCloseBitmap;
|
|
|
|
wxBitmap m_activePinBitmap;
|
|
|
|
wxBitmap m_activeMaximizeBitmap;
|
|
|
|
wxBitmap m_activeRestoreBitmap;
|
|
|
|
wxPen m_gripperPen1;
|
|
|
|
wxPen m_gripperPen2;
|
|
|
|
wxPen m_gripperPen3;
|
|
|
|
wxColour m_baseColour;
|
|
|
|
wxColour m_activeCaptionColour;
|
|
|
|
wxColour m_activeCaptionGradientColour;
|
|
|
|
wxColour m_activeCaptionTextColour;
|
|
|
|
wxColour m_inactiveCaptionColour;
|
|
|
|
wxColour m_inactiveCaptionGradientColour;
|
|
|
|
wxColour m_inactiveCaptionTextColour;
|
|
|
|
int m_borderSize;
|
|
|
|
int m_captionSize;
|
|
|
|
int m_sashSize;
|
|
|
|
int m_buttonSize;
|
|
|
|
int m_gripperSize;
|
|
|
|
int m_gradientType;
|
2006-06-06 09:12:07 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#endif // wxUSE_AUI
|
|
|
|
#endif //_WX_DOCKART_H_
|