[2024-feb-29] Sad news: Eric Layton aka Nocturnal Slacker aka vtel57 passed away on Feb 26th, shortly after hospitalization. He was one of our Wiki's most prominent admins. He will be missed.

Welcome to the Slackware Documentation Project

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
wiki:user:pghvlaans [2023/12/23 00:06 (UTC)] – [General Configuration] pghvlaanswiki:user:pghvlaans [2023/12/23 00:45 (UTC)] – [Running] pghvlaans
Line 1: Line 1:
-===== Using X11 Environments in Xwayland ===== +===== Running Xorg Environments in Xwayland =====
-<note important>This is a draft, and parts of it haven't been tested properly just yet, especially for 15.0.</note> +
 > Being able to read xorg.conf is not one my goals, nor achieving a bug-for-bug compatibility with Xorg - Xwayland with !901 (merged) allows to run a full X11 desktop, even the most legacy ones  (I demoed it internally here using CDE from an XDMCP remote connection for the fun 😉).((Olivier Fourdan, xserver issue [[https://gitlab.freedesktop.org/xorg/xserver/-/issues/1332#note_1431672|#1332]])) > Being able to read xorg.conf is not one my goals, nor achieving a bug-for-bug compatibility with Xorg - Xwayland with !901 (merged) allows to run a full X11 desktop, even the most legacy ones  (I demoed it internally here using CDE from an XDMCP remote connection for the fun 😉).((Olivier Fourdan, xserver issue [[https://gitlab.freedesktop.org/xorg/xserver/-/issues/1332#note_1431672|#1332]]))
  
-This is a how-to guide for running an X11 window manager or desktop environment in Xwayland on Slackware 15.0 and beyond.+This is a how-to guide for running an Xorg window manager or desktop environment in a Wayland compositor((In Wayland terms, the "compositor" is the program responsible for displaying and managing windows. KWin is the only Wayland compositor included in Slackware 15.0.)) on Slackware 15.0 and beyond.
  
-At the time of writing (December 2023), this is a purely academic question for most -- if not all -- users. As both KDE Plasma and Xfce continue to move in the direction of Wayland, however, it is not impossible that full X servers become unavailable on Slackware in future years. This poses a dilemma from both a user and a software preservation perspective. Xwayland provides a way forward, if an imperfect one. The process of running an Xorg environment from inside a "rootfull" Xwayland session is straightforward:+At the time of writing (December 2023), this is a purely academic question for most -- if not all -- users. As both KDE Plasma and Xfce continue to move in the direction of Wayland, however, it is not impossible that full X servers become unavailable on Slackware in future years. Xwayland provides a workaround, if an imperfect one. The process of running an Xorg environment from inside a rootful(("Rootfulhere means that the Wayland compositor does not manage the Xwayland window.)) Xwayland session is straightforward:
  
   * Choosing a Wayland compositor \\   * Choosing a Wayland compositor \\
   * Configuration \\   * Configuration \\
   * Running the Wayland compositor \\   * Running the Wayland compositor \\
-  * Starting the X11 environment on Xwayland \\+  * Starting the Xorg environment on Xwayland \\
  
 All outside packages mentioned here can be found on [[https://slackbuilds.org|SlackBuilds Online]]. All outside packages mentioned here can be found on [[https://slackbuilds.org|SlackBuilds Online]].
 ==== Choosing a Wayland compositor ==== ==== Choosing a Wayland compositor ====
-The following considerations are important in choosing a Wayland compositor:+The following considerations are important in choosing a Wayland compositor to run the Xwayland server:
  
   * Lightweight   * Lightweight
   * Stacking window management   * Stacking window management
-<note important>The following two conditions can be ignored if the Xwayland version exceeds 22.1.3.</note>+<note tip>The following two conditions can be ignored if the Xwayland version exceeds 22.1.3.</note>
   * Able to suppress client-side decorations   * Able to suppress client-side decorations
   * Compatible with [[https://slackbuilds.org/repository/15.0/desktop/wlroots/|wlroots]] for [[https://slackbuilds.org/repository/15.0/desktop/wlr-randr/|wlr-randr]], a drop-in xrandr replacement.   * Compatible with [[https://slackbuilds.org/repository/15.0/desktop/wlroots/|wlroots]] for [[https://slackbuilds.org/repository/15.0/desktop/wlr-randr/|wlr-randr]], a drop-in xrandr replacement.
Line 71: Line 69:
 These changes reflect post-15.0 Xwayland development: These changes reflect post-15.0 Xwayland development:
  
-  * Rootfull Xwayland windows are no longer decorated, so ''rc.xml'' is unnecessary.  +  * Rootful Xwayland windows are no longer decorated, so ''rc.xml'' is unnecessary.  
-  * The initial geometry of the Xwayland server must be specified. Replace the Xwayland line in the autostart script above with the following +  * The initial geometry of the Xwayland server must be specified. Replace the Xwayland line in the autostart script above with the following:
      
   ''DISPLAY=:1 startx -- /usr/bin/Xwayland -fullscreen -geometry 1920x1200''   ''DISPLAY=:1 startx -- /usr/bin/Xwayland -fullscreen -geometry 1920x1200''
Line 78: Line 76:
 Ideally, the ''geometry'' option will match the dimensions of the monitor. xrandr can change the resolution afterwards. Ideally, the ''geometry'' option will match the dimensions of the monitor. xrandr can change the resolution afterwards.
 ==== Running ==== ==== Running ====
-The Wayland compositor should be known to the display manager for Run Level 4 users, assuming that its package includes a desktop file. Run Level 3 users can run the Wayland compositor directly from the command line:+The Wayland compositor should be known to the display manager for runlevel 4 users, assuming that its package includes a desktop file. Runlevel 3 users can run the Wayland compositor directly from the command line:
  
   $ /usr/bin/labwc   $ /usr/bin/labwc
  
-Once the autostart script has started the X11 environment, the following commands can verify that the process worked:+Once the autostart script has launched the Xorg environment, the following commands can verify that the process worked:
   $ pgrep Xorg   $ pgrep Xorg
   $ pgrep Xwayland   $ pgrep Xwayland
-If there is at least one Xwayland process (may vary by Wayland compositor) and no Xorg process, feel free to take a screenshot (optional) and tell your friends (not advised).+If there is at least one Xwayland process and no Xorg process, feel free to take a screenshot (optional) and tell your friends (not advised).
  
 ==== Caveats ==== ==== Caveats ====
Line 93: Line 91:
   * xrandr is non-functional in Xwayland versions before 22.1.3, and an extra program such as wlr-randr would be needed for screen management. Effectively, this restricts the choice of compositor to those based on wlroots.   * xrandr is non-functional in Xwayland versions before 22.1.3, and an extra program such as wlr-randr would be needed for screen management. Effectively, this restricts the choice of compositor to those based on wlroots.
   * GPU memory usage is slightly higher relative to running an ordinary xserver.   * GPU memory usage is slightly higher relative to running an ordinary xserver.
-  * Wayland-only programs (e.g. waydroid) and any other program that runs in Wayland mode will be managed by the Wayland compositor rather than the Xorg environment.+  * Wayland-only programs and any other program that runs in Wayland mode will be managed by the Wayland compositor rather than the X11 environment.
   * Neither xinput nor synclient will work to turn off touchpads, for example.   * Neither xinput nor synclient will work to turn off touchpads, for example.
   * If an input device does not work in the chosen Wayland compositor, running an Xwayland server will not cause it to start working.   * If an input device does not work in the chosen Wayland compositor, running an Xwayland server will not cause it to start working.
Line 104: Line 102:
   * Xwayland(1)   * Xwayland(1)
   * labwc(1)   * labwc(1)
 +  * labwc-config(5)
   * [[https://gitlab.freedesktop.org/xorg/xserver/-/issues/1332#note_1431672|xserver, Issue #1173: Xwayland: Improve rootfull mode for legacy X11 environments]]   * [[https://gitlab.freedesktop.org/xorg/xserver/-/issues/1332#note_1431672|xserver, Issue #1173: Xwayland: Improve rootfull mode for legacy X11 environments]]
 wiki:user:pghvlaans ()