Board index » delphi » turbo Pascal 1.5 for windows + workshop question

turbo Pascal 1.5 for windows + workshop question

a) Workshop:
   I made a dialog box and i put 2 frames on it of different sizes.
   There both set to invisible. In my code I decide in an if-test which
   frame should become visible. Now I can't find anything in the
   help-files how to do this. Can some1 tell me how ?

b) I have this program in turbo pascal for windows where you can draw
   circles, lines, .... But this program is eating resources. When I
click
   the scrollbars a couple of times quickly, my system and GDI resources
   decrease very fast. I didn't write the program, but I'm looking for a
   resource tracker so I can see at which point the resources drop.
(e.g.
   do they drop when I draw something, are resources released when I
   remove  a drawing, etc...). I hope some1 understands what I'm trying
to
   say.

Hope to hear something,

%==============================================================%
% Geert Vermuyten                                              %
% email: Geert.Vermuy...@uia.ua.ac.be                          %
% tel/fax: 03/455.40.47                                        %
%--------------------------------------------------------------%
% Better to remain silent and be thought a fool, than to speak %
% out and remove all doubt.                                    %
%==============================================================%

 

Re:turbo Pascal 1.5 for windows + workshop question


a) I think a call to ShowWindow (I think that's the name of the function -
check in the reference manual under sw_xxxx constants) with sw_show, with
GetDlgItemHandle(yyy) as the window
handle, should do it.
b) I don't think resources are consumed by drawings in and of themselves.
More likely, the
   program is selecting resources (brushes, pens, etc) into a display
context, and not
   selecting them out.  Take a look at the code for drawing, as well as the
code for repainting
   the window.
Hope this helps
Rob

joan De Boeck <j...@innet.be> wrote in article
<32AE9113.6...@uia.ua.ac.be>...

Quote
> a) Workshop:
>    I made a dialog box and i put 2 frames on it of different sizes.
>    There both set to invisible. In my code I decide in an if-test which
>    frame should become visible. Now I can't find anything in the
>    help-files how to do this. Can some1 tell me how ?

> b) I have this program in turbo pascal for windows where you can draw
>    circles, lines, .... But this program is eating resources. When I
> click
>    the scrollbars a couple of times quickly, my system and GDI resources
>    decrease very fast. I didn't write the program, but I'm looking for a
>    resource tracker so I can see at which point the resources drop.
> (e.g.
>    do they drop when I draw something, are resources released when I
>    remove  a drawing, etc...). I hope some1 understands what I'm trying
> to
>    say.

> Hope to hear something,

> %==============================================================%
> % Geert Vermuyten                                              %
> % email: Geert.Vermuy...@uia.ua.ac.be                          %
> % tel/fax: 03/455.40.47                                        %
> %--------------------------------------------------------------%
> % Better to remain silent and be thought a fool, than to speak %
> % out and remove all doubt.                                    %
> %==============================================================%

Other Threads