Hello, On 2023/01/05 06:25:52 +0000, screwtape <screwt...@sdf.org> wrote: > Excuse me, after enabling UTF8 I noticed this funny behaviour that didn't > seem very good. In ~ the default fvwm xterm with rlwrap and xclip packages > from ports on both arm64 and amd64 > > $ printf "a\xe2\x98\xbdb" | xclip -i > $ rlwrap ed > <middle click> > > in contrast to > > $ printf "a\xe2\x98\xbdb" | xclip -i > $ ed > <middle click> > Which works as expected.
Works as expected for me: % printf "a\xe2\x98\xbdb" | xclip -i % rlwrap ed a☽b ? q % ed a☽b ? q Do you have a valid (UTF8) LANG set up *before* spawning xterm? Ideally as soon as .xsession should set it. I have: % env | grep -i lang LANG=en_US.UTF-8 that leads to % locale LANG=en_US.UTF-8 LC_COLLATE="en_US.UTF-8" LC_CTYPE="en_US.UTF-8" LC_MONETARY="en_US.UTF-8" LC_NUMERIC="en_US.UTF-8" LC_TIME="en_US.UTF-8" LC_MESSAGES="en_US.UTF-8" LC_ALL= > ed could be something else, I tried with rlwrap ecl and rlwrap sbcl. pkg_info > rlwrap lists ports@openbsd.org as the maintainer. Sorry if it was something I > caused myself, or the intended functionality. I doubt, ed is as simple as it can be, and rlwrap don't change its behaviour based on the wrapped program. I suspect an issue with your locale setup. May also be worth looking at which XTerm resources you've changed in .Xresources/.Xdefaults (if any.)