Click here to Skip to main content
15,893,190 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Files and folders Pin
Michael Dunn2-Nov-03 20:04
sitebuilderMichael Dunn2-Nov-03 20:04 
Generaladding a cbutton to a custom control Pin
mindows2-Nov-03 17:11
mindows2-Nov-03 17:11 
GeneralRe: adding a cbutton to a custom control Pin
Antti Keskinen2-Nov-03 23:03
Antti Keskinen2-Nov-03 23:03 
GeneralRe: adding a cbutton to a custom control Pin
mindows3-Nov-03 11:54
mindows3-Nov-03 11:54 
GeneralRe: adding a cbutton to a custom control Pin
Antti Keskinen5-Nov-03 1:44
Antti Keskinen5-Nov-03 1:44 
QuestionHow to manage objects unknown at run-time Pin
Steve Messer2-Nov-03 16:42
Steve Messer2-Nov-03 16:42 
AnswerRe: How to manage objects unknown at run-time Pin
Christian Graus2-Nov-03 17:08
protectorChristian Graus2-Nov-03 17:08 
GeneralRe: How to manage objects unknown at run-time Pin
Steve Messer2-Nov-03 21:26
Steve Messer2-Nov-03 21:26 
Christian,

I used the term control rather loosely. There is no base class for my controls.
They are just visual representations. The buttons are either bitamps or a
roundedrect for which I create a region for hit testing. So, they are not based
on any real control or window.

Actually I have looked at all of your GDI+ articles so thanks for writing them.

So, your saying keep a list of each kind of objects for example.

1) CLabel
2) CTextButton
3) CBitmapButton

If I create 3 CTextButton's

CTextButton* pTextBtn1 = new CTextButton; // arguments not shown for simplicity
CTextButton* pTextBtn2 = new CTextButton;
CTextButton* pTextBtn3 = new CTextButton;

I don't understand how to create a dynamic list of CTextButton's for looping thru.
Sorry for being so dense.


PS: As a side question how do you determine the length of text that you have drawn?
I am trying to draw some text (ie Friday, November 3, 2003 10:59 PM ) then find the
bounding rect for it so that I can invalid the rect for smooth updating. Since font
type is user configurable the size of the bounding box varies. I know how to find
the height of a font but I have not figured out how to find the width.
GeneralRe: How to manage objects unknown at run-time Pin
Christian Graus3-Nov-03 9:07
protectorChristian Graus3-Nov-03 9:07 
GeneralRe: How to manage objects unknown at run-time Pin
Steve Messer3-Nov-03 10:23
Steve Messer3-Nov-03 10:23 
GeneralRe: How to manage objects unknown at run-time Pin
Steve S3-Nov-03 23:02
Steve S3-Nov-03 23:02 
GeneralFloat window in MDI application Pin
novachen2-Nov-03 16:35
novachen2-Nov-03 16:35 
QuestionHow can I put my window under any other application window? Pin
golden06062-Nov-03 16:24
golden06062-Nov-03 16:24 
GeneralText in the taskbar vs. title bar Pin
Vancouver2-Nov-03 15:21
Vancouver2-Nov-03 15:21 
GeneralFoundation Problem, #include Problem Pin
Mehran Ziadloo2-Nov-03 15:12
Mehran Ziadloo2-Nov-03 15:12 
GeneralRe: Foundation Problem, #include Problem Pin
ZoogieZork2-Nov-03 15:21
ZoogieZork2-Nov-03 15:21 
GeneralRe: Foundation Problem, #include Problem Pin
Christian Graus2-Nov-03 15:22
protectorChristian Graus2-Nov-03 15:22 
GeneralProblem with CAsyncSocket Pin
Daniel13242-Nov-03 14:30
Daniel13242-Nov-03 14:30 
GeneralHelp with file management... Pin
Snyp2-Nov-03 14:18
Snyp2-Nov-03 14:18 
GeneralRe: Help with file management... Pin
Ravi Bhavnani2-Nov-03 15:03
professionalRavi Bhavnani2-Nov-03 15:03 
GeneralRe: Help with file management... Pin
Christian Graus2-Nov-03 15:21
protectorChristian Graus2-Nov-03 15:21 
GeneralPlease help me Pin
golden06062-Nov-03 14:03
golden06062-Nov-03 14:03 
GeneralRe: Please help me Pin
Christian Graus2-Nov-03 15:24
protectorChristian Graus2-Nov-03 15:24 
GeneralRe: Please help me Pin
golden06062-Nov-03 15:42
golden06062-Nov-03 15:42 
GeneralRe: Please help me Pin
Christian Graus2-Nov-03 15:44
protectorChristian Graus2-Nov-03 15:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.