ravynsoft / ravynos

A BSD-based OS project that aims to provide source and binary compatibility with macOS® and a similar user experience.
https://www.ravynos.com
Other
5.61k stars 184 forks source link

0.3.0pre: No menu showing when desktop (Filer) is selected #93

Closed mszoek closed 3 years ago

mszoek commented 3 years ago

When a Filer window is selected, its menu shows in the top bar as expected. However, when the desktop (i.e. no app) is selected, there is no menu. We should still see the Filer menu in this case.

probonopd commented 3 years ago

We had this exact issue in helloSystem initially but it should be resolved there. Can you confirm?

mszoek commented 3 years ago

I don't remember it being a problem with Menu as the top bar. Pretty sure it is a regression due to Plasmashell taking that role. I unfortunately still can't get helloSystem to run in Vmware Fusion so it's hard to test :(

probonopd commented 3 years ago

Still no USB drive to run it on real hardware? ;-)

mszoek commented 3 years ago

USB drives I have :) More that it's a pain to boot stuff natively on my MacBook and I don't have any other hardware available. I guess I can spin it up in qemu or something.

markshank commented 3 years ago

Screenshot from my helloSystem VM running 0.5.0. The Desktop is selected as the "About This Computer" title bar is greyed out.

helloSystem 2021-08-27 143751

probonopd commented 3 years ago

Yes, this works properly on helloSystem 0.5.0. I can't imagine right now what is causing this not to work on Airyx.

markshank commented 3 years ago

I guess I can spin it up in qemu or something.

So I thought I would try that and publish the qemu command line for your convenience.

I installed qemu on my MacBook Air with Homebrew. Tried various configurations. They will boot the FreeBSD kernel, but won't show the FreeBSD splash screen graphic or any other graphics. If I use the Airyx iso, it works fine.

Already had VirtualBox 6.1 installed on my Air, so I played around with that too. Still no joy.

Then started playing around with alternative vm configs on Proxmox. My theory at this point is that helloSystem 0.5.0 requires UEFI.

But I can't find edk2-ovmf in Homebrew. So I'm trying to decide if I want to attempt to create a Homebrew formula. Not really interested unless it would be really valuable for this project.

Was having trouble getting past the EFI shell on VirtualBox, but I did watch a YouTube video on the subject. There is still hope that might work.

Any advice?

probonopd commented 3 years ago

Sorry, I am never using virtualization, always bare metal, so I can't be of much help here. What I can say, though, is that helloSystem runs perfectly well on non-EFI BIOS systems. Typing this from one. Have also booted the Airyx Live USB on this same machine.

mszoek commented 3 years ago

I did successfully run helloSystem 0.5.0 in VirtualBox at one point and also in Qemu. Make sure it has 4GB RAM minimum, and it should not need EFI. Note that after the kernel boots, there is a black screen for quite a while - several minutes - as the memory disk is created & populated. THEN it will show the desktop. (I added some messages in Airyx during that memdisk stage so it was more obvious what is happening.)

Here's a command line that works for me with 0.5.0: qemu-system-x86_64 -m 4096m -smp 2 -accel hvf -cdrom ~/Downloads/hello-0.6.0_0F30-FreeBSD-12.2-amd64.iso

markshank commented 3 years ago

there is a black screen for quite a while - several minutes

I tried your command line and waited and waited and gave up and took a bio break. When I came back, there was the Hello System desktop. Apparently my Early 2014 MacBook Air is underpowered in the virtualization department.

That also answers my original question. I don't need to spend anymore time on that. Thanks!

mszoek commented 3 years ago

The root cause of this turned out to be this change from March 2020 that switches the global menu applet to use KDE's libtaskmanager which excludes NET::Desktop windows. I modified it to include them and haven't noticed any weird effects yet, and it does make the menu work properly. So... #win?

probonopd commented 3 years ago

Very interesting @mszoek. We should find out why the global menu in KDE would want to exclude NET::Desktop windows in the first place. Looks like an anti-feature to me, preventing e.g., Filer from working properly on a KDE Plasma desktop?

Searching for documentation, I am having a bit of a hard time finding anything about libtaskmanager. What does it do?

mszoek commented 3 years ago

KDE's documentation (or lack of it!) is extremely frustrating.

Libtaskmanager seems to be a library that abstracts "tasks" across X11, Wayland and Windows, mapping the abstract concept to their platform equivalent processes and window IDs. It can return the list of tasks and notify clients when the active task has changed. I think it is used by the Alt-Tab switcher.

I suspect libtaskmanager excludes Desktop windows because the desktop is not really a "task" as most users would see it. You would not generally switch to the Desktop with Alt-Tab so it gets filtered out. It does seem like a misfeature when applied to the global menu.

probonopd commented 3 years ago

In the latest ISO, I noticed that we can switch away from the Filer desktop to a black desktop (without a menu) by pressing Alt-Tab (or was it Ctrl-Tab)?. Unintended side effect?

mszoek commented 3 years ago

Partially. I'm sure that is a result of my change to libtaskmanager but I left it for now because it's handy to recover from the black screen issue if it occurs. Still deciding how to handle this properly.

probonopd commented 3 years ago

Actually, I need to switch away from the black screen to the screen that has the desktop. I wonder what that black screen actually is.

markshank commented 3 years ago

Alt-Tab switches me to the black screen. And Filer is still running in the background.

Another Alt-Tab switches me back to the Summer Field desktop.

mszoek commented 3 years ago

@probonopd

Actually, I need to switch away from the black screen to the screen that has the desktop. I wonder what that black screen actually is.

The black screen is plasmashell's desktop window where it would normally render wallpaper and desktop icons. I have turned those things off and set the color to black.

There is some kind of race between the plasmashell and Filer startup that I have not quite isolated yet. If plasma creates its desktop window after Filer has created its desktop window, the plasma window is on top and you see the black screen. If Filer displays after plasma, you see the expected desktop icons and wallpaper.

@markshank

Alt-Tab switches me to the black screen. And Filer is still running in the background. Another Alt-Tab switches me back to the Summer Field desktop.

Yes. The fact that you can switch between the desktop windows is a useful side effect of the change I made to show a menu when the desktop is selected. I left it for now because this problem still exists, but the cause is different.

probonopd commented 3 years ago

The black screen is plasmashell's desktop window where it would normally render wallpaper and desktop icons.

Makes sense. Plasmashell normally draws its own desktop. Gotta reduce it to just the space the menu bar takes. (But then, it might be overkill for "just" the menu bar, my 2 cents.)