imagpcx.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /////////////////////////////////////////////////////////////////////////////
  2. // Name: wx/imagpcx.h
  3. // Purpose: wxImage PCX handler
  4. // Author: Guillermo Rodriguez Garcia <guille@iies.es>
  5. // Copyright: (c) 1999 Guillermo Rodriguez Garcia
  6. // Licence: wxWindows licence
  7. /////////////////////////////////////////////////////////////////////////////
  8. #ifndef _WX_IMAGPCX_H_
  9. #define _WX_IMAGPCX_H_
  10. #include "wx/image.h"
  11. //-----------------------------------------------------------------------------
  12. // wxPCXHandler
  13. //-----------------------------------------------------------------------------
  14. #if wxUSE_PCX
  15. class WXDLLIMPEXP_CORE wxPCXHandler : public wxImageHandler
  16. {
  17. public:
  18. inline wxPCXHandler()
  19. {
  20. m_name = wxT("PCX file");
  21. m_extension = wxT("pcx");
  22. m_type = wxBITMAP_TYPE_PCX;
  23. m_mime = wxT("image/pcx");
  24. }
  25. #if wxUSE_STREAMS
  26. virtual bool LoadFile( wxImage *image, wxInputStream& stream, bool verbose=true, int index=-1 );
  27. virtual bool SaveFile( wxImage *image, wxOutputStream& stream, bool verbose=true );
  28. protected:
  29. virtual bool DoCanRead( wxInputStream& stream );
  30. #endif // wxUSE_STREAMS
  31. private:
  32. DECLARE_DYNAMIC_CLASS(wxPCXHandler)
  33. };
  34. #endif // wxUSE_PCX
  35. #endif
  36. // _WX_IMAGPCX_H_