1. window size

my problem is this:

        my screen is set 800x600
        i have opened a window (createwindow) with default
dimensions
(defined as CW_USEDEFAULT)
        GetClientRect reply : 0,0,80,116
        but the size in pixels is 590x370
        (think please that a window 80x116 would be large a tenth of the
screen and tall 1/6 of the screen, but it's not like this...)

        i cannot harmonize such differences...

        can u help me, please ?

        Thanks, Flaminio

new topic     » topic index » view message » categorize

2. Re: window size

On Mon, 6 Sep 1999 18:40:26 +0200, Flaminio <newpow at TIN.IT> wrote:

>my problem is this:
>
>        my screen is set 800x600
>        i have opened a window (createwindow) with default
>dimensions
>(defined as CW_USEDEFAULT)
>        GetClientRect reply : 0,0,80,116
>        but the size in pixels is 590x370


Flaminio
   You can use GetWindowRect to get window's size and see if that is
   same size ( - title and frame ) as client values.
   You can set coordinates in createwindow to a known values and compare
   to screen size ratio. Use GetClientRect and see what values it returns
   when you set values ( other than default )
   Make sure that MAP MODE is set to MM_TEXT set by SetMapMode function.
   MM_TEXT should be default value for PIXELS.
   CW_USEDEFAULT is ONLY VALID if the WINDOW STYLE is set to OVERLAPPED.

   Hope that this helps you
Bernie

new topic     » goto parent     » topic index » view message » categorize

3. Re: window size

>Flaminio wrote:

>my problem is this:

>my screen is set 800x600
>i have opened a window (createwindow)
>with default dimensions (defined as CW_USEDEFAULT)
>  GetClientRect reply : 0,0,80,116
>  but the size in pixels is 590x370
>(think please that a window 80x116 would
>be large a tenth of the
>screen and tall 1/6 of the screen, but it's not
>like this...)

>        i cannot harmonize such differences...

How did you get the pixel size of the window?

Terry

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu