Open atropos1789 opened 1 year ago
This is very strange. I had to use ~/.Xresources
myself a while back, and it seemed to work just fine. I think it will be very difficult for me to reproduce this bug. Let me know if you figure out something
Can confirm that xrdb
for some reasons doesn't work. I even tried to run it "manually" in the script, but it hasn't helped.
/etc/lemurs/wms/awesome
--------------------------------
#!/usr/bin/env bash
xrdb -merge $HOME/.Xresources
exec awesome
It works perfectly if I use another DisplayManager or even with startx
+ /etc/lemurs/wms/awesome
commands.
$ lemurs --version
0.3.1
$ xrdb -version
xrdb 1.2.1
$ uname -a
Linux laptop 6.2.13-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 26 Apr 2023 20:50:14 +0000 x86_64 GNU/Linux
I am able to reproduce the behavior. It is very strange. From what I see, some other DMs (e.g. Ly) have the same problem. I think the xsetup.sh
script runs xrdb
at the wrong time in the Xorg start. There is no real documentation on this so I will have a look what other DMs do to see whether that works.
@coastalwhite Can confirm i have faced the same problem today, had to revert to my previous display manager in order to get it working.
Hello, nice to meet you all 👋🏻 I'd like to join this conversation and see if/how I can help, considering I'm actively using Lemurs and have to deal with this issue daily.
As a first attempt, I tried to apply a sleep between the X bootup and the xstart.sh
execution (to ensure that no race condition was present), but It didn't work. I also verified that the script was actually executed after receiving the sigusr1
signal (to make sure that no weird exiting condition was causing the script to be executed before the X process exited). I also looked at how Ly handles that part of the startup, but It seems similar to Lemurs (unless the bug hides inside the complexity of our abstractions - the C code is pretty straightforward on this). I'll add more details as soon as I have time to dig dive.
Thank you. I would love for someone to look further this. Personally, I got a bit lost on this issue when I looked into it before.
I had the same problem.
Adding xrdb -load ~/.Xresources &
right before exec
in the wms script works perfectly for me.
I had the same problem. I added the following to the end of my ~.xinitrc
(after all the background processes were kicked off): xrdb -load "$HOME/.Xresources"
. Maybe add it before everything if those background processes need something from ~/.Xresources
in your .xinitrc
.
I noticed /etc/lemurs/xsetup.sh
only calls xrdb -merge $HOME/.Xresources
(~which didnt work to load in Xresources when added to .xinitrc
, only -load
worked~ -> wrong, see my last comment).
Although, looking at the documentation for xrdb, I don't feel like it should matter. I feel like we are safe to replace -merge
with the -load
option by default. I will test it out and see what I find.
~Yeah I thought the same thing before trying both, it doesn't seem like it should matter.~
My theory was wrong, both -load
and -merge
work fine. Sorry for the confusion. I was having a problem with another part of my setup I thought was related to Xresources loading, but I now know is not.
I just added this line from xsetup.sh
at the end of my .xinitrc
and everything works fine:
[ -f "$HOME/.Xresources" ] && xrdb -merge "$HOME/.Xresources"
I want to use Lemurs bit this issue is preventing me from doing so. I use .Xresources to set my screen DPI, and it's the only way that I've been able to use my external monitor with my HDPI laptop screen together. It's an annoying, but hard-won victory for this to work and I'm not keen on trying to find another solution in that regard. I want to use Lemurs so that I can finally have sleep/idle working properly since i3 doesn't report idle events for logind.
I've tried some of the fixes in the comments here, but none of them work. The following .xinitrc with startx
has worked for a long time:
#!/bin/sh
userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap
# merge in defaults and keymaps
if [ -f $sysresources ]; then
xrdb -merge $sysresources
fi
if [ -f $sysmodmap ]; then
xmodmap $sysmodmap
fi
if [ -f "$userresources" ]; then
xrdb -merge "$userresources"
fi
if [ -f "$usermodmap" ]; then
xmodmap "$usermodmap"
fi
# start some nice programs
if [ -d /etc/X11/xinit/xinitrc.d ] ; then
for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
[ -x "$f" ] && . "$f"
done
unset f
fi
setxkbmap us -option ctrl:nocaps
XDG_MENU_PREFIX=arch- kbuildsycoca6
exec i3
I created the following /etc/lemurs/wms/i3. It launches i3, but does not set my keyboard map with setxkbmap
or load my .Xresources.
#!/usr/bin/env sh
setxkbmap us -option ctrl:nocaps 2>&1 > /tmp/lemurs.log
XDG_MENU_PREFIX=arch- kbuildsycoca6 2>&1 > /tmp/lemurs.log
xrdb -merge $HOME/.Xresources 2>&1 > /tmp/lemurs.log
exec i3
I'm wondering if it's because xrdb -merge .Xresources
needs to be run before starting the X server, and xsetup.sh is executed too late to take effect.
When I use X on my computer, I need to use the xresource "Xft.dpi" to adjust screen dpi. Using my shell to start xinit and then sourcing the files in my local xinitrc generally works fine, but as I am trying to adjust to this display manager I am finding that the Xft.dpi isn't being respected.
There is a file in my home dir as follows:
When I launch this setup, it is not sourced:
An inspection of the code leads me to believe that the file
/etc/lemurs/xsetup.sh
should run and directly source~/.Xresources
, which obviously is not happening.