Skip to main content
Topic: searching for a wayland openbox (Read 2192 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

searching for a wayland openbox

I'm trying out wayland in an artix qemu vm. Normally I am an openbox  user. I think simpler is better. I removed most of the normal slim+openbox stuff I have installed.

As a first step into wayland I installed labwc-git, wlroots & swayland.  labwc is  supposed to be similar in spirit to openbox.

Then I can start a graphical screen using ./labwc it seems to work.

There is a primitive middle button menu which shows a lot of tearing. The VM details says it's using Video Virtio. I have xfce4-terminal in the menu so I can test xwayland. That works, but any attempt at moving the terminal shows a lot of tearing.

What am I testing? Is the qemu video broken? Or is it wayland in the VM?

So far wayland seems a bit disorganised. It seems the video engineers prefer simple new stuff, but the intermediate layers seem to be missing or too large to be easily understood.

Re: searching for a wayland openbox

Reply #1
That Labwc has made me curious to try wayland again, it really seems like a replacement for the simple x stuff. I'm also not using the full desktops but rather the "wrapper" that is LXQt, so i guess kinda in the middle.

I will try it myself and report back. :)

Re: searching for a wayland openbox

Reply #2
I will try it myself and report back. :)

thanks, for some reason this got posted twice. I looked for a delete, but could not find one. Perhaps the true ruler of the house, BrandyKat, walked on the keyboard.

Also there is another openbox type pkg for wayland called waybox (https://github.com/wizbright/waybox); I haven't tried that yet.

Re: searching for a wayland openbox

Reply #3
Oh okay, something is interesting, Labwc is in theory superior as it doesn't require wlroots. And started from a tty has the nice feature of inheriting whatever i launch from the x session on it.
They both seem to get started by sddm just fine and neither have any tearing. On actual hw of course. :D
I will try to run the lxqt stuff on it next tomorrow.

Re: searching for a wayland openbox

Reply #4
OK I used real hardware with labwc and after disabling slim and installing labwc-git wlroot swaybg bemenu I was able to run labwc from the console.

1) it seems stable
2) I didn't have much in the default menu just Exit & Reconfigure

Not sure exactly why that is, but ~/.config/labwc was not auto-genereated.

 I rsynced .config/labwc/ from my VM it has a few bits in it. I can't remember how this got created. With that in place I could at least poweroff, exit, reconfigure or run a terminal (xfce4-terminal). Edit: I believe I must have followed this page https://labwc.github.io/getting-started.html

Everything was stable I saw no tearing. I ran detach swaybg -c '#263248' and the background changed. This looks like a good start at an openbox env; needs a panel of some sort, proper menu  etc etc.

I will enquire of the author regarding VM behaviour.

Hitman, you say you used sddm to start labwc. I don't use it, but did you just add some sort of xsession?




Re: searching for a wayland openbox

Reply #5
Okay I recompiled it today with the git version, put in .config/labwc with some autostart stuff, added the lxqt stuff and even the bar runs surprisingly albeit broken so I'll have to use what they use like waybar and stuff, i also see a slight blur effect which is nice/or maybe qt is doing it. And it even has the window panning and auto tilling that i have to use the bloated kwin for currently. I need to get correct dpi and a menu layout working before anything but yeah i can totally use this!

The session just shows up in my preconfigured sddm, which probably runs in x11 but can start wayland session regardless, i need to see that too and maybe correct it if i decide to switch to this. :)

Re: searching for a wayland openbox

Reply #6
I think the various xorg bars are a bit picky about what they display in labwc; eg tint2 can show an icon for gvim-gtk2, but not xfce4-terminal. I think that must be related to how the signal or something.

I tried waybar, but it doesn't autohide (so far) and I need to see if it can show apps etc etc.

Re: searching for a wayland openbox

Reply #7
Yeah i'm kinda yet to find a good bar. And yet to configure waybar too cause it's kinda complex, maybe it'll look ok, if it cannot hide itself it can be put possibly vertical?
Had a laugh at this thing https://github.com/elkowar/eww config file eww.yuck :D
It was nice to see that MOZ_ENABLE_WAYLAND finally works and scaling works with kanshi and isn't blurry. Qt looks fine and gtk at least 3 and 4 do too.
Other than that i see the same problem as on my mobile telephone's wayland desktop where right click menus have a bit of delay and xwayland is mostly working but eh, so and so.
Got further with it this time, will have another look later, if you find some interesting additions post them here!

Re: searching for a wayland openbox

Reply #8
I tried to set up lxqt-labwc-session and run via sddm. However it fails immediately. If I try to start it from a terminal I get an error like this

