Click here to Skip to main content
13,298,655 members (48,520 online)
Click here to Skip to main content


76 bookmarked
Posted 21 Jan 2001

Enhanced Progress Bar Control

, 11 Jun 2002
An enhanced progress control that supports gradient shading, formatted text, animation, tooltips, shape, 'snake' and reverse modes, and vertical modes
// ProgressBarTestDlg.h : header file

#if !defined(AFX_PROGRESSBARTESTDLG_H__476B90AA_6932_11D4_B261_00104BB13A66__INCLUDED_)
#define AFX_PROGRESSBARTESTDLG_H__476B90AA_6932_11D4_B261_00104BB13A66__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "ProgressCtrlX.h"

// CProgressBarTestDlg dialog

class CProgressBarTestDlg : public CDialog
// Construction
	CProgressBarTestDlg(CWnd* pParent = NULL);	// standard constructor

// Dialog Data
	CButton	m_btnAnimate;
	CButton	m_btnRun;
	CProgressCtrlX	m_progressV;
	CProgressCtrlX	m_progressH;
	BOOL	m_fUseBrush;
	BOOL	m_fRubberBar;
	BOOL	m_fTiedText;
	int		m_nBorder;
	int		m_iProgressMode;
	UINT	m_nRange;
	int 	m_nStepSize;
	UINT	m_nTailSize;
	CString	m_sTextAngel;
	int		m_nAlign;
	int		m_nVAlign;
	BOOL	m_fUsePalette;
	BOOL	m_fShaped;
	BOOL	m_fSkipPalInBackgnd;
	int		m_nAnimStep;
	BOOL m_fToolTipSet;
	int	m_iToolTipTextMode;
	int	m_iTextMode;
	BOOL m_fAnimation;
	BOOL m_fRun;
	// ClassWizard generated virtual function overrides
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support

	void Run(BOOL fRun = TRUE);
// Implementation
	HICON m_hIcon;
	CFont m_fontV;
	CFont m_fontH;
	int m_pos;
	BOOL m_inc;
	CBrush m_brBk;
	CBrush m_brBar;

	// Generated message map functions
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg void OnButtonMssetup();
	afx_msg void OnButtonMulticolor();
	afx_msg void OnButtonNsSnake();
	afx_msg void OnCheckBrush();
	afx_msg void OnCheckRubberbar();
	afx_msg void OnCheckTiedtext();
	afx_msg void OnClrBk();
	afx_msg void OnClrEnd();
	afx_msg void OnClrStart();
	afx_msg void OnChangeEditBorder();
	afx_msg void OnRadioTextMode();
	afx_msg void OnRadioProgressMode();
	afx_msg void OnChangeRange();
	afx_msg void OnReset();
	afx_msg void OnReverse();
	afx_msg void OnRun();
	afx_msg void OnStep();
	afx_msg void OnChangeStepsize();
	afx_msg void OnChangeTail();
	afx_msg void OnClrTextBk();
	afx_msg void OnClrTextBar();
	afx_msg void OnButtonMulticolorCentered();
	afx_msg void OnButtonMySnake();
	afx_msg void OnEditchangeComboTextAngel();
	afx_msg void OnSelchangeComboTextAngel();
	afx_msg void OnRadioAlign();
	afx_msg BOOL OnQueryNewPalette();
	afx_msg void OnPaletteChanged(CWnd *pFocusWnd);
	afx_msg void OnCheckPalette();
	afx_msg void OnCheckSkipPalBkgnd();
	afx_msg void OnCheckShape();
	afx_msg void OnRadioText();
	afx_msg void OnRadioTooltip();
	afx_msg void OnBtnFont();
	afx_msg void OnAnimate();
	afx_msg void OnChangeAnimStep();
	afx_msg void OnButtonMsAnimated();
	afx_msg void OnButtonShapedAnimation();

// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_PROGRESSBARTESTDLG_H__476B90AA_6932_11D4_B261_00104BB13A66__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Yury Goltsman
Software Developer (Senior)
Israel Israel
Yury is Software Engineer since 1988.
His programming experience includes C#/VB.NET, WPF, C/C++(MFC/STL), Borland Delphi & C++ (VCL), JavaScript, HTML, CSS, XML, SQL, VB6, DirectX, Flash.
He has worked on PCs (DOS/Win3.1-Vista) and PocketPCs (WinCE).

Yury was born in Ukraine, but currently based in Jerusalem.

You may also be interested in...

Permalink | Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.171207.1 | Last Updated 12 Jun 2002
Article Copyright 2001 by Yury Goltsman
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid