mprogressbar.h

Go to the documentation of this file.
00001 
00018 #ifdef _MGNCSCTRL_PROGRESSBAR
00019 
00020 #ifndef _MGUI_NCSCTRL_PROGRESSBAR_H
00021 #define _MGUI_NCSCTRL_PROGRESSBAR_H
00022 
00023 #ifdef __cplusplus
00024 extern "C" {
00025 #endif  /* __cplusplus */
00026 
00032 /*
00033  * \def NCSCTRL_PROGRESSBAR
00034  * \brief the name of progressbar control
00035 */
00036 
00037 #define NCSCTRL_PROGRESSBAR   NCSCLASSNAME("progressbar")
00038 
00039 typedef struct _mProgressBar            mProgressBar;
00040 typedef struct _mProgressBarClass       mProgressBarClass;
00041 typedef struct _mProgressBarRenderer    mProgressBarRenderer;
00042 
00043 #define mProgressBarHeader(Class)   \
00044     mWidgetHeader(Class)
00045 
00052 struct _mProgressBar
00053 {
00054         mProgressBarHeader(mProgressBar)
00055 };
00056 
00057 #define mProgressBarClassHeader(clsName, parentClass) \
00058         mWidgetClassHeader(clsName, parentClass)          \
00059     int (*increase)(clsName *self, int delta);       \
00060     int (*stepIncrease)(clsName *self);
00061 
00078 struct _mProgressBarClass
00079 {
00080         mProgressBarClassHeader(mProgressBar, mWidget)
00081 };
00082 
00089 MGNCS_EXPORT extern mProgressBarClass g_stmProgressBarCls;
00090 
00091 #define mProgressBarRendererHeader(clsName, parentClass) \
00092         mWidgetRendererHeader(clsName, parentClass) \
00093     void (*drawProgress)(clsName* self, HDC hdc, const RECT *rc);
00094 
00107 struct _mProgressBarRenderer
00108 {
00109         mProgressBarRendererHeader(mProgressBar, mWidget)
00110 };
00111 
00112 #define mHProgressBar mProgressBar
00113 #define mHProgressBarClass mProgressBarClass
00114 #define g_stmHProgressBarCls  g_stmProgressBarCls
00115 
00116 #define mVProgressBar mProgressBar
00117 #define mVProgressBarClass mProgressBarClass
00118 #define g_stmVProgressBarCls  g_stmProgressBarCls
00119 
00125 enum mProgressBarProp
00126 {
00132     NCSP_PROG_MAXPOS = NCSP_WIDGET_MAX + 1, 
00138     NCSP_PROG_MINPOS,                       
00144     NCSP_PROG_CURPOS,                       
00150     NCSP_PROG_LINESTEP,                     
00151     NCSP_PROG_MAX
00152 };
00153 
00158 #define NCSS_PRGBAR_HORIZONTAL          0x0000L
00159 
00164 #define NCSS_PRGBAR_VERTICAL            (0x0001L<<NCSS_WIDGET_SHIFT)
00165 
00170 #define NCSS_PRGBAR_BLOCKS              (0x0002L<<NCSS_WIDGET_SHIFT)
00171 
00176 #define NCSS_PRGBAR_SMOOTH              (0x0000L<<NCSS_WIDGET_SHIFT)
00177 
00182 #define NCSS_PRGBAR_SHOWPERCENT         (0x0004L<<NCSS_WIDGET_SHIFT)
00183 
00184 #define NCSS_PRGBAR_SHIFT  (NCSS_WIDGET_SHIFT+5)
00185 
00188 #ifdef __cplusplus
00189 }
00190 #endif  /* __cplusplus */
00191 
00192 #endif /* _MGUI_NCSCTRL_PROGRESSBAR_H */
00193 #endif //_MGNCSCTRL_PROGRESSBAR
Generated on Fri Jun 10 11:18:06 2011 for New Control Set V1.0.0 API Reference by  doxygen 1.6.3