Welcome! Log In Create A New Profile

Advanced

Windev with 4K Monitors

Posted by Michael Drechsel 
Windev with 4K Monitors
June 15, 2021 09:27AM
Hi,

sometimes users of my application telling me that the windows of my application are damaged if they choose >125 % zoom in the windows settings of the 4K Monitors. I use windev 22.

I am not sure which settings I should do to avoid this.

I use "Enlarge the window and controls" and "Multiplatform / Independent of dpi" in the windows settings.

Any hints ?

regards Michael
Re: Windev with 4K Monitors
June 15, 2021 10:12AM
Hi Michael,

I'm using the ..Zoom property on the MDI-parent. User is offered a spin control on the parent and thus is able to increase / decrease the magnification of the parent window - which magnifies all shown MDI childs as well. If you're using an SDI setup then things will maybe get a bit more complex. You'd have to apply the zoom value to each window after opening it.

Kind regards,
Guenter Predl
office@windev.at



Edited 1 time(s). Last edit at 06/15/2021 10:13AM by gpredl.
Attachments:
open | download - Ashampoo_Snap_Dienstag, 15. Juni 2021_10h05m33s_001_.png (34.4 KB)
Re: Windev with 4K Monitors
June 15, 2021 11:52AM
Hi Guenter,

interesting approach ..

And which settings do you use in the window template ? (See my settings)

regards Michael
Re: Windev with 4K Monitors
June 15, 2021 12:41PM
Hi, same as you do: "enlarge ..."

Kind regards,
Guenter Predl
office@windev.at
pao
Re: Windev with 4K Monitors
June 16, 2021 11:13AM
I'm using the ..zoom property and i'm using one event defined at project level to do several things when one windows opens.
With the event i don't need to replicate anything and even if someone forgets to use the templates or for some reason don't need to use it not a problem because the code runs anyway.

Regards

Paulo Oliveira
Re: Windev with 4K Monitors
June 16, 2021 04:47PM
HI Paulo,

interesting. Could you plz show us how you define the event ? Work this also in windev22 ?

regards Michael
pao
Re: Windev with 4K Monitors
June 16, 2021 05:33PM
It works in older versions of WINDEV. We use it since windev9 at least.

[doc.windev.com]

Just be carefull, it runs even with the INFO/ERROR windows

In the init code of the project just use something like this (copy&paste of some code of my app probably with errors):
G_ZOOM is int
Event("rotina_inicio_janela","*.",WM_CREATE)
Event("rotina_close_janela","*.",WM_CLOSE)

PROCEDURE rotina_inicio_janela()

IF MyWindow..Name IN ("Gaugewin7","WinDevGrapheAutoTable") THEN
RETURN
END

MyWindow..Title=G_CAB
//===============================================================================================================================

IF ParentObject(MyWindow)<>"" _AND_ {ParentObject(MyWindow), indWindow}..Zoom<>G_ZOOM _AND_ G_USER<>"" THEN
MyWindow..Zoom = {ParentObject(MyWindow), indWindow}..Zoom
ELSE
MyWindow..Zoom = G_ZOOM=0 ? 100 ELSE G_ZOOM
END



PROCEDURE rotina_close_janela()

// store the ZOOM select by the user
IF G_ZOOM<>MyWindow..Zoom _AND_ G_USER<>"" THEN
G_ZOOM = MyWindow..Zoom
JanelaPai is string = ParentObject(MyWindow)
WHILE JanelaPai<>""//Replica o zoom para todas as janelas pai
{JanelaPai, indWindow}..Zoom = G_ZOOM
JanelaPai = ParentObject(JanelaPai)
END
end

Regards

Paulo Oliveira
Re: Windev with 4K Monitors
June 16, 2021 06:06PM
Hi Paulo,

many thx.

regards Michael
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: