00001 /* 00002 * 00003 * ChartGradient.h 00004 * 00005 * Written by Cédric Moonen (cedric_moonen@hotmail.com) 00006 * 00007 * 00008 * 00009 * This code may be used for any non-commercial and commercial purposes in a compiled form. 00010 * The code may be redistributed as long as it remains unmodified and providing that the 00011 * author name and this disclaimer remain intact. The sources can be modified WITH the author 00012 * consent only. 00013 * 00014 * This code is provided without any garanties. I cannot be held responsible for the damage or 00015 * the loss of time it causes. Use it at your own risks 00016 * 00017 * An e-mail to notify me that you are using this code is appreciated also. 00018 * 00019 * 00020 */ 00021 00022 #pragma once 00023 00025 enum EGradientType 00026 { 00028 gtHorizontal, 00030 gtVertical, 00032 gtHorizontalDouble, 00034 gtVerticalDouble 00035 }; 00036 00038 00042 class CChartGradient 00043 { 00044 public: 00046 CChartGradient(); 00048 ~CChartGradient(); 00049 00051 00063 static void DrawGradient(CDC* pDC, const CRect& GradientRect, COLORREF Color1, 00064 COLORREF Color2, EGradientType GradientType); 00065 };