Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.clipper.visual-objects > #3192 > unrolled thread
| Started by | Ian <ithomson@mikroaid.co.uk> |
|---|---|
| First post | 2012-03-18 13:41 -0700 |
| Last post | 2012-03-20 13:33 -0700 |
| Articles | 6 — 4 participants |
Back to article view | Back to comp.lang.clipper.visual-objects
Window size and controls position Ian <ithomson@mikroaid.co.uk> - 2012-03-18 13:41 -0700
Re: Window size and controls position Mathias <mathias.hakansson@consultec.se> - 2012-03-19 23:25 -0700
Re: Window size and controls position "richard.townsendrose" <richard.townsendrose@gmail.com> - 2012-03-20 02:47 -0700
Re: Window size and controls position Ian <ithomson@mikroaid.co.uk> - 2012-03-20 06:32 -0700
Re: Window size and controls position "Jamal" <vodotnet_nospam@yahoo.com> - 2012-03-20 16:06 -0400
Re: Window size and controls position Ian <ithomson@mikroaid.co.uk> - 2012-03-20 13:33 -0700
| From | Ian <ithomson@mikroaid.co.uk> |
|---|---|
| Date | 2012-03-18 13:41 -0700 |
| Subject | Window size and controls position |
| Message-ID | <8c5b097f-374a-4305-a6fd-d47c8f240103@er9g2000vbb.googlegroups.com> |
Hi All, My app has been designed to fit a screen resolution of 1024*768. More of my customers are now using screen resolutionsof 1280*1024 or 1440*900. When my app runs the shell is shown zoomed and my other datawindows are set to a size of 1003*634 so they sit at the top left corner of the shell and fit perfectly on a screen resolution of 1024*768. Nearly all of the datawindows that show at this size contain either one or two tab controls each with a number of pages and one or two bBrowsers and of course there are pushbuttons radio buttons and so on. The tab controls also have bBrowsers and push buttons etc on them. What I would like to do is to get the shell to open to suit the size of the clients screen and then get my other datawindows to open up to fit the size of the shell rather than their current fixed size of 1003*634. I would need the tab controls and bBrowsers on the datawindow to resize accordingly and although I do not need to resize the other controls I would like them to reposition themselves to suit the new datawindow size. As these datawindows contain tab controls that would be resized, the bBrowsers on those tab pages would need to resize and the other controls need to reporition themselves to suit the tab pages new size. All of the windows and tab pages have groupboxes on them so they would need to resize as well. There are many other data entry and data look up dialog windows in the app but these do not need to resize. I only need this to work with the datawindows not the datadialog windows Could anyone point me in the right direction with this and tell me if there is any code available that I can drop into my app to cover this subject. Customers are asking why the app does not fill their screens. Regardss, Ian
[toc] | [next] | [standalone]
| From | Mathias <mathias.hakansson@consultec.se> |
|---|---|
| Date | 2012-03-19 23:25 -0700 |
| Message-ID | <30579028.3923.1332224745011.JavaMail.geo-discussion-forums@vbbfy7> |
| In reply to | #3192 |
Hi Ian, There is a setting called Owner alignment in the window editor. With this setting you can decide what should happen with the control when the window it resides in changes it's size. Search for "owneralignment" in the VO help file and learn the basics. You should also make a plan for your windows for which controls that should adjust it's size and which should move and which should stay where they are. I find it a little bit difficult myself to figure out exactly which setting each control should have, so I usually take a channce on the most probable and then test different settings a few times until I get it right. /Mathias Den söndagen den 18:e mars 2012 kl. 21:41:55 UTC+1 skrev Ian: > Hi All, > > My app has been designed to fit a screen resolution of 1024*768. More > of my customers are now using screen resolutionsof 1280*1024 or > 1440*900. > > When my app runs the shell is shown zoomed and my other datawindows > are set to a size of 1003*634 so they sit at the top left corner of > the shell and fit perfectly on a screen resolution of 1024*768. > > Nearly all of the datawindows that show at this size contain either > one or two tab controls each with a number of pages and one or two > bBrowsers and of course there are pushbuttons radio buttons and so on. > The tab controls also have bBrowsers and push buttons etc on them. > > What I would like to do is to get the shell to open to suit the size > of the clients screen and then get my other datawindows to open up to > fit the size of the shell rather than their current fixed size of > 1003*634. > > I would need the tab controls and bBrowsers on the datawindow to > resize accordingly and although I do not need to resize the other > controls I would like them to reposition themselves to suit the new > datawindow size. As these datawindows contain tab controls that would > be resized, the bBrowsers on those tab pages would need to resize and > the other controls need to reporition themselves to suit the tab pages > new size. > > All of the windows and tab pages have groupboxes on them so they would > need to resize as well. > > There are many other data entry and data look up dialog windows in the > app but these do not need to resize. I only need this to work with the > datawindows not the datadialog windows > > Could anyone point me in the right direction with this and tell me if > there is any code available that I can drop into my app to cover this > subject. Customers are asking why the app does not fill their screens. > > Regardss, > Ian
[toc] | [prev] | [next] | [standalone]
| From | "richard.townsendrose" <richard.townsendrose@gmail.com> |
|---|---|
| Date | 2012-03-20 02:47 -0700 |
| Message-ID | <b4f16cab-626a-4484-bc80-7876b67b1a20@l7g2000vbw.googlegroups.com> |
| In reply to | #3213 |
Ian What I found when i got a new large screen is that i want the app to remain the size it was designed for ... in the old days it was common to use full screen ... so now i make my apps to fill an old screen.... but that means keeping the position and size odf the app when it last closed ... you will notice that vo itself does this [save desktop]. it is easy .. then you dont need to redesign a layout that is already comfortable for the user here is a sample for saving .. METHOD SaveScreenSizePos CLASS TDOCShellWindow LOCAL lpRect IS _winRECT LOCAL wTop, wLeft AS INT SysObject():PutSet(ScrWidth, NTrim(SysObject():Size:Width)) // rgtr 150311 SysObject():PutSet(ScrHeight, NTrim(SysObject():Size:Height)) GetWindowRect(SysObject():Handle(), @lpRect) wTop:=Max(lpRect.top, 0) wLeft:=Max(lpRect.Left,0) SysObject():PutSet(ScrTop, NTrim(wTop)) SysObject():PutSet(ScrLeft, NTrim(wLeft)) RETURN NIL and here's the loading SetWindowPos(oMain:Handle(), NULL_PTR, Val(oMain:GetSet(ScrLeft)), Val(oMain:GetSet(ScrTop)), ; Val(oMain:GetSet(ScrWidth)), Val(oMain:GetSet(ScrHeight)), SWP_SHOWWINDOW) you will need to have yopur own storage mechanism .. we use an ini file ... richard
[toc] | [prev] | [next] | [standalone]
| From | Ian <ithomson@mikroaid.co.uk> |
|---|---|
| Date | 2012-03-20 06:32 -0700 |
| Message-ID | <f84225de-188d-40d0-8369-51687a605d90@w5g2000vbv.googlegroups.com> |
| In reply to | #3217 |
On Mar 20, 9:47 am, "richard.townsendrose" <richard.townsendr...@gmail.com> wrote: > Ian > > What I found when i got a new large screen is that i want the app to > remain the size it was designed for ... in the old days it was common > to use full screen ... > > so now i make my apps to fill an old screen.... but that means keeping > the position and size odf the app when it last closed ... you will > notice that vo itself does this [save desktop]. > > it is easy .. then you dont need to redesign a layout that is already > comfortable for the user > > here is a sample for saving .. > METHOD SaveScreenSizePos CLASS TDOCShellWindow > LOCAL lpRect IS _winRECT > LOCAL wTop, wLeft AS INT > > SysObject():PutSet(ScrWidth, > NTrim(SysObject():Size:Width)) // rgtr 150311 > SysObject():PutSet(ScrHeight, NTrim(SysObject():Size:Height)) > > GetWindowRect(SysObject():Handle(), @lpRect) > wTop:=Max(lpRect.top, 0) > wLeft:=Max(lpRect.Left,0) > SysObject():PutSet(ScrTop, NTrim(wTop)) > SysObject():PutSet(ScrLeft, NTrim(wLeft)) > > RETURN NIL > > and here's the loading > > SetWindowPos(oMain:Handle(), NULL_PTR, Val(oMain:GetSet(ScrLeft)), > Val(oMain:GetSet(ScrTop)), ; > Val(oMain:GetSet(ScrWidth)), > Val(oMain:GetSet(ScrHeight)), SWP_SHOWWINDOW) > > you will need to have yopur own storage mechanism .. we use an ini > file ... > > richard Hi, Thanks for the replies. Understand what you are saying Richard but I would like to have my app data windows open as zoomed and have the controls etc resize and reposition themselves to suit. I think I will look at owneralignmet as suggested by Mathias. I have already had a quick look at this using the setting OA_PX_PY_PWIDTH_PHEIGHT, which seems to do the job I need although it does seem to struggle with bBrowsers and I have to click off then back onto a tab page for the browser to show correctly. Will continue with this and see if I can get it to do what I want. Only have 26 datawindows to sort, all of the dialog windows will stay as they are. Thanks for the help. Ian
[toc] | [prev] | [next] | [standalone]
| From | "Jamal" <vodotnet_nospam@yahoo.com> |
|---|---|
| Date | 2012-03-20 16:06 -0400 |
| Message-ID | <jkanva$v3i$1@dont-email.me> |
| In reply to | #3220 |
>> although it does seem to struggle with bBrowsers and I have to click off then back onto a tab page for the browser to show correctly. << Use bBrowser:Repaint() and bBrowser:Recalculate() Jamal "Ian" wrote in message news:f84225de-188d-40d0-8369-51687a605d90@w5g2000vbv.googlegroups.com... On Mar 20, 9:47 am, "richard.townsendrose" <richard.townsendr...@gmail.com> wrote: > Ian > > What I found when i got a new large screen is that i want the app to > remain the size it was designed for ... in the old days it was common > to use full screen ... > > so now i make my apps to fill an old screen.... but that means keeping > the position and size odf the app when it last closed ... you will > notice that vo itself does this [save desktop]. > > it is easy .. then you dont need to redesign a layout that is already > comfortable for the user > > here is a sample for saving .. > METHOD SaveScreenSizePos CLASS TDOCShellWindow > LOCAL lpRect IS _winRECT > LOCAL wTop, wLeft AS INT > > SysObject():PutSet(ScrWidth, > NTrim(SysObject():Size:Width)) // rgtr 150311 > SysObject():PutSet(ScrHeight, NTrim(SysObject():Size:Height)) > > GetWindowRect(SysObject():Handle(), @lpRect) > wTop:=Max(lpRect.top, 0) > wLeft:=Max(lpRect.Left,0) > SysObject():PutSet(ScrTop, NTrim(wTop)) > SysObject():PutSet(ScrLeft, NTrim(wLeft)) > > RETURN NIL > > and here's the loading > > SetWindowPos(oMain:Handle(), NULL_PTR, Val(oMain:GetSet(ScrLeft)), > Val(oMain:GetSet(ScrTop)), ; > Val(oMain:GetSet(ScrWidth)), > Val(oMain:GetSet(ScrHeight)), SWP_SHOWWINDOW) > > you will need to have yopur own storage mechanism .. we use an ini > file ... > > richard Hi, Thanks for the replies. Understand what you are saying Richard but I would like to have my app data windows open as zoomed and have the controls etc resize and reposition themselves to suit. I think I will look at owneralignmet as suggested by Mathias. I have already had a quick look at this using the setting OA_PX_PY_PWIDTH_PHEIGHT, which seems to do the job I need although it does seem to struggle with bBrowsers and I have to click off then back onto a tab page for the browser to show correctly. Will continue with this and see if I can get it to do what I want. Only have 26 datawindows to sort, all of the dialog windows will stay as they are. Thanks for the help. Ian
[toc] | [prev] | [next] | [standalone]
| From | Ian <ithomson@mikroaid.co.uk> |
|---|---|
| Date | 2012-03-20 13:33 -0700 |
| Message-ID | <2b9e2e19-c10a-4fda-a28b-1f9394dc5d0b@k6g2000vbz.googlegroups.com> |
| In reply to | #3224 |
On Mar 20, 8:06 pm, "Jamal" <vodotnet_nos...@yahoo.com> wrote: > >> although it does seem to struggle with > > bBrowsers and I have to click off then back onto a tab page for the > browser to show correctly. << > > Use bBrowser:Repaint() and bBrowser:Recalculate() > > Jamal > > "Ian" wrote in message > > news:f84225de-188d-40d0-8369-51687a605d90@w5g2000vbv.googlegroups.com... > > On Mar 20, 9:47 am, "richard.townsendrose" > > > > > > <richard.townsendr...@gmail.com> wrote: > > Ian > > > What I found when i got a new large screen is that i want the app to > > remain the size it was designed for ... in the old days it was common > > to use full screen ... > > > so now i make my apps to fill an old screen.... but that means keeping > > the position and size odf the app when it last closed ... you will > > notice that vo itself does this [save desktop]. > > > it is easy .. then you dont need to redesign a layout that is already > > comfortable for the user > > > here is a sample for saving .. > > METHOD SaveScreenSizePos CLASS TDOCShellWindow > > LOCAL lpRect IS _winRECT > > LOCAL wTop, wLeft AS INT > > > SysObject():PutSet(ScrWidth, > > NTrim(SysObject():Size:Width)) // rgtr 150311 > > SysObject():PutSet(ScrHeight, NTrim(SysObject():Size:Height)) > > > GetWindowRect(SysObject():Handle(), @lpRect) > > wTop:=Max(lpRect.top, 0) > > wLeft:=Max(lpRect.Left,0) > > SysObject():PutSet(ScrTop, NTrim(wTop)) > > SysObject():PutSet(ScrLeft, NTrim(wLeft)) > > > RETURN NIL > > > and here's the loading > > > SetWindowPos(oMain:Handle(), NULL_PTR, Val(oMain:GetSet(ScrLeft)), > > Val(oMain:GetSet(ScrTop)), ; > > Val(oMain:GetSet(ScrWidth)), > > Val(oMain:GetSet(ScrHeight)), SWP_SHOWWINDOW) > > > you will need to have yopur own storage mechanism .. we use an ini > > file ... > > > richard > > Hi, > > Thanks for the replies. Understand what you are saying Richard but I > would like to have my app data windows open as zoomed and have the > controls etc resize and reposition themselves to suit. I think I will > look at owneralignmet as suggested by Mathias. I have already had a > quick look at this using the setting OA_PX_PY_PWIDTH_PHEIGHT, which > seems to do the job I need although it does seem to struggle with > bBrowsers and I have to click off then back onto a tab page for the > browser to show correctly. > > Will continue with this and see if I can get it to do what I want. > Only have 26 datawindows to sort, all of the dialog windows will stay > as they are. > > Thanks for the help. > > Ian Hi Jamal Away on business for a few days so will try the repaint() recalculate() when I get back. Many Thanks Ian
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.clipper.visual-objects
csiph-web