2001-06-26 21:05:06 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: private.h
|
|
|
|
// Purpose: Private declarations: as this header is only included by
|
2004-05-23 14:56:36 +00:00
|
|
|
// wxWidgets itself, it may contain identifiers which don't start
|
2001-06-26 21:05:06 +00:00
|
|
|
// with "wx".
|
|
|
|
// Author: Vaclav Slavik
|
|
|
|
// Created: 2001/04/07
|
|
|
|
// RCS-ID: $Id$
|
2002-02-14 20:30:34 +00:00
|
|
|
// Copyright: (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
|
2004-05-23 20:53:33 +00:00
|
|
|
// Licence: wxWindows licence
|
2001-06-26 21:05:06 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2005-05-19 19:37:59 +00:00
|
|
|
#ifndef _WX_MGL_PRIVATE_H_
|
|
|
|
#define _WX_MGL_PRIVATE_H_
|
2001-06-26 21:05:06 +00:00
|
|
|
|
2005-05-19 19:37:59 +00:00
|
|
|
#include "wx/ioswrap.h"
|
2001-06-26 21:05:06 +00:00
|
|
|
#include <mgraph.hpp>
|
2001-12-14 19:24:49 +00:00
|
|
|
#include "pmapi.h"
|
2001-06-26 21:05:06 +00:00
|
|
|
|
2006-01-04 14:14:32 +00:00
|
|
|
// the scitech headers define true and false
|
|
|
|
#undef true
|
|
|
|
#undef false
|
|
|
|
|
2001-06-26 21:05:06 +00:00
|
|
|
class WXDLLEXPORT wxBitmap;
|
|
|
|
|
|
|
|
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
// private variables
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
|
|
|
|
extern MGLDevCtx *g_displayDC;
|
2001-08-01 22:57:11 +00:00
|
|
|
extern winmng_t *g_winMng;
|
2001-06-26 21:05:06 +00:00
|
|
|
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
// helper functions
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
|
|
// This function converts wxBitmap into pixpattern24_t representation
|
|
|
|
// (used by wxBrush and wxPen)
|
|
|
|
|
2005-05-19 19:37:59 +00:00
|
|
|
extern void wxBitmapToPixPattern(const wxBitmap& bitmap,
|
2001-06-26 21:05:06 +00:00
|
|
|
pixpattern24_t *pix, pattern_t *mask);
|
2005-05-19 19:37:59 +00:00
|
|
|
|
2001-06-26 21:05:06 +00:00
|
|
|
|
|
|
|
// Sets current DC and restores previous one upon destruction:
|
|
|
|
class wxCurrentDCSwitcher
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
wxCurrentDCSwitcher(MGLDevCtx *dc)
|
|
|
|
{ m_old = dc->makeCurrent(); }
|
|
|
|
~wxCurrentDCSwitcher()
|
|
|
|
{ MGL_makeCurrentDC(m_old); }
|
|
|
|
MGLDC *m_old;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2005-05-19 19:37:59 +00:00
|
|
|
#endif // _WX_MGL_PRIVATE_H_
|