Origin 0,0 (in)dependent from themes?

This forum is for eXpress++ general support.
Message
Author
daan_vossebeld
Posts: 11
Joined: Fri Jan 29, 2010 1:37 am

Re: Origin 0,0 (in)dependent from themes?

#11 Post by daan_vossebeld »

Roger,

Is it possible that you make en new update for this problem?

Daan

User avatar
rdonnay
Site Admin
Posts: 4729
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: Origin 0,0 (in)dependent from themes?

#12 Post by rdonnay »

I am struggling with this.

I don''t have a Vista computer so I am not sure about Vista.
I DO have a Windows 7 computer and I can see that the below code does not work on Win 7.

This is what is working good for me on Windows XP.

Code: Select all

::metrics := GetSystemMetrics(4) + ;  // Title bar Height
             GetSystemMetrics(8) + ;  // Border Height
             GetSystemMetrics(7) + ;  // Border Width
             IIF(::isMenu, GetSystemMetrics(15), 0 ) // Menu Height
The below code appears to work correctly on both Win 7 and XP:

Code: Select all

::metrics := GetSystemMetrics(4) + ;  // Title bar Height
             GetSystemMetrics(32)*2 + ; // Frame Width
             IIF(::isMenu, GetSystemMetrics(15), 0 ) // Menu Height
The eXpress train is coming - and it has more cars.

daan_vossebeld
Posts: 11
Joined: Fri Jan 29, 2010 1:37 am

Re: Origin 0,0 (in)dependent from themes?

#13 Post by daan_vossebeld »

Roger,

The first code gives wrong results for Vista with theme Windows Vista. No further tests done.

I have implemented the second code as follows (_dcgetbx.prg lines about 1674):

Code: Select all

            nStartRow := nParentHeight - nStartRow - ;
               GetSystemMetrics(4) - ;  // Title bar Height
               GetSystemMetrics(32)*2 - ; // Frame Width
               IIF(::isMenu, GetSystemMetrics(15), 0 ) - ; // Menu Height
               aOptions[nGETOPT_ROWOFFSET]
I tested on:
- Vista with themes Windows Vista and Windows Classic. Both tests are OK.
- XP with themes Windows XP and Windows Classic. Both tests are OK.

You tested on Windows-7 and that was OK. So I think the problem has been solved.
Thank you (and Jimmy) for the support.

User avatar
rdonnay
Site Admin
Posts: 4729
Joined: Wed Jan 27, 2010 6:58 pm
Location: Boise, Idaho USA
Contact:

Re: Origin 0,0 (in)dependent from themes?

#14 Post by rdonnay »

Ok, very good.

This fix will be in build 255.
The eXpress train is coming - and it has more cars.

Post Reply