wxwidgets/include/wx/qt/dcclient.h
ali kettab 0c6e2fafd6 Make wxWindowDC work if constructed outside of a paint event under wxQt
Also prepare wxScreenDC to work with wxOverlay (in the upcoming commit)
2023-11-23 22:49:15 +01:00

60 lines
1.4 KiB
C++

/////////////////////////////////////////////////////////////////////////////
// Name: wx/qt/dcclient.h
// Author: Peter Most, Javier Torres, Mariano Reingart
// Copyright: (c) 2010 wxWidgets dev team
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#ifndef _WX_QT_DCCLIENT_H_
#define _WX_QT_DCCLIENT_H_
#include "wx/qt/dc.h"
#include <memory>
class QPicture;
class WXDLLIMPEXP_CORE wxWindowDCImpl : public wxQtDCImpl
{
public:
wxWindowDCImpl( wxDC *owner );
wxWindowDCImpl( wxDC *owner, wxWindow *win );
~wxWindowDCImpl();
protected:
std::unique_ptr<QPicture> m_pict;
// @true if m_qtPainter is owned by the window, @false otherwise (default).
bool m_isWindowPainter = false;
private:
wxDECLARE_CLASS(wxWindowDCImpl);
wxDECLARE_NO_COPY_CLASS(wxWindowDCImpl);
};
class WXDLLIMPEXP_CORE wxClientDCImpl : public wxWindowDCImpl
{
public:
wxClientDCImpl( wxDC *owner );
wxClientDCImpl( wxDC *owner, wxWindow *win );
private:
wxDECLARE_CLASS(wxClientDCImpl);
wxDECLARE_NO_COPY_CLASS(wxClientDCImpl);
};
class WXDLLIMPEXP_CORE wxPaintDCImpl : public wxClientDCImpl
{
public:
wxPaintDCImpl( wxDC *owner );
wxPaintDCImpl( wxDC *owner, wxWindow *win );
private:
wxDECLARE_CLASS(wxPaintDCImpl);
wxDECLARE_NO_COPY_CLASS(wxPaintDCImpl);
};
#endif // _WX_QT_DCCLIENT_H_