]> git.saurik.com Git - wxWidgets.git/blame - include/wx/mgl/private.h
more f*h interface file revisions
[wxWidgets.git] / include / wx / mgl / private.h
CommitLineData
32b8ec41
VZ
1/////////////////////////////////////////////////////////////////////////////
2// Name: private.h
3// Purpose: Private declarations: as this header is only included by
77ffb593 4// wxWidgets itself, it may contain identifiers which don't start
32b8ec41
VZ
5// with "wx".
6// Author: Vaclav Slavik
7// Created: 2001/04/07
8// RCS-ID: $Id$
52750c2e 9// Copyright: (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
65571936 10// Licence: wxWindows licence
32b8ec41
VZ
11/////////////////////////////////////////////////////////////////////////////
12
ec75509f
WS
13#ifndef _WX_MGL_PRIVATE_H_
14#define _WX_MGL_PRIVATE_H_
32b8ec41 15
ec75509f 16#include "wx/ioswrap.h"
32b8ec41 17#include <mgraph.hpp>
7332adf0 18#include "pmapi.h"
32b8ec41 19
5fe8edce
MW
20// the scitech headers define true and false
21#undef true
22#undef false
23
b5dbe15d 24class WXDLLIMPEXP_FWD_CORE wxBitmap;
32b8ec41
VZ
25
26
27// ---------------------------------------------------------------------------
28// private variables
29// ---------------------------------------------------------------------------
30
31extern MGLDevCtx *g_displayDC;
a4bbc9f7 32extern winmng_t *g_winMng;
32b8ec41
VZ
33
34// ---------------------------------------------------------------------------
35// helper functions
36// ---------------------------------------------------------------------------
37
38
39// This function converts wxBitmap into pixpattern24_t representation
40// (used by wxBrush and wxPen)
41
ec75509f 42extern void wxBitmapToPixPattern(const wxBitmap& bitmap,
32b8ec41 43 pixpattern24_t *pix, pattern_t *mask);
ec75509f 44
32b8ec41
VZ
45
46// Sets current DC and restores previous one upon destruction:
47class wxCurrentDCSwitcher
48{
49public:
50 wxCurrentDCSwitcher(MGLDevCtx *dc)
51 { m_old = dc->makeCurrent(); }
52 ~wxCurrentDCSwitcher()
53 { MGL_makeCurrentDC(m_old); }
54 MGLDC *m_old;
55};
56
57
ec75509f 58#endif // _WX_MGL_PRIVATE_H_