2001-04-22 18:21:21 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
2009-03-09 19:08:36 -04:00
|
|
|
// Name: wx/imagxpm.h
|
2001-04-22 18:21:21 -04:00
|
|
|
// Purpose: wxImage XPM handler
|
|
|
|
// Author: Vaclav Slavik
|
|
|
|
// Copyright: (c) 2001 Vaclav Slavik
|
2004-05-23 16:53:33 -04:00
|
|
|
// Licence: wxWindows licence
|
2001-04-22 18:21:21 -04:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _WX_IMAGXPM_H_
|
|
|
|
#define _WX_IMAGXPM_H_
|
|
|
|
|
|
|
|
#include "wx/image.h"
|
|
|
|
|
2008-09-03 03:29:31 -04:00
|
|
|
#if wxUSE_XPM
|
2001-04-22 18:21:21 -04:00
|
|
|
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
// wxXPMHandler
|
|
|
|
//-----------------------------------------------------------------------------
|
|
|
|
|
2008-03-26 11:06:00 -04:00
|
|
|
class WXDLLIMPEXP_CORE wxXPMHandler : public wxImageHandler
|
2001-04-22 18:21:21 -04:00
|
|
|
{
|
|
|
|
public:
|
2002-12-04 09:11:26 -05:00
|
|
|
inline wxXPMHandler()
|
|
|
|
{
|
|
|
|
m_name = wxT("XPM file");
|
|
|
|
m_extension = wxT("xpm");
|
|
|
|
m_type = wxBITMAP_TYPE_XPM;
|
|
|
|
m_mime = wxT("image/xpm");
|
|
|
|
}
|
2001-04-22 18:21:21 -04:00
|
|
|
|
|
|
|
#if wxUSE_STREAMS
|
2014-03-29 20:02:23 -04:00
|
|
|
virtual bool LoadFile( wxImage *image, wxInputStream& stream, bool verbose=true, int index=-1 ) wxOVERRIDE;
|
|
|
|
virtual bool SaveFile( wxImage *image, wxOutputStream& stream, bool verbose=true ) wxOVERRIDE;
|
2006-02-08 16:47:09 -05:00
|
|
|
protected:
|
2014-03-29 20:02:23 -04:00
|
|
|
virtual bool DoCanRead( wxInputStream& stream ) wxOVERRIDE;
|
2001-04-22 18:21:21 -04:00
|
|
|
#endif
|
2002-12-04 09:11:26 -05:00
|
|
|
|
|
|
|
private:
|
2015-04-23 07:49:01 -04:00
|
|
|
wxDECLARE_DYNAMIC_CLASS(wxXPMHandler);
|
2001-04-22 18:21:21 -04:00
|
|
|
};
|
|
|
|
|
2008-09-03 03:29:31 -04:00
|
|
|
#endif // wxUSE_XPM
|
2001-04-22 18:21:21 -04:00
|
|
|
|
2009-03-09 19:08:36 -04:00
|
|
|
#endif // _WX_IMAGXPM_H_
|