Code: [Select]
00:00:00.050 [INFO] [../labwc/src/input/cursor.c:1230] Cursor theme is missing cursor names, using fallback
xkbcommon: ERROR: [XKB-338] Couldn't find file "symbols/en" in include paths
xkbcommon: ERROR: [XKB-338] 1 include paths searched:
xkbcommon: ERROR: [XKB-338] /usr/share/X11/xkb
xkbcommon: ERROR: [XKB-338] 3 include paths could not be added:
xkbcommon: ERROR: [XKB-338] /home/robin/.config/xkb
xkbcommon: ERROR: [XKB-338] /home/robin/.xkb
xkbcommon: ERROR: [XKB-338] /etc/xkb
xkbcommon: ERROR: [XKB-769] Abandoning symbols file "(unnamed)"
xkbcommon: ERROR: Failed to compile xkb_symbols
xkbcommon: ERROR: Failed to compile keymap
00:00:00.051 [ERROR] [../labwc/src/input/keyboard.c:590] Failed to create xkb keymap
Segmentation fault

lxqt was mentioned by hitman so I wonder how it was started.

EDIT: this problem was caused by some process/config not knowing the true name of the keyboard maps for my locale which is en_GB. The standard keyboard name is not en, but gb. I managed to start the LXQt Labwc session after making a symbolic link sudo ln -s gb  /usr/share/X11/xkb/symbols/en.  The session came up, but LXQt was a bit confused and I seem to have panels top and bottom. Most of the desktop did seem to work though, but it seems a bit unstable. The real problem is that it's using labwc as a compositor for LXQt and I really prefer openbox.

Re: searching for a wayland openbox

Reply #9
Didn't know about that project with lxqt wayland files, it's pretty cool. The last changelog in lxqt about this was in 1.3.0 (regarding some prevented errors) but nothing regarding the panel, so far it stays in the middle of the screen no matter how i put it
They provide a config for the panel maybe it does something for you https://github.com/stefonarch/lxqt-labwc-session/blob/master/config/panel-wayland.conf.in

Then they have a session and env config which basically puts some overrides and starts lxqt-session on top of labwc. Which i guess it's needed because trying to simply put in labwc as compositor expecting an xorg one ended in disaster, hehe. It kind of works for me but feels too hacky.

In more recent news they are finishing support early next year natively https://www.phoronix.com/forums/forum/phoronix/latest-phoronix-articles/1427390-lubuntu-24-04-lts-aiming-for-optional-wayland-session-default-in-24-10
With that and labwc getting some blur and shadow tuning to do the same beauty as i do with picom i will switch right away :)

Re: searching for a wayland openbox

Reply #10
Okay, i scrapped trying to hack lxqt-session and went back to @replabrobin's original idea of a true barebones desktop, it seems sfwbar is nicer to use and close to how the lxqt bar looks.

WM remains labwc 99% unless one comes with better theming.

That's how i put my autostart/env:
Quote
labwc/autostart:
sfwbar &
swaybg -i image &
lxqt-policykit-agent &
kanshi &

kanshi/config:
profile {
   output HDMI-A-1 scale 2
   }

labwc/environment:
BROWSER=falkon
GTK_CSD=0
GTK_OVERLAY_SCROLLING=0
QT_QUICK_CONTROLS_STYLE=org.kde.desktop
QT_QPA_PLATFORM=wayland
QT_QPA_PLATFORMTHEME=kvantum
QT_STYLE_OVERRIDE=kvantum
(to have a proper qtplugin since this isn't a full desktop set these last two either qt6ct or kvantum)
MOZ_ENABLE_WAYLAND=1

Works pretty good, it's simple just like openbox/icewm, not ironed out of course but functional enough and i would be attracted to use it right away thanks to the superior dpi scaling in wayland, just got to get used to a few bugs.

Offtopic but how is the cursor gpu accelerated so that it lags under video load? lmao. i gotta make it sw drawn like x11 does.
Found out, i recommend you do this by default for some pretty obvious reasons:
WLR_NO_HARDWARE_CURSORS=1

 

Re: searching for a wayland openbox

Reply #11
There are new session script files in the lxqt wayland files repo, thanks to native support in the new lxqt session and co. they're much slimmer, a bit weird that they didn't officially add it this time but i can understand.
I've looked over them and decided to slim them down even further.
Also using greetd as opposed to a full session manager to avoid conflicts with my turnstile+seatd setup, and it's slimmer afterall.

If you use regular logind use the full script instead: https://github.com/stefonarch/LXQt-Wayland-files/blob/main/start_scripts/startlxqtlabwc

Code: [Select]
#!/bin/sh
export QT_PLATFORM_PLUGIN="lxqt"
export XDG_MENU_PREFIX="lxqt-"
export XDG_CURRENT_DESKTOP="LXQt:labwc:wlroots"
export QT_EXCLUDE_GENERIC_BEARER=1
export QT_AUTO_SCREEN_SCALE_FACTOR=0
export XDG_DATA_HOME="$HOME/.local/share"
export XDG_CONFIG_HOME="$HOME/.config"
exec labwc -C $XDG_CONFIG_HOME/labwc -s lxqt-session
Then make it as executable and add it under /etc/greetd/config.toml e.g.
Code: [Select]
[default_session]
command = "/path/to/script"
user = "youruser"

And that's it, it just works.

Don't forget to check labwc's environment file, maybe remove it altogether as from what i saw lxqt session exports everything just fine, and remove the qt style override variable as it doesn't play nice with qt6.

Apart from that, a few bugs but it looks good. :)