> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Rohit Gupta
> Sent: Monday, 12 June 2000 15:45
> To: Multiple recipients of list delphi
> Subject: RE: [DUG]: Screen Size
> 
> 
> Jason,
> 
> thanks for the effort.  From the help files, I knew I could do that.  
> My fault for not specifying the requirement.  I wish my app to run in 
> 1024X768.  The current temporary solution is that it refuses to run if 
> you are in say 800x600.  What I want to do is to change the 
> settings to 1024x768 run the program and on exit, change the 
> system backto what it was.
> 
> For this to work, 
> 
> 1.  I need to know the exact mode number to restore to.
> 2.  I need to know the current mode number so that I can figure out 
> things like font size and display frequency before flipping to 
> 1024x768... otherwise we could have sync problems.
> 
> And there is no GetDisplaysettings.  EnumDisplaySettings as you 
> know gives you all the settings but I cant find anyway to know what 
> the current setting is.  I can get a few of those fields from 
> GetSystemMetrics, but not all.

You can also get some from GetDeviceCaps, such as
    GetDeviceCaps( Canvas.Handle, HORZRES )
    GetDeviceCaps( Canvas.Handle, VERTRES )


---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz

Reply via email to