Screen overrun
-
I am porting an application from a Linux SUSE system to a Raspberry Pi application running Wayland. When I run the Raspberry Pi application I get screen overrun and I cannot adjust the screen resolution to compensate for it. I have the same issue when I run it on Mac iOs.
I have tried setting the screen when the application opens to no avail. It is fine on Windows and SUSE. The latter are running an older version 5 of QT Creator. I am running version 6 on the others. -
Hi,
What do you mean by overrun ? Your application is bigger than the screen ?
-
Are you setting any fixed size on your application ?
Which window manager are you using on the various devices ? -
Are you setting any fixed size on your application ?
Which window manager are you using on the various devices ? -
Are other applications behaving in a similar fashion ?
-
Is KDE also having this issue ?
Which version of Qt are you using ?
How did you install it ? -
Is KDE also having this issue ?
Which version of Qt are you using ?
How did you install it ?@SGaist KDE is not having the issue, I am running QT Creator version 9.02 on The newest version of Raspbien. Creator draws ok itself, it is when I run full screen applications created with QT that I have an issue. Windowed applications are fine. As I said before, even full screen the upper left corner is correct.
-
It sounds like your issue is related to scaled display settings. The system may apply display scaling to make text and UI elements larger and more readable. However, this also means that the physical size of the application window becomes larger than its logical size, potentially causing screen overrun.
To handle this, you need to adjust your UI layout based on the display scale factor.
-
@SGaist No I'm not fixing a size other that what is generated by the ui. I'm moving the appllication from SUSE to a Rasbien system running KDE on both.
@dencla
On Yocto weston, these envs are needed to run qt apps. You may need them as well. Try these out in your main() and see if they help.
setenv( "DISPLAY", ":0", 1 );
setenv( "GDK_BACKEND", "wayland", 1 );
setenv( "QT_QPA_PLATFORM", "wayland", 1 );
setenv( "WAYLAND_DISPLAY", "wayland-1", 1 ); -
@dencla
On Yocto weston, these envs are needed to run qt apps. You may need them as well. Try these out in your main() and see if they help.
setenv( "DISPLAY", ":0", 1 );
setenv( "GDK_BACKEND", "wayland", 1 );
setenv( "QT_QPA_PLATFORM", "wayland", 1 );
setenv( "WAYLAND_DISPLAY", "wayland-1", 1 ); -
@dencla
On Yocto weston, these envs are needed to run qt apps. You may need them as well. Try these out in your main() and see if they help.
setenv( "DISPLAY", ":0", 1 );
setenv( "GDK_BACKEND", "wayland", 1 );
setenv( "QT_QPA_PLATFORM", "wayland", 1 );
setenv( "WAYLAND_DISPLAY", "wayland-1", 1 ); -
@JoeCFD I gave it a shot. I don't think I saw any change, but I will work with it some more. If I size my screen to fit the display it works, but I would rather not have to do that because I don't know what display it will run on.
-
I thought I posted an answer about this...
In any case, since other application are behaving correctly on the target, the good old technique is to strip down your application to a basic widget. Then add back piece by piece your elements until it starts breaking again.
-
@JoeCFD I gave it a shot. I don't think I saw any change, but I will work with it some more. If I size my screen to fit the display it works, but I would rather not have to do that because I don't know what display it will run on.
-
I thought I posted an answer about this...
In any case, since other application are behaving correctly on the target, the good old technique is to strip down your application to a basic widget. Then add back piece by piece your elements until it starts breaking again.
@SGaist I don't understand the purpose of this. Are you saying that adding a widget to a window causes some error and I'm looking for which one? I have resized all of my widgets to make them fit on the screen and that works, but I prefer not to have to do this as I do not know which screen I will run it on.
-
I don't know your widget so I can't comment however since you are saying that you are resizing things manually then there lies your problem. You should consider using layouts and you will that automatic resizing based on screen size.