GUI has two different sizes
After starting console or basicshell there is the problem, that the GUI can have different screen sizes.
E. g. console can have two diffent sizes
With console it is only a cosmetic problem, but basicshell is often so small that it must be retarted to be able to work with it.
I'm using Ubuntu with WSL and VcSrv X Server. With C64Screen there is no such problem.
Can you provide an example of how BasicShell looks when this happens?
It is the black line:
I started BasicShell four times: the first three attemps were as expected, but then the windows is very small. The good news: it can be resized
Strange. I've never seen this behaviour. I've modified the GUI initialization code of the BasicShell to see if that has any effect. Please give it a try.
Console: Small size at the first start, then always the bigger size BasicShell: the size toggles: big, black line, big, black line, ...
No idea then...I've switched the order of some stuff in the BasicShell, please see if that does something...
Perhaps this helps: here is the hwininfo of the big and the little windows:
xwininfo: Window id: 0x200003 (can't convert UTF8_STRING to unknown encoding)
Absolute upper-left X: 0 Absolute upper-left Y: 0 Relative upper-left X: 0 Relative upper-left Y: 0 Width: 800 Height: 600 Depth: 24 Visual: 0x21 Visual Class: TrueColor Border width: 0 Class: InputOutput Colormap: 0x20 (installed) Bit Gravity State: NorthWestGravity Window Gravity State: NorthWestGravity Backing Store State: NotUseful Save Under State: no Map State: IsViewable Override Redirect State: no Corners: +0+0 -352+0 -352-272 +0-272 -geometry 800x600+0+0
xwininfo: Window id: 0x200003 (can't convert UTF8_STRING to unknown encoding)
Absolute upper-left X: 0 Absolute upper-left Y: 0 Relative upper-left X: 0 Relative upper-left Y: 0 Width: 120 Height: 1 Depth: 24 Visual: 0x21 Visual Class: TrueColor Border width: 0 Class: InputOutput Colormap: 0x20 (installed) Bit Gravity State: NorthWestGravity Window Gravity State: NorthWestGravity Backing Store State: NotUseful Save Under State: no Map State: IsViewable Override Redirect State: no Corners: +0+0 -1032+0 -1032-871 +0-871 -geometry 120x1+0+0
The problem seems to be, that Java's layout manager thinks, that the window is empty when it actually shouldn't be. That's quite strange and I can't reproduce it. I'm on vacation now for two weeks but I'll try to reproduce it on Linux afterwards.
The different window size is not really a problem, so this issue can wait. I wanted to try it with a commerical XServer, but it can't find the bought license number. So I have two weeks time for searching it ;-)
Have a beautiful holiday
I tried to reproduce it with the latest version of vcxsrv (Version 21.1.13) and wsl1 for windows. First all looks fine, but when I switched the screen resolution to 1152 x 864, then the Problems with BasicShell appeared again.
I made some tests with a commerical xserver (Netsarang XMANAGER). Here were no problems.
On another PC I installed wsl2, because here GUI is already integrated.
Here BasicShell works, but the window for Console or MOSpeed is always too small and must be resized.
I've really no idea, why it behaves so erratically. I guess it must have something to do with the fact that the size is dynamic. I'm giving it a preferred size and an actual size (both set to the same value), but the layout manager is free to change it, if it thinks that these values won't fit for some reason. My guess is, that the OS reports something strange so that the layout manager gets confused. I'm not sure what to do about that ...
I still haven't solved the issue, but my son made a UI in .NET, which is much more comprehensive. It should run under Windows and Linux (at least it did for me). Maybe you want to give that one a try instead: https://github.com/Error504TimeOut/MoSpeedUI/releases