Main Page | Class Hierarchy | Alphabetical List | Compound List | File List | Compound Members

DibCtl.h

00001 /*
00002 /--------------------------------------------------------------------
00003 |
00004 |      $Id: DibCtl.h,v 1.8 2002/08/04 20:08:01 uzadow Exp $
00005 |
00006 \--------------------------------------------------------------------
00007 */
00008 /////////////////////////////////////////////////////////////////////////////
00009 // Copyright (C) 1998 by Jorge Lodos
00010 // All rights reserved
00011 //
00012 // Distribute and use freely, except:
00013 // 1. Don't alter or remove this notice.
00014 // 2. Mark the changes you made
00015 //
00016 // Send bug reports, bug fixes, enhancements, requests, etc. to:
00017 //    lodos@cigb.edu.cu
00018 /////////////////////////////////////////////////////////////////////////////
00019 
00020 //  adapted to paintlib by bdelmee@skynet.be, 1998
00021 
00022 #ifndef INCL_DIBCTL
00023 #define INCL_DIBCTL
00024 
00025 #if _MSC_VER >= 1000
00026 #pragma once
00027 #endif // _MSC_VER >= 1000
00028 
00029 #include "WinBmpEx.h"
00030 
00031 /////////////////////////////////////////////////////////////////////////////
00032 // CDIBStatic window
00033 
00034 class CDIBStatic : public CStatic
00035 {
00036     // Construction
00037 public:
00038     CDIBStatic() : m_bHasFile(false)
00039         {} ;
00040     virtual ~CDIBStatic()
00041         {} ;
00042 
00043     // Attributes
00044 private:
00045     PLWinBmpEx  m_DIB;
00046     bool        m_bHasFile;
00047 
00048     // Operations
00049 public:
00050     bool IsValidDib() const
00051     {
00052         return m_bHasFile;
00053     }
00054     bool LoadDib(LPCTSTR lpszFileName);
00055     void UpdateDib();
00056     void RemoveDib();
00057 
00058     bool DoRealizePalette(bool bForceBackGround);
00059 
00060     // Overrides
00061     // ClassWizard generated virtual function overrides
00062     //{{AFX_VIRTUAL(CDIBStatic)
00063     //}}AFX_VIRTUAL
00064 
00065 protected:
00066     void ClearDib();
00067     void PaintDib(bool bDibValid);
00068 
00069     // Generated message map functions
00070 protected:
00071     //{{AFX_MSG(CDIBStatic)
00072     afx_msg HBRUSH CtlColor(CDC* pDC, UINT nCtlColor);
00073     afx_msg BOOL OnQueryNewPalette();
00074     afx_msg void OnPaletteChanged(CWnd* pFocusWnd);
00075     //}}AFX_MSG
00076 
00077     DECLARE_MESSAGE_MAP()
00078 };
00079 
00080 /////////////////////////////////////////////////////////////////////////////
00081 
00082 //{{AFX_INSERT_LOCATION}}
00083 // Microsoft Developer Studio will insert additional declarations immediately before the previous line.
00084 
00085 #endif // INCL_DIBCTL
00086 /*
00087 /--------------------------------------------------------------------
00088 |
00089 |      $Log: DibCtl.h,v $
00090 |      Revision 1.8  2002/08/04 20:08:01  uzadow
00091 |      Added PLBmpInfo class, ability to extract metainformation from images without loading the whole image and proper greyscale support.
00092 |
00093 |      Revision 1.7  2002/01/27 18:20:18  uzadow
00094 |      Updated copyright message; corrected pcx decoder bug.
00095 |
00096 |      Revision 1.6  2000/03/28 21:05:03  Ulrich von Zadow
00097 |      Added zoom capability.
00098 |
00099 |      Revision 1.5  2000/01/10 23:53:01  Ulrich von Zadow
00100 |      Changed formatting & removed tabs.
00101 |
00102 |      Revision 1.4  1999/12/02 17:07:35  Ulrich von Zadow
00103 |      Changes by bdelmee.
00104 |
00105 |
00106 --------------------------------------------------------------------
00107 */

Generated on Sun Jun 6 13:42:21 2004 for paintlib by doxygen 1.3.2