Wayland – eirenicon llc https://eirenicon.org Working together for success! Tue, 02 Jan 2024 15:05:17 +0000 en-US hourly 1 https://wordpress.org/?v=6.7.1 https://i0.wp.com/eirenicon.org/wp-content/uploads/2019/03/cropped-eirenicon-1.png?fit=32%2C32&ssl=1 Wayland – eirenicon llc https://eirenicon.org 32 32 61586100 Xorg – Wayland Transition Thoughts… https://eirenicon.org/2023/12/13/xorg-wayland-transition-thoughts/ Wed, 13 Dec 2023 14:41:28 +0000 https://eirenicon.org/?page_id=3692 Revisions:
Initial Draft: 13 Dec 2023
Revised Draft: 14 Dec 2023

This document is yet another one of those I plan to update periodically. We’ll see how that goes.

Merchants Hotel ~1925 Wayland Iowa
Merchants Hotel ~1925 Wayland Iowa

As has become evident from other recent posts I have made here, I am attempting to ‘tough my way through’ a transition from Xorg to Wayland (not the town in Southeastern Iowa). What I can say, unequivocally, is that there is no single, simple, straightforward transition. This is especially true for those of us who like to run multiple desktop configurations. For those happy to work in a more homogeneous setup such as running gnome, kde, or xfce, the challenges will not be as great as they are for folks who run using dwm (to dwl), openbox (to labwc or waybox), and i3wm (to swaywm) on Debian.

In the future, the following issues will need to be addressed ‘permanently’, in one manner or another. For now however, here are some of Wayland’s problem ‘children’ along with some simple, reasonably safe ‘fixes’ for major problems.

By way of full disclosure, I am working primarily on Debian. There are a host of mainline distros I do NOT work on. Therefore, my observations are incomplete and may miss important information that you, on your environment, need. Please, remember to to search the web for further information…

Luckily, I have found a pretty decent solution for those x11 applications requiring root privileges to perform (read these applications normally need polkit to run). The following applications seem to work well and safely when invoked via terminal using “sudo -E”. The “sudo -E “applications I have currently identified (and use regularly) include:

  • synaptic
  • thunar (as root)
  • nemo (as root)
  • pcmanfm (as root)
  • gparted

Here are a few additional items that my research indicates are currently “less” solvable, perhaps even insoluble absent drastic change.

There is no single Wayland-wide method for addressing the identification of active running applications and their respective Desktop/ Workspace. What that means is that just because you can accomplish this on SwayWM does not mean you can solve the same problem, the same way with labwc or River or hyprland or…. (that’s the bad news). The better news is that there are numerous tools that are able to provide partial solutions, such as the following incomplete list:

  • swaymsg (Sway specific)
  • Waybar (best on Sway)
  • swfbar (best on Sway and hyprland)
  • yatbfw (labwc and others?)

A corollary to the above is that waybar, swfbar, yatbfw do not run offering the same features and in the same manner on different Compositors (Desktops). Some run quite well on one or more compositors others may be all but Compositor specific. The same applies for other tools like swaymsg. It is frustratingly variable. Be advised.

Here are tools/ approaches you can use to identify and then address those on your installation(s). For those without solutions, simply be advised the difficulties ‘may be there’ and could cause trouble.

Obviously, I will never identify all the Wayland/ x.org compatibility difficulties/ problems.

How to determine whether an application is running using Wayland (native) or via ‘compatibility mode’ using xwayland, etc.

Background information (some recent articles comparing x11 and Wayland)

The links below are not overly ‘shrill’. Be careful because some information on this topic can become reminiscent of systemd vitriol.

Window Decorations (Borders)

Many (most?) compositors attempt to tell windows not to draw their own decorations and this works for many (most?) applications, but the protocols for doing so are not yet standard or universally supported. As you would expect some windows still draw their own. For now, there’s probably nothing you can do about this ‘problem’, but (for you optimists out there) this is likely to improve in the future, or maybe not.

Lastly, it is worth noting that not all Wayland Compositors (Desktop Systems) operate equally well on all distros. If you are an intrepid Wayland adventurer, the best distros (those offering the broadest number of Wayland Compositors- Desktops) seem to be Arch and Void. Debian/ Ubuntu offer among the fewest.

