<snakedye>
I do see the error now, by setting the option, I triggered another event which would set the option and ...
<snakedye>
weird that it never manifested before. anyway now I know a great tool :)
<snakedye>
btw I did find a use for advertise_done. i use the event to generate the layout once all views are advertised.
<snakedye>
if a layout doesn't need to AdvertiseView it's useless but if it does it is nice.
snakedye has quit [Ping timeout: 240 seconds]
waleee-cl has quit [Quit: Connection closed for inactivity]
<wrkzk[m]>
this might just be me being stupid
<wrkzk[m]>
but I cant figure out how to remap caps to control
<wrkzk[m]>
in wayland, specifically river
<wrkzk[m]>
anyone been able to do this?
<novakane[m]>
wrkzk: you probably need to use XKB_DEFAULT_OPTIONS="ctrl:swapcaps"
<novakane[m]>
look at grep -E "(ctrl|caps):" /usr/share/X11/xkb/rules/base.lst to see some options
novakane has joined #river
maringuu has quit [Read error: Connection reset by peer]
maringuu has joined #river
yyp has joined #river
<novakane>
it would be great if pixman had some doc :/
Dedguy21 has joined #river
<Dedguy21>
What is the best bar to use with River, so far I have defaulted to Waybar, notice there's only one module for it, last time I was hear someone mentioned another bar
<Dedguy21>
Opps I'm sure most people are sleeping right about now
novakane has quit [Ping timeout: 250 seconds]
novakane has joined #river
<ifreund>
nope, it's 11am for me ;D
<novakane[m]>
Dedguy21: you can try yambar too
<ifreund>
I use waybar, though yambar also has support
<novakane[m]>
ifreund: hmm something I don't understand in zig, why this wouldn't work https://zigbin.io/7a38d8
<ifreund>
notEmpty() returns a c_int
<ifreund>
if you want to, improving zig-pixman to automatically do the != 0 would be nice
<novakane[m]>
really? reading pixman.zig I thought it returns a bool
<ifreund>
that's a pixman `const Bool = c_int`
<ifreund>
at least, iirc
<ifreund>
it's been a while
<ifreund>
you know what I'll do that real quick if you give me ~15 minutes
<ifreund>
should have converted to a bool from the start
<novakane[m]>
oh ok, damn I can't say I enjoy using pixman, they're litteraly no info in the source code :/
<novakane[m]>
in pixman.h I mean not pixman.zig
<novakane[m]>
sure no problem
<ifreund>
yeah, pixman has literally 0 docs, it sucks
<novakane[m]>
right? On their website it's said 'There is currently no documentation besides the source code itself.' but they're like 2 comments in it
<dnkl>
novakane[m]: they literally mean the source *code* ;)
<ifreund>
and the soruce code of pixman is not pretty :/
novakane has quit [Quit: WeeChat 3.1]
<novakane[m]>
dnkl : not super useful though without a bit more info
<dnkl>
novakane[m]: yeah, been there myself...
<dnkl>
with fcft, foot and fuzzel etc
<novakane[m]>
dnkl: I can imagine yeah, that's when you really understand why doc is so important :p
<ifreund>
either docs or readable code
<novakane[m]>
right, but some basic comment for not too obvious things can't hurt
Dedguy21 has quit [Quit: Connection closed]
<ifreund>
novakane[m]: zig-pixman bools should be nicer to use now
<novakane[m]>
ah yeah, well boring but really improve pixman
<novakane[m]>
I need to update where you used !=0 in river now though :p
<ifreund>
indeed, please do that in a separate commit
jaafarrc has joined #river
<ifreund>
you could even just open a PR for that right now updating zig-pixman
leon-p has joined #river
jaafarrc has left #river [#river]
<novakane[m]>
all right I'll do that
jaafarrc has joined #river
<jaafarrc>
How do I set the background?
<ifreund>
to an image? use swaybg or similar
<jaafarrc>
SwayBG can work without Sway? Awesome!
jaafarrc has quit [Quit: leaving]
<leon-p>
ifreund: I have finished porting contrib/layout.c, I'll push it today but first need to test it.
<ifreund>
\o/
<ifreund>
we're probably looking at a river-layout merge this evening then
<leon-p>
nice! I'll do the testing right now, if only I can find a way to get the patch from one laptop to the other...
<ifreund>
just throw the diff in a pastebin!
<ifreund>
then `git apply` on other laptop
<leon-p>
yeah, that's probably the easiest solution. Although I really should move to a place where I have control over the network
yyp has quit [Quit: now it's safe to turn off your computer]
<novakane[m]>
ifreund: so to be sure, if (var !=0) should become (var) and (var == 0) become (!var) or did I reverse it?
<ifreund>
0 means false and everything else means true
<ifreund>
so what you said is right
<novakane[m]>
ok thanks
<novakane[m]>
looks like there was only two place with this in PointerConstraint
<novakane[m]>
should be good, I'll open a PR
<leon-p>
ifreund: pushed the change.
<leon-p>
I am fairly confident that everything I worked on is done now.
<leon-p>
this PR has been open and worked on for almost half a year, it will be good to finally have it merged
<ifreund>
indeed, I've got some work work to do then I'll do the final pass and commit cleanup
snakedye has joined #river
jaafarrc has joined #river
waleee-cl has joined #river
jaafarrc has quit [Quit: leaving]
jaafarrc has joined #river
<jaafarrc>
Hey, sorry for joining and leaving so much, I'm here to ask a question.
<jaafarrc>
How do I bind something to a key like Print Screen?
snakedye has quit [Quit: Connection closed]
<leon-p>
jaafarrc: find out how XKB calls the key and then just use a mapping as normal.
<leon-p>
if you want the mapping to be without modifiers, use "None" as modifier string
<jaafarrc>
How do I find that out?
<leon-p>
honestly I have no idea. they are probably listed somewhare. Although I faintly remember that print screen is called just "Print".
<ifreund>
they are listed in /usr/include/xkbcommon/xkbcommon-keysyms.h
<ifreund>
(if you have the headers for xkbcommon installed of course)
<jaafarrc>
Yeah, I tried it, and it doesn't work. To make matters worse, the command that was supposed to be stared for "Print" just runs upon starting river.
<jaafarrc>
s/stared for/binded to/
<leon-p>
sounds like a config error
<jaafarrc>
ifreund: Oh, cool, I'll check that.
<leon-p>
paste it online somewhere and I'll have a look
<jaafarrc>
leon-p: Just hold on for a second.
<jaafarrc>
I'm taking a look at the header file ifreund mentioned.
<leon-p>
the problem is that $(slurp) will be executed not when the mapping is called, but when the mapping is created
<emersion>
you cvan use xev or wev to find out the keysym name
<emersion>
can*
<jaafarrc>
I already have used xev before, back when I used X11, and it told me: Print Screen is just "Print".
<ifreund>
Print is correct
<jaafarrc>
But I've never heard of wev.
<ifreund>
the problem is that you need single quotes around the command passed to spawn
<jaafarrc>
I'll try that.
<ifreund>
spawn 'grim -g "$(slurp)"'
<leon-p>
jaafarrc: you need to escape that or quote the entire command you want river to spawn. The problem is that the shell running your startup script is interpreting the $(slurp).
novakane65 has joined #river
<jaafarrc>
Alright, thanks, guys! I got it working. 'grim -g "$(slurp)"', as suggested by ifreund, works the best.
<jaafarrc>
Btw, why do my GTK apps not use their proper themes under Wayland? It only works on X.
<leon-p>
how do you set the theme? If you do it with gsettings it should work fine
<jaafarrc>
With config files.
<leon-p>
yeah, that will not work. Use: gsettings set org.gnome.desktop.interface gtk-theme <theme-name>
<leon-p>
note that you only have to do that once, the change will be kept in the dconf databse
<leon-p>
also note that it is possible (and pretty easy) to crash GNOME with bad dconf values, so if you want to run GNOME, be a bit careful
<leon-p>
(it's quite an interesting issue actually: GNOME/mutter does not santiy check what is in dconf, so if for example you tell it to load a cursor theme which has missing cursors, mutter tries to do so, fails and crashes. I guess the GNOME devs think that because dconf is not exposed directly to the user, only through their interface, that they can do the sanity check in the config client instead of the
<leon-p>
compositor itself. Not sure I agree with that, but it is not an issue the average user would ever encounter)
<jaafarrc>
Do I have to restart Wayland for gsettings to take effect?
<leon-p>
no
<leon-p>
you should see the change immediately
<jaafarrc>
Well, that means I'm doing something wrong.
<jaafarrc>
I start Firefox after running that commands and it is still a bright, blaring light theme.
<jaafarrc>
When I use a custom dark one.
<leon-p>
well, firefox isn't a typical gtk application
<leon-p>
firefox is special in all the wrong ways
<leon-p>
I think there is some dconf switch for setting a dark theme preference system wide (good gtk themes these days have both a dark and light version build in and you are supposed to use the switch). Firefox likely respects that.
<jaafarrc>
Hmmm... Well, I can't really use any other GTK app to test it out; since I (intentionally) don't have Xwayland installed. Why do my GTK apps still can't use Wayland even though they're GTK, you might ask? Well, that's a whole other story.
<leon-p>
they can?
<leon-p>
I still use a few and they are all wayland native
<leon-p>
gtk3 that is. gtk2 will never run on natively wayland
<jaafarrc>
Well, the reasons are specific to the GTK apps that I have. GIMP still doesn't have it because it's buggy or something, and Flowblade doesn't have it, despite the fact that is 100% GTK3.
<jaafarrc>
s/is/Flowblade is/
<leon-p>
gimp definitely is still gtk2. The gimp git master is mostly ported to gtk3 and is mostly wayland native. I don't know the other program though.
<jaafarrc>
I already knew that about GIMP.
<leon-p>
in that case you'll have to keep on using xwayland for gimp until the next major release
<jaafarrc>
That's obvious.
<jaafarrc>
Well, uh, I still don't know why my command doesn't work.
<leon-p>
probably because you are using special fancy pants "apps" that like to do their own thing, not traditional gtk programs
<jaafarrc>
-._^.
<jaafarrc>
Well, I'm gonna try using lxappearance; that never failed me.
<leon-p>
tbf visual consistenty is a lost cause anyway
<jaafarrc>
LXAppearance doesn't seem to be GTK2, so, scratch that.
<leon-p>
I am pretty sure gtk2 does still use the config file (.config/gtk-2.0/gtkrc-2.0) instead of dconf
<jaafarrc>
Not even I use dconf.
<leon-p>
lxappareance does overwrites that file, so it may work
<leon-p>
jaafarrc: dconf is like dbus. You'll use it whether you want or not :)
<jaafarrc>
I use .config/gtk-3.0/settings.ini and ~/.gtkrc-2.0.mine.
<leon-p>
yes, when running on wayland gtk3 mostly ignores the config file
<jaafarrc>
Why?
<leon-p>
because the gtk developers apparently prefer dconf over config files. and to be honest, for a system designed to be used by non technical people they may be right.
<leon-p>
dconf just works better with graphical setting things
<leon-p>
obviously that is a bit annoing if you, like me, prefer to have a somewhat consistent system and like config files
<jaafarrc>
Ugh.
<leon-p>
for myself I solved the problem by just containerizing all those gtk programs. They would not integrate to well if installed directly anyway, so flatpak it is. UX is the same, but it just feels a bit better to know everything is neatly contained :P
<jaafarrc>
Why do we have Flatpak/Snap/AppImage anyway? Can't we just compile an app and statically-link all of its binaries? Or is it about loading external data like PNGs or audio or whatever?
<leon-p>
because reasons.
<leon-p>
I'll be honest: I don't like the use case for flatpak. I really don't. But for that use case it is the best solution and the technology is fine.
<leon-p>
also not everything can be linked statically. famously glibc can't be, but also stuff like opengl isn't really intended for that.
<jaafarrc>
I knew about Glibc, but why not? Why causes any library in general to be unsafe for static linking?
<jaafarrc>
s/Why causes/What causes/
<leon-p>
no idea, to be honest.
<jaafarrc>
I should type slower.
<leon-p>
my use for flatpak really is just to separate my main system, which I can keep neat and clean, from all those "lone wolf" type of applications that don't integrate into the desktop anyway and spill their files everywhere. Also it automatically uses bubblewrap for all the applications, and I am somewhat lazy, so that's a plus in my book.
<jaafarrc>
That reminds me of how cluttered my ~/.config is.
<jaafarrc>
Anyway, I'll just live with this for now.
jaafarrc has quit [Quit: leaving]
<novakane[m]>
so do you guys prefer screen flickering or freeze? that's my options with damage tracking :p
novakane65 has quit [Quit: Connection closed]
<leon-p>
I think screens are big enough these days that we could comfortably have both
<ifreund>
:D
<novakane[m]>
sounds cool, I'm gonna make a PR to have flickering and freeze then :p
<novakane[m]>
ifreund: hope you merge it right away :p
<skuzzymiglet>
dnkl: why does foot use xmalloc and xsnprintf? (a quick search tells me these abort on failed malloc)
<dnkl>
skuzzymiglet: it uses those in situations where it doesn't make much sense to do anything else
waleee-cl has quit [Quit: Connection closed for inactivity]
waleee-cl has joined #river
<ifreund>
river-layout is merged! every have fun updating your configs
<ifreund>
*everyone
<novakane[m]>
Yeah! Congratz
<leon-p>
nice!
<leon-p>
I see you managed to squeeze everything into just 4 commits
<ifreund>
Yeah, I decided the incremental commits weren't really worth keeping as they were a little all over the place and some didn't compile
<ifreund>
hope you're happy with what my hour long rebase session came up with :D
<leon-p>
I think it turned out great. I feared the incremental commits weren't squashable, but you managed to do it anyway
<ifreund>
yeah it just took some time and good understanding of `git rebase -i`
<ifreund>
the tricky part was keeping the river-options-v2 commit separate
<leon-p>
I heard zig 0.8.0 is close as well, so rivers first release is close
c7s has joined #river
<ifreund>
zig 0.8.0 is targeted for may 31, so over a month still
<ifreund>
which is good because I haven't fixed that glibc issue upstream yet
<leon-p>
over a month is still pretty close :P
<leon-p>
but enough time to start prting the config commands to river-options
<ifreund>
yeah, definitely want to get that done before release
<leon-p>
should the config options be part of OptionsManager or Config?
<ifreund>
Config would probably be more appropriate tbh
<leon-p>
Isn't Config init'd before OptionsManager? So we either need to rearrange that or add some sort of createOptions() function to Config
<ifreund>
With how river-options-v2 shaped up we also need to consider whether we really want to support e.g. different border color for for different outputs
<leon-p>
yeah, I noticed it as well. Currently it would be trivial though
<leon-p>
but if people want things like different keyboard repeat rates per output it will get a bit messy
<ifreund>
Yeah I see no reason to support that kind of thing
<leon-p>
huh, actually in Output.handle{Layout,Title}Change(), why do we test is value is .string? Should that not be guarenteed?
<ifreund>
indeed, that should be an assert
yyp has joined #river
snakedye has joined #river
<snakedye>
Congratulations on the recent merge 🎉
<skuzzymiglet>
has the default layout for river changed? I see the layout system changed, and it seems to have affected my config
<leon-p>
to get around it, either use the workaound by qiu, or run river inside another compositor (I'd use cage)
<jaafarrc>
What did ifreund say the problem was again?
<jaafarrc>
qiu?
<leon-p>
a person in the github issue thread
<leon-p>
the issue was something in wlroots affecting every non-damage tracking compositor
<jaafarrc>
So qiu made a fork, basically?
<jaafarrc>
Hmmm, I'd just go with Cage.
<leon-p>
note that cage by default does not allow you to swtitch VTs, you have to explicitly enable that
<jaafarrc>
WHAT?
<leon-p>
cage is a kiosk compositor, so obviosuly it is going to be a bit restrictive, hence the name
<jaafarrc>
Uhh, bit of a problem with cage, it assumes I have Xwayland installed, when I actually don't.
<leon-p>
if you build it from source, you can disable xwayland support.
<leon-p>
Although it totally should be optional even if compiled with xwayland support
<jaafarrc>
Oh my God, WHY???!!!!
<leon-p>
anyway, scratch cage. I just tried it and immediatly experienced the same freeze issue.
<leon-p>
it's logical, actually: the issue bubbles up when you commit an output buffer often, which we in river do because we don't track damage. When you run river in cage, river makes cage commit that often as well (perhaps even via direct scan out?), so it makes sense that the issue persists...
<leon-p>
I wonder about running river in sway, I never had it freeze there when testing.
<jaafarrc>
Hmmm, maybe I could do that.
snakedye has quit [Quit: Connection closed]
<leon-p>
jaafarrc: for reference, what's your hardware?
<jaafarrc>
What kind of info are you looking for?
<jaafarrc>
I've got an Intel i7-8550U CPU, an NVIDIA GeForce MX130 dGPU, and an Intel UHD Graphics 620 iGPU. My computer prefers to use the latter GPU 100% of the time.
<jaafarrc>
And, again, I am doing all of this with no drivers, not even Intel.
<leon-p>
yes, you have drivers for intel, they are in the kernel.
<jaafarrc>
My OS is Artix Linux.
<leon-p>
huh, so one other person who has this issue also has a UHD 620
<jaafarrc>
leon-p: In the kernel? Cool, I guess.
jaafarrc has quit [Quit: leaving]
<leon-p>
so... if I am not mistaken, everyone affected uses an integrated intel graphics chip? Possibly on a laptop?
jaafarrc has joined #river
<jaafarrc>
Hey, I'm back.
<novakane[m]>
leon-p: I thinks so yeah
<leon-p>
I am sure that means something, I am just not sure what :D
<jaafarrc>
*What* does mean something?
<leon-p>
that apparently everyone who is affected by the freeze uses intel integrated graphics, apparently on a laptop
<novakane[m]>
it means you can't use nvidia, you can't use intel, we gonna need to build something special wayland :p
<leon-p>
well, ifreund uses an amd card and apparently never has experienced the freeze, so...
<jaafarrc>
I thought NVIDIA was fine as long as you were using nouveau.
<leon-p>
depends on your card. nouveau does not work that well with newer hardware because of nvidias greed^W buiseness decissions
<novakane[m]>
yup.. I don't know if there is a lot of laptop with amd card
<jaafarrc>
I don't understand the ^W reference, here; don't we usually use ^C?
novakane has joined #river
<leon-p>
^W in emacs/readline commands means deleting the previous word
<leon-p>
(just don't try in your browser :P)
<jaafarrc>
I already know how it works in Firefox. xD
<novakane>
I don't see jaafarrc message when I use matrix, it's really confusing
<jaafarrc>
Matrix completely fucked with my IRC nick; never again.
<novakane>
jaafarrc: that's weird you're the only one that I can't see
<jaafarrc>
I guess Matrix just hates IRC me.
<waleee-cl>
leon-p: ^W is portable, it works in vim's insert mode too
leon-p has quit [Quit: leaving]
jaafarrc has quit [Quit: Quit]
n8r has joined #river
novakane has quit [Quit: WeeChat 3.1]
<ifreund>
not in kakoune's insert mode :D though it does work in kakoune's command prompt along with other readline bindings