Resource Dialogs change with PC's

Resource Dialogs change with PC's

Postby byron.hopp » Mon Apr 28, 2014 2:55 am

All,

I have seen this problem depending on which workstation I work on. I can't figure out how to fix. Anybody know, I am using borland workshop (old).
I would love to post a picture of the two screens, but I can't figure out to do that as well. But in general the controls on the dialog seemed bunched together on the bad one.


Thanks,

Byron
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 355
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: Resource Dialogs change with PC's

Postby Antonio Linares » Mon Apr 28, 2014 5:29 pm

Byron,

Do those computers use different screen resolutions ?

If yes, and it has to be that way, then you may have two different dialogs (in size) and select the right one based on the used screen resolution.

If this is not the case, please post some screen shots, thanks :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41365
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Resource Dialogs change with PC's

Postby byron.hopp » Mon Apr 28, 2014 6:02 pm

Thanks for the response. I have noticed that it seems to be more than the screen resolution because when on a workstation which it works correctly, I change the screen resolution and it changes size, but not the aspect retio or the placement. But on one that looks wrong it seems always to be wrong regardless of the screen resolution.

I will check more and report back. Do most people need to check the resolution and have many dialog for each, or is it the aspect ratio and dialog s for each one that deffers.
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 355
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: Resource Dialogs change with PC's

Postby Jeff Barnes » Tue Apr 29, 2014 2:46 pm

Could also be an issue with the size of text:

Right click on your desktop, select "Screen Resolution"
Click on "Make text and other items larger or smaller"
You will have three options:
-Smaller - 100% (default)
-Medium - 125%
-Larger - 150%

Take a look at your "working" system and compare to the systems giving you problems.
Thanks,
Jeff Barnes

(FWH 16.11, xHarbour 1.2.3, Bcc730)
User avatar
Jeff Barnes
 
Posts: 929
Joined: Sun Oct 09, 2005 1:05 pm
Location: Ontario, Canada

Re: Resource Dialogs change with PC's

Postby ShumingWang » Wed Apr 30, 2014 3:02 am

dialog.prg

+ METHOD Autoresize(ntop,nleft,res)
METHOD Autoresize(ntop,nleft,res)
local i,rsl0,rsl1,oCtrol,aRect
DEFAULT ntop:=0
DEFAULT nleft:=0

if res==nil; res:=800; end

rsl0:=getsysmetrics(0)/res //width,col

if rsl0==1; return ; end //<=800*600, not needed
rsl1:=getsysmetrics(1)/if(res==800,600,768) // height ,nrow
for i:=1 TO LEN(::acontrols)
oCtrol = ::aControls[i] // top:nrow, left:ncol,bottom: nrow, right:ncol
aRect = GetCoors( oCtrol:hWnd )
do case
case oCtrol:classname()=="TCOMBOBOX"
oCtrol:Move( aRect[1]*rsl1, aRect[2]*rsl0)
otherwise
oCtrol:Move( aRect[1]*rsl1, aRect[2]*rsl0,(aRect[4] - aRect[2])*rsl0, (aRect[3] - aRect[1])*rsl1, .t. )
// ntop,nleft,nbottom,nright
end case
next

// aRect = GetWndRect( ::hWnd )

::Move( ntop,nleft,::nWidth*rsl0, ::nHeight*rsl1, .T. )


if ::lCentered
WndCenter( ::hWnd )
else
if Empty( ::cResName )
::Move( ::nTop, ::nLeft )
endif
endif


return


in prg:

ACTIVATE DIALOG odlg
ON INIT (odlg:autoresize())
http://www.xtech2.top
Mobile:(86)13802729058
Email:100200651@qq.com
QQ:100200651
Weixin: qq100200651
ShumingWang
 
Posts: 460
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China

Re: Resource Dialogs change with PC's

Postby byron.hopp » Sun May 04, 2014 9:39 pm

My dialog seems to have all of the controls fit nicely on the left 70% of the screen. This varies depending on the setting of the Display under to controlPanel. If I set it to 125% Screen looks great, same as it looks in the Resource Workshop. If I set it to 100% there is some plain space on the right side, but it looks great in resource workshop. If I set it to 150% it looks like there is plain space on the right side, all controls seem to fit into the left 70% of the screen however it looks great on resource workshop. If you had to make several versions of the dialog to use the correct one then how would you ever get it right, because you never see the problem in Resource Workshop.

My screen resolution is 1900 x 1200. But if the display is set to 125% it looks fine. How do the big boys do this, this is obviously out of my league. Does everybody who sells software in fivewin have to tell your customers they have to have a special setting on the monitor to get it to look right?

I will gladly e-mail screen shots if you provide me an address.

Thanks,

bhopp@matrixcomputer.com
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 355
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA

Re: Resource Dialogs change with PC's

Postby byron.hopp » Sun May 04, 2014 11:37 pm

My fault, (dumb as a box of rocks) comes to mind. I have to admit it. I was saving the coords of the dialog in the ini, because it was my main window. This app has no mdi shell (like most of my apps). so by switching between modes, but using the same values it caused this problem. Now I just save the Top, Left and let it do the rest. Everything is fine. Sorry to waste your time, but thanks everybody for the help.

Thanks,

Byron ..
Thanks,
Byron Hopp
Matrix Computer Services
byron.hopp
 
Posts: 355
Joined: Sun Nov 06, 2005 3:55 pm
Location: Southern California, USA


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 19 guests