Subject: | Re: Automatically resize forms and all their controls based on
| Date: | Wed, 27 May 2020 17:01:42 +0200
| From: | modridirkac <jure.zorko@gmail.com>
| Newsgroups: | pnews.paradox-development
|
Yup, been there, done that.
"init" of the form:
var f form
endVar
v = applib1.PreberiNastavitev("APP","Forms","Size","",false)
if v.isSpace() then
v = "640x480"
writeprofilestring(privdir()+"\\INI\\APP.INI","Forme","Size",v)
endIf
f.attach()
switch
case v = "1024x768" :
f.setPosition(0,0,13400,9220)
Page2.setPosition(0,0,13400,9220)
TF.size = Point(13080,7500)
case v = "800x600" :
f.setPosition(0,0,11720,7000)
Page2.setPosition(0,0,11720,7000)
TF.size = Point(11400,5250)
otherwise :
f.getPosition(x,y,w,h)
f.setPosition(x,y,w,h)
Page2.setPosition(0,0,9407,5880)
TF.size = Point(9433,4750)
endSwitch
Manually resize objects on form, to show more columns of table,...
Jure
On Wed, 27 May 2020 05:52:10 +0200, Kevin Zawicki <numberjack@wi.rr.com>
wrote:
>
> to add
>
>>
> Its not just the screen resolution you have to worry about, you may also
> need to consider the DPI as well and then apply a scaling factor.
> <
> and that the user may change on the fly...
>
>
> Also, ZOOM will magnify, but what some users mean is "more real estate".
>
> If a tableframe has x many rows and they get a nigger monitor /
> resolution,
> etc, they may want more than x rows.
>
> So you have to consider magnification is not more space.
>
>
>
>
>
>
> modridirkac <jure.zorko@gmail.com> wrote:
>> I use "built in" method.
>> It works on most computers. On some it does not work as I would like it
> to.
>>
>> So I use a global variable, which can be set on app level.
>>
>>
>> in "var" of form:
>> doZoom logical
>>
>> in "init" method:
>> ...
>> doZoom = true/false - read from INI or something
>> ...
>> doDefault
>> ...
>>
>>
>> in "setFocus" method of the form:
>> ...
>> doDefault
>> if doZoom then
>> menuAction(MenuPropertiesZoomBestFit)
>> else
>> menuAction(MenuPropertiesZoom100)
>> endIf
>> ...
>>
>>
>> Jure
>
--
Using Opera's mail client: http://www.opera.com/mail/
|