Compositor (Desktop) Dev-teams

The stability, consistency, and robustness of Compositor development/ support teams is hugely ‘variable’. Be advised that many ‘other’ teams either have evaporated into the ‘ether’ or are operating on a shoe-string. Still other teams are robust (even ‘huge’) and appear to be relatively ‘resource rich’.

Going forward into the future, be prepared for the Wayland world’s many shifts, successes, and failures .

Remember, like with all of my work, I am able to provide the following assurance(s):
  • It is almost certainly going to work until it breaks; although I have to admit it may never work and that would be sad.
  • When/if it does break, you may keep all of the pieces.
  • If you find my materials helpful, both you & I will be happy, at least for a little while.
  • My advice is worth every penny you paid for it!

Image Credits:

Xorg: User:Sven, CC BY-SA 3.0 http://creativecommons.org/licenses/by-sa/3.0/, via Wikimedia Commons
Wayland: Kristian Høgsberg, Intel Corporation, Benjamin Franzke, Collabora, Ltd., Red Hat, Public domain, via Wikimedia Commons

]]>
3692
labwc- A journal, a tutorial? https://eirenicon.org/2023/12/08/labwc-a-tutorial/ Fri, 08 Dec 2023 15:58:07 +0000 https://eirenicon.org/?p=3640 8 Dec 2023- Original Rough DRAFT
9 Dec 2023- Revision 1 of the Draft
11 Dec 2023 – Revision 2 of the Draft

This is a work-in-progress (updates will occur, as I remember to write them). Be AWARE, labwc is fragile. It breaks quite seriously and without much warning and few error detection assists (that I can find or understand) are provided. Use it at your own Risk.

None of this is to say that you should avoid trying to make labwc function, please do; such is the opensource community. Without us, no one will know what ‘needs doing’. By all means jump in and help find the problem areas. Now… on with the show.

There are two pretty ‘straight forward’ method for installing labwc on Debian (sid). I am only testing on sid; thus, you may need to run the meson install method if you are on Debian Stable or some other distro altogether.. Here is a link to the labwc Github page for Build & Install instructions/ guidance. If you are using Debian Sid, here’s a link to the Debian labwc package page. I personally use the following from my terminal (foot) on my SwayWM desktop.

sudo apt install labwc

Next you should make certain that you have the appropriate labwc config files. These seem to mirror those from Openbox. Instructions on how-to get these setup are available from Github. Further clarification and explanation is available on the “Getting Started” page. Reading the aforementioned page provides invaluable insight(s).

Either of the Debian based options work quite smoothly. After you have the Config setup (in basic form) I recommend you reboot. Once your reboot is complete and you login, you even get something akin to a Desktop. Pretty skinny, granted. But it is a good point to build from.

Next, you can begin playing with your favorite Openbox config and try deploying them on labwc. I do this in a step-wise fashion. Below is a current screenshot.

Themes especially for stacking window manager style Desktops are nice to have. Here is a recommended collection. To review and learn about all labwc theme options, see labwc-theme(5) or the themerc example file. Caveat: I have NOT tried using all these themes.

Now for a treasure trove of pre-built themes:

No matter the theme(s) you choose, place them in ~/.local/share/themes/

On Github, johanmalm provides a listing of suggested apps for use with labwc. I have annotated his list with the tools I use (my choice of tool(s) appears in parens.):

Additional tools I use include:

  • file manager: thunar (for root functions I use sudo -E thunar )
  • email: (Thunderbird)
  • software: ( I use synaptic called from terminal via sudo -E synaptic or nala/ apt used normally)
  • browser(s): (Firefox, Microsoft-Edge-Beta)
  • terminal: ( foot )
  • wallpaper changer: ( setwall )
  • I have changed from wofi to a rofi-wayland fork (which runs on both x11 and Wayland), “almost” accurately. Where it has difficulty is in showing all active Wayland/ Xwayland running applications under to command rofi -show window. It is better than nothing (since wofi doesn’t work at this task either), but not by much.

Sad (troublesome) items

