dcgetoptions ... SCALEFACTOR and TABpages
dcgetoptions ... SCALEFACTOR and TABpages
Hi Roger,
I'm testing with the autoscale option of the dcgetoptions.
I get the following on tabpages with a factor 1.2. It looks as the factor is executed on each tab, the font is 'growing'.
I'm testing with the autoscale option of the dcgetoptions.
I get the following on tabpages with a factor 1.2. It looks as the factor is executed on each tab, the font is 'growing'.
Re: dcgetoptions ... SCALEFACTOR and TABpages
Hi,
I'm using the following scalefactor:
SCALEFACTOR { 1.2,1.2,1.2,1.2,.t.,.f.}
I'm using the following scalefactor:
SCALEFACTOR { 1.2,1.2,1.2,1.2,.t.,.f.}
Re: dcgetoptions ... SCALEFACTOR and TABpages
I haven't seen this before. The sample in ..\samples\scale\scale.prg looks fine.
Can you send me your sample?
Can you send me your sample?
The eXpress train is coming - and it has more cars.
Re: dcgetoptions ... SCALEFACTOR and TABpages
Roger,
I was checking the sample SCALE.PRG and there the tabpages are ok. I don't see why this isn't working in my dialog. I don't see any difference in the getoptions.
I was checking the sample SCALE.PRG and there the tabpages are ok. I don't see why this isn't working in my dialog. I don't see any difference in the getoptions.
Code: Select all
DCGETOPTIONS WINDOWHEIGHT 580 ;
WINDOWWIDTH 780 ;
SAYWIDTH 130 ;
SAYOPTIONS XBPSTATIC_TEXT_BOTTOM ;
SAYFONT amain(9,6) ;
GETFONT amain(9,7) ;
FONT amain(9,6) ;
TABSTOP ;
HILITEGETS GRA_CLR_YELLOW ;
CLOSEQUERY MSG {||DC_MsgBox(,,{'Stoppen ? / Arreter ?'},"Klanten / Clients" ,,,.t.,1,,,,,'10.Arial.bold')} ;
EVAL {|o|SetAppWindow(o)} ;
TOOLTIPCOLOR GRA_CLR_BLACK, GRA_CLR_YELLOW ;
HILITEGETS GRA_CLR_RED NOSUPERVISE AUTORESIZE ;
SCALEFACTOR { 1.5,1.5,1.5,1.5,.t.,.f.}
Re: dcgetoptions ... SCALEFACTOR and TABpages
I haven't seen something like this before either. And I do use the SCALEFACTOR intensively. It looks like there is a font object (re)used.
By the way: Scaling the app is a user option in our applications. If this is set, there is only one factor calculated. Since the app layout is based on 1024 x 768, the factor is calculated using DC_GetWorkArea(). If the width is higher than 1024, like 1400, the width factor would be 1.37. If the height is only 900, which creates the factor 1.17, this factor is used (first 4 parameters) - and vice versa. This creates a perfectly scaled app, while setting different factors for width and height may create something really ugly.
The scalefactor is set only once, using DC_GetOptDefault().
Some dialogs can't be scaled, since they always try to use the full work-/screenarea - and show more data if the resolution is bigger. Only in those dialogs the SCALEFACTOR clause is used directly - with 1,1,1,1. If scaling is active anyway, they use bigger fonts.
Besides, we also support negative scaling. Some of our users run around with "Netbooks" (did they have the same name in the U.S.?). Those devices come with resolutions like 900 x 500. It looks interesting, but it works.
By the way: Scaling the app is a user option in our applications. If this is set, there is only one factor calculated. Since the app layout is based on 1024 x 768, the factor is calculated using DC_GetWorkArea(). If the width is higher than 1024, like 1400, the width factor would be 1.37. If the height is only 900, which creates the factor 1.17, this factor is used (first 4 parameters) - and vice versa. This creates a perfectly scaled app, while setting different factors for width and height may create something really ugly.
The scalefactor is set only once, using DC_GetOptDefault().
Some dialogs can't be scaled, since they always try to use the full work-/screenarea - and show more data if the resolution is bigger. Only in those dialogs the SCALEFACTOR clause is used directly - with 1,1,1,1. If scaling is active anyway, they use bigger fonts.
Besides, we also support negative scaling. Some of our users run around with "Netbooks" (did they have the same name in the U.S.?). Those devices come with resolutions like 900 x 500. It looks interesting, but it works.
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: dcgetoptions ... SCALEFACTOR and TABpages
Chris -
you should show how your tabs are created. The options are correct.
(Bullshit erased.)
you should show how your tabs are created. The options are correct.
(Bullshit erased.)
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Re: dcgetoptions ... SCALEFACTOR and TABpages
Hi Tom,
This was exactly what I wanted to implement. Checking for the screen size, and if the user wants rescaling using the default getoption.
This looks as a good solution. I see some strange things happening in my application.
- Tabpages with growing font.
- Height of dialog is not always correct, it looks as this is a bit too small. Some buttons just comes too low on the screen, where everything is perfect with factor 1.
- Strange messagebox height.
- A lot of white space on top of some dialogs.
- Browses aren't scaled?
I stopped my experiment, but since you are using it the same way, I will check this again. If it is working in your application, I don't see any reason why it shouldn't in mine.
I don't know how they call the netbooks in the US, but in Belgium it are also netbooks. Negative scaling could also be interesting for the Microsoft Surface.
This was exactly what I wanted to implement. Checking for the screen size, and if the user wants rescaling using the default getoption.
This looks as a good solution. I see some strange things happening in my application.
- Tabpages with growing font.
- Height of dialog is not always correct, it looks as this is a bit too small. Some buttons just comes too low on the screen, where everything is perfect with factor 1.
- Strange messagebox height.
- A lot of white space on top of some dialogs.
- Browses aren't scaled?
I stopped my experiment, but since you are using it the same way, I will check this again. If it is working in your application, I don't see any reason why it shouldn't in mine.
I don't know how they call the netbooks in the US, but in Belgium it are also netbooks. Negative scaling could also be interesting for the Microsoft Surface.
Re: dcgetoptions ... SCALEFACTOR and TABpages
Hi Tom,
here it is:
Nothing special at all in my opinion. I already added TABWIDTH and ANGLE to the SCALE.PRG sample. That was the main difference, but there it still works.
here it is:
Code: Select all
// TABPAGE 1 //
@ 0.1,0.1 DCTABPAGE aTabPages[1] TABWIDTH 17 CAPTION "~1. "+fMessage(2100) ;
SIZE 92 , 18 ACCELKEY xbeK_ALT_1 FONT amain(9,5) ;
GOTFOCUS {|a,b,oTab| oTab:tofront(), BuildGets(aTabPages,1,GetList,aBuildGets,aApp,oDialog) } ;
PARENT oDlg ANGLE 20 color amain(15,13)
// TABPAGE 2 //
@ 0,0 DCTABPAGE aTabPages[2] CAPTION "~2. "+fMessage(2200) ;
relative aTabPages[1] ACCELKEY xbeK_ALT_2 ;
GOTFOCUS {|a,b,oTab| oTab:tofront(), BuildGets(aTabpages,2,GetList,aBuildgets,aApp,oDialog) } ;
PARENT oDlg when {|| frights("ABCDFH") } color amain(15,13)
// TABPAGE 3 //
@ 0,0 DCTABPAGE aTabPages[3] CAPTION "~3. "+fMessage(2300) ;
relative aTabPages[2] ACCELKEY xbeK_ALT_3 ;
GOTFOCUS {|a,b,oTab| oTab:tofront(), BuildGets(aTabpages,3,GetList,aBuildgets,aApp,oDialog) } ;
PARENT oDlg when {|| frights("ABCDFH") } color amain(15,13)
Re: dcgetoptions ... SCALEFACTOR and TABpages
Chris -
If you can give me your full application, I can probably help you with this.
Roger
If you can give me your full application, I can probably help you with this.
Roger
The eXpress train is coming - and it has more cars.
Re: dcgetoptions ... SCALEFACTOR and TABpages
I assume the problem sits inside "BuildGets". You are merging getlists there, right?
Best regards,
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."
Tom
"Did I offend you?"
"No."
"Okay, give me a second chance."