[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Is there no text for CProgressCtrl?

Posted on 1998-03-22
3
Medium Priority
?
823 Views
Last Modified: 2013-11-19
Some documents tell us text of CProgressCtrl.
In the on-line Help, I saw it.
In default processing message, there are WM_GETFONT and WM_SETFONT.
In class library reference, too.
In the first, there is a text below.
"...display, if any, the text..."

How can I display, if any, the text?

Please give me help!
0
Comment
Question by:hotheart
  • 2
3 Comments
 
LVL 10

Accepted Solution

by:
RONSLOW earned 0 total points
ID: 1317138
A windows common control progress bar does not display any text.

GetFont and setfont are message that all windows may receive, so the progress bar has to do something sensible with them (BTW: MFC class library doesn't have getfont and setfont).

If you want text on a progress bar, you'll have to draw it yourself by either owner-drawing the progress bar (have to do all the work yourself) or drawing the text over the progress bar (probably in xor mode).

0
 

Author Comment

by:hotheart
ID: 1317139
Of course, I can't display any text.

But On Help, There is a title "Default progress bar message processing".
In other section there is a "Default ... message processing".
Slider control has no WM_GETFONT and WM_SETFONT.

So I think I can display text on "blue block".
Thank for your answer!

0
 
LVL 10

Expert Comment

by:RONSLOW
ID: 1317140
That appears to be a documentation error.

The progress control will process these messages (otherwise you'd have to), and if you owner draw the control and try to output text, then I would say that the font you set with WM_SETFONT would be the one that would be used.

But if you let the control draw itself, then you won't get any text.

0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
Ready to get certified? Check out some courses that help you prepare for third-party exams.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
When cloud platforms entered the scene, users and companies jumped on board to take advantage of the many benefits, like the ability to work and connect with company information from various locations. What many didn't foresee was the increased risk…

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question