Here are some features that are not yet ready and these omissions may make your move from Openbox disappointing. They make mine difficult.

  • Debugging Problems. I find it very difficult to debug errors. When errors occur they are often catastrophic and debug tools are not obvious, to me.
  • Workspaces. They simply are not handled in the same manner as they are on Sway nor do they function like they did using ewmh on Openbox. Here’s the thread highlighting the issue. More posts are available on the web, should you need them. I have found what might eventually be a useful tool, sfwbar. Perhaps, you can make it work better than I am able.
  • Keybinding tools sxhkd/swhkd. Neither seems to be described anywhere I have looked. Thus defining keybindings is a unique and time consuming event, manually needing to built and codified in rc.xml.
  • It is probably worth noting that keybindings are, also, different from Openbox, albeit only slightly.

A word of Caution (because I have now been caught twice unprepared): Be extremely cautious of any updates you might make. Be absolutely certain you are able to roll back to a previous state. Even little (tiny) mistakes can be a cause for a complete rebuild.

More to come as I progress and gather my notes…

Contact me directly with ideas, questions, comments.

Remember, like with all of my work, I am able to provide the following assurance(s):
  • It is almost certainly going to work until it breaks; although I have to admit it may never work and that would be sad.
  • When/if it does break, you may keep all of the pieces.
  • If you find my materials helpful, both you & I will be happy, at least for a little while.
  • My advice is worth every penny you paid for it!
]]>
3640
Conky on Wayland (SwayWM) https://eirenicon.org/conky-on-wayland-swaywm/ Mon, 24 Jul 2023 12:03:29 +0000 https://eirenicon.org/?page_id=3535 Recently, I have been working at understanding, building, and using Wayland/SwayWM as my regular computing environment.  Given I continue to be in the ‘early days’ of this adventure, I have had to address several usage ‘worries’.  One of my concerns had been fixing and using conky on my desktop, over the years I have become a great fan of Conky.

Now I can report and show, how to make Conky work on SwayWM.  I presume it will function on other Wayland desktop systems, as well.

@Unklar provided me with the solution to this dilemma you may read it via this link.

As you will notice, Conky itself has been enhanced to address its ability to run on Wayland. Making this happen involves the addition of one simple command in your conky config section:

out_to_wayland = true,

Here is an image (on my SwayWM desktop) of Conky ‘in action’.

Conky on SwayWMThis is a link to the entirety of my conky for this desktop, both conkies are included. Feel free to edit and use these conkies in your application and work.

 

Remember, like with all of my work, I am able to provide the following assurance(s):
  • It is almost certainly going to work until it breaks; although I have to admit it may never work and that would be sad.
  • When/if it does break, you may keep all of the pieces.
  • If you find my materials helpful, both you & I will be happy, at least for a little while.
  • My advice is worth every penny you paid for it!

]]>
3535
SwayWM on BearDog (Debian) & EndeavourOS (Arch) (tutorial) https://eirenicon.org/knowledge-base/sway-on-debian-arch/ Tue, 18 Jul 2023 23:11:35 +0000 https://eirenicon.org/?page_id=3476 revised:

1 Jan 2024
2 Dec 2023
20 Jul 2023
22 Jul 2023

Lately, I have taken the time to see how SwayWM/ Wayland might function for me (and you?). I began on a Debian based distro, specifically BearDog.  Now that I have managed to create a functioning reasonably ‘stable’ installation, I thought I’d provide the results and specifics of my discoveries.

As noted above, I believe my environment is now quite stable. I have been running SwayWM for over a month on both Debian (BearDog) and Arch (EndeavourOS). 

TL;DR: Based on my past experiences, I can confirm that SwayWM seems, based upon my usage, to run well on both Arch & Debian (Sid/ Unstable).

I have settled on Arch as my preferred platform, simply because I prefer running on a more reliable rolling release base.  Debian Sid has experienced some peculiar faults/errors over the last few weeks; although none seem linked/ related to  running SwayWM/ Wayland, they ‘got in my way’.  

For that reason,  EndeavourOS simply has functioned better for what I want and how I prefer to do ‘things’.

The following are my SwayWM & Wayland Notes

General:

