🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #10908

Re: Dialog Boxes and child windows

#10908
From: Gary Setter
Date: Sat, 20 Mar 2004 21:48
35 lines
2519 bytes
"Mark Morrisson" <mark4@NO_SPAMvoila.fr> wrote in message
news:405c7e0d$1@newsgroups.borland.com...
> Hi Gary,
> I really don't know how to thank you for the time you've spent on my
> problem.

You pay by helping the next person :-)

<snip>
> Anyway, you'll perhaps be able to advise me. I'm using raw APIs. I have a
> window that has 3 screens with curves that will be drawn inside. To draw
> each curve, I need to know the top coordinate of the window (which is
> obtained by summing the height of several elements). If I ever had to add
> something between 2 screens, I would have to change all the drawing code !
> That's not a good coding style. So, I thought that it would be cleaner to
> create
> 3 independant windows instead of drawn rectangles. This way, each window
> would draw its own data, and there wouldn't be any need to know the y
> coordinate of these client areas. Is it a frequent way of solving such
> problems ?
>
> I hope I haven't explained too badly.
>
> Thanks again and have a very nice day,
> Mark
>
Based just on what you said, as long as most of what you need is available
to the individual 'window', I would make them paint themselves.

By the way, the child windows of a dialog are usually called controls. In
your case they are custom controls.

Glad to be of help,
Gary
Technical Details
Message-ID: <405cbc71@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshosting.com!nx02.iad01.newshosting.com!203.109.252.33.MISMATCH!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail
References: <405b3edd@newsgroups.borland.com> <405b4370$1@newsgroups.borland.com> <405b53f5$1@newsgroups.borland.com> <405c6892$1@newsgroups.borland.com> <405c7e0d$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,f7c94584fd5860a5
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2004-03-20 13:59:29 PST
From: "Gary Setter" <setterg@worldnet.att.net>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <405b3edd@newsgroups.borland.com> <405b4370$1@newsgroups.borland.com> <405b53f5$1@newsgroups.borland.com> <405c6892$1@newsgroups.borland.com> <405c7e0d$1@newsgroups.borland.com>
Subject: Re: Dialog Boxes and child windows
Date: Sat, 20 Mar 2004 15:48:14 -0600
Lines: 36
MIME-Version: 1.0
Content-Type: text/plain;
 charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
NNTP-Posting-Host: 12.74.20.121
Message-ID: <405cbc71@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1079819377 12.74.20.121 (20 Mar 2004 13:49:37 -0800)
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshosting.com!nx02.iad01.newshosting.com!203.109.252.33.MISMATCH!newsfeeds.ihug.co.nz!ihug.co.nz!newsgroups.borland.com!not-for-mail