The Complete Computing Environment

Picom on EXWM startup

LifeTechEmacsTopicsArcology

,#+ARROYOMODULEWANTS: cce/exwm.org

(provide 'cce/exwm-xcompmgr)

First commit to xcompmgr was in 2003 and there are still people running non-composited X11 environments SMH

(Matthew Garrett on Twitter)

i use picom, a simple X11 compositor that works with EXWM or i3wm or XMonad, and have it start after EXWM does, rather than through home-manager because KDE's kwin doesn't like to compete for the compositor. I provide a custom backend to prevent mpv from tearing.1

(defun cce/run-picom ()
  (interactive)
  (when (executable-find "picom")
    (start-process "picom" " *picom*" "picom" "--backend=glx" "-i 0.9")))
; (add-hook 'exwm-init-hook #'cce/run-picom)
(add-hook 'after-init-hook #'cce/run-picom)

picom comes from home-manager and needs a working NixGL.

{ pkgs, ... }:

let mkNixGLWrapper = pkgs.lib.mkNixGLWrapper;
in 
{
  home.packages = [(mkNixGLWrapper { name="picom"; pkg=pkgs.picom; })];
  systemd.user.services.picom.serviceConfig.enable = false;
}

Footnotes


  1. https://github.com/mpv-player/mpv/wiki/FAQ#X11Intel↩︎