Debian seems quite resource poor (almost impoverished) in the Wayland/ SwayWM ecosphere, although in recent months that appears to be on the mend (somewhat). The most resource rich distros include: Arch, Void, Gentoo, even ‘tiny’ Alpine seems to have more.  A corollary to this would suggest those distros might be good places to seek help, ideas, tools, etc.

In this tutorial, I will present some of the workarounds I have unearthed in order to over-come challenges and frustrations, I encountered. I think (hope?) I have kept track of the most important info and shared it here.

IMHO. It is “not super easy” but it IS possible to make Wayland/ SwayWM into a fully functional, rewarding computing environment. The environment I have, thus far created, I find enjoyable to use. Almost certainly Wayland is not as rich an environment as x-windows offers; but, it is fun, aesthetically pleasing and usable.

SwayWM, Wayland, Waybar, Conky (x2), Yad, Rofi all on Debian Sid/Trixie

Here is a requisite screenshot. The image displays SwayWM, Wayland, Waybar, Conky (x2), Yad, Rofi all on Debian Sid/Trixie.

Other Wayland information resources:

It all began on BearDog (Debian)

Be advised, I began by running SwayWM & Wayland on Debian Sid/Trixie. The reason for the Sid/Trixie choice is my preference for having and using current software. Tools such as SwayWM and Wayland are in active development; which means they change frequently. Should you elect a different platform, your mileage may vary…

Installing the basic Wayland/ SwayWM base is pretty straight forward. I followed the guidance on this page in the Debian wiki.  As for Arch, here is a link to Colin Woodbury’s tutorial which I used to help with my EndeavourOS install. 

FWIW. My i3wm setup was NOT in any way drop-in compatible with SwayWM. I run both regularly and they ‘are’ different.  Apparently, I have much too much going on in my i3wm install to make any port seemless.

Compatibility between my i3wm and SwayWMis all but non-existent.  I ultimately elected to find a clean SwayWM install and then tweak it to fit my needs. I elected to use the EndeavourOS Sway Community edition as my base. Thank you everyone at EndeavourOS!

My tweaked version, which is by now quite different from that on EOS, is that offered above.  (I’ll attempt to keep the dotfiles current.)

I have augmented what I learned on the above pages creating the following instruction document. Be advised this works for me, I can only hope it works for you, too. (See my warranty at the bottom of the page).  Here is a link to my  SwayWM-Wayland Dotfiles (I have successfully tested and use these dotfiles on my EndeavourOS base (Arch).)

The Journey

Below are the component parts I have tweaked, hacked, revised and bent to my preferred approach, such as my skills allow.  You may certainly use my code base or EndeavourOS’, which is available here and is minus my changes offered at the link above) or…

All of the folders, you wish to use, should be placed in your $Home/ directory. There are materials that will be placed in the following hidden directories:

  • .config
  • .conky
  • .local (the full path will be .local/share/scripts)

Remember: my dotfiles will only work after you have installed SwayWM and Wayland on your system. AND, I apologize in advance for any materials I may have forgotten to put in here. Use our Contact Page to let me know if you need something I may have omitted.

SwayWM-Related Folders

These are most, if not all, of my ‘dotfiles’.

Keep in mind I will continually (assuming I remember) drop new versions of my ‘stuff’ here for you to use.  You should fully expect to modify and enhance what you find here, to suit your needs. This IS NOT a guaranteed clean install. (See my Warranty below)

Terminal Option(s)

I have elected to use foot as my primary Wayland/ SwayWM terminal. Why? Because, it is light, fast, and easy to tweak.  Sadly, it does not run on X11 (or I’d consider using it everywhere).

If you are seeking a terminal that is flexible & reasonably light to use on both X11 and Wayland, I recommend xfce4-terminal. It works amazingly well on both x11 and Wayland; plus, xfce4-terminal is able to support geometry and position settings.

However, you are, certainly, able to find other fancier, cooler, trendier terminals should you choose to do so.

Transition Challenges

Because of an over abundance of x-windows application experience, I have encountered awkward transitions to new methods of working. Think square peg, round hole. Here are a few examples where I am reluctant to perform back-flips in order to accomplish tasks.

Various items (software apps) that are not yet ready for Wayland (Root privs).

  • First and foremost, be aware you need to install a polkit (such as lxpolkit-polkit) for the following fix(es) to work.
  • In the Debian universe Synaptic is pretty important. Sadly, Synaptic is one of those problem children. If you wish to use it, Synaptic is best called via terminal for security reasons. The command line is “sudo -E synaptic”.
  • Thunar Open as Root does not work in Wayland. If you wish to Open Thunar as Root via terminal. The command line is “sudo -E thunar”.
  • The same applies to Nemo. Nemo Open as Root does not work. Open Nemo as Root via terminal. The command line is “sudo -E nemo”.
  • The same applies to Gparted. Open Gparted as Root via terminal. The command line is “sudo -E gparted”.

Synaptic

I have been reliant on this Debian package management tool for more than 20 years… Debian, unlike ArchLinux, does not offer the wealth of package managers and approaches. Luckily, I dug up an approach to rescue & use synaptic. I know this weird hack has risks (the preferred approach involves using sudo -E, noted above) …

Here is another approach you may be able to live with (source: Reddit

My read (FWIW) is that the above approach is both more difficult and less reliable than simply opening an offending app via command line in terminal using sudo -E.

Xwayland

In an effort to get a “goodly number” of x-windows applications to run under Wayland, I installed Xwayland. It is not difficult. You simply install Xwayland in order to achieve a degree of  native x-window (x11) application compatibility.

CAVEAT: It is always better to use a native Wayland application, if you can find one. Xwayland (and QTwayland for that matter) are simply temporary solutions.

QTwayland

The same situation exists, and can be similarly addressed, for qt applications. (Here is the reference for the following solution.)  The major installation process follows:

  • sudo apt install qtbase5-dev
  • git clone git://code.qt.io/qt/qtwayland.git
  • cd qtwayland
  • git checkout v5.10.0
  • qmake
  • make
  • make install

Random Wallpaper Background

The simplest, closest to ‘nitrogen approach’ I prefer to use in X11, involves installing ‘setwall’. Because setwall is written using rust, you can install it using ‘cargo’. I will try using it (it should work well) on my x11 window manager setups.

Wofi/Rofi

If you are running on Wayland only, wofi appears to be an excellent tool to use.  Unlike SwayWM with i3wm, wofi appears to be compatible with the rofi setups and scripts I use.  However if you run both X11 and Wayland based window managers (like I do), I recommend sticking with Rofi (after you install Xwayland).  It works well, then, in both environments.

Taking Screenshots

In order to take desktop screenshots, I found the following installations were required:

  • install grim (using apt/nala).
  • install grimshot (using apt/nala)

I am considering adding a new (to me), hopefully more approachable screenshot toolset to SwayWM:

My initial read is that sway-screenshot adds a few nice features. But, grim by itself is silent, fast and generates a simple screenshot (entire window), just fine.  Obviously the choice is yours.

Conky

As a huge fan (user) of Conky, I am very pleased to have obtained a guide on how-to install and make Conky run on Wayland. This guidance may be found on the Lilidog Forums from @unklar. I should add that getting Conky to reliably run on both Arch & Debian base distros, required I clean up my conky scripts (massively). A warning to the wise, “Conky will NOT suffer messy code on Wayland. “

Additional ‘frustrations’

There are a few pieces of missing system functionality that irk me.  I know I should be able to survive without these things. I simply do not ‘prefer’ to run minus these functions, every day. Oh well…

  • root level access at the GUI level. This impacts several critical applications including Thunar, Gparted, Synaptic, among others I am certain.

Should you find or know of good ways to address the issues I have noted, please use our contact page to let me know.

Have fun with SwayWM and Wayland. If you have additional tips and pointers you believe I should publish here, be sure to let me know.

Remember, like with all of my work, I am able to provide the following assurance(s):
  • It is almost certainly going to work until it breaks; although I have to admit it may never work and that would be sad.
  • When/if it does break, you may keep all of the pieces.
  • If you find my materials helpful, both you & I will be happy, at least for a little while.
  • My advice is worth every penny you paid for it!
]]>
3476