Home liberachat/#xmonad: Logs Calendar

Logs: liberachat/#xmonad

←Prev  Next→ 184,733 events total
2024-06-17 12:13:17 × wsx quits (055e6b628d@2a03:6000:1812:100::dd6) (Remote host closed the connection)
2024-06-17 12:13:19 × alethkit quits (23bd17ddc6@sourcehut/user/alethkit) (Remote host closed the connection)
2024-06-17 12:13:19 × bwolf quits (c3bc363dd1@2a03:6000:1812:100::180) (Remote host closed the connection)
2024-06-17 12:13:19 × dxld quits (a6d27c8ee6@2a03:6000:1812:100::52) (Remote host closed the connection)
2024-06-17 12:13:19 × raghavgururajan quits (ea769b8000@user/raghavgururajan) (Remote host closed the connection)
2024-06-17 12:13:51 raghavgururajan joins (ea769b8000@user/raghavgururajan)
2024-06-17 12:13:52 wsx joins (055e6b628d@2a03:6000:1812:100::dd6)
2024-06-17 12:13:55 bwolf joins (c3bc363dd1@2a03:6000:1812:100::180)
2024-06-17 12:14:00 samhh joins (7569f027cf@2a03:6000:1812:100::e4)
2024-06-17 12:14:04 alethkit joins (23bd17ddc6@sourcehut/user/alethkit)
2024-06-17 12:14:04 dxld joins (a6d27c8ee6@2a03:6000:1812:100::52)
2024-06-17 12:14:04 eso joins (a0662dfd5e@2a03:6000:1812:100::1266)
2024-06-17 13:28:05 × weitcis quits (~quassel@syn-075-083-074-003.res.spectrum.com) (Ping timeout: 240 seconds)
2024-06-17 13:28:18 weitcis joins (~quassel@syn-076-082-169-160.res.spectrum.com)
2024-06-17 13:30:13 derfflinger_ joins (~derffling@user/derfflinger)
2024-06-17 13:34:15 × derfflinger quits (~derffling@user/derfflinger) (Ping timeout: 260 seconds)
2024-06-17 13:54:51 × derfflinger_ quits (~derffling@user/derfflinger) (Ping timeout: 268 seconds)
2024-06-17 14:05:25 × catman quits (~catman@user/catman) (Quit: WeeChat 4.3.0-dev)
2024-06-17 14:06:42 catman joins (~catman@user/catman)
2024-06-17 14:13:40 derfflinger_ joins (~derffling@user/derfflinger)
2024-06-17 14:37:57 × derfflinger_ quits (~derffling@user/derfflinger) (Ping timeout: 256 seconds)
2024-06-17 16:58:35 × cfricke quits (~cfricke@user/cfricke) (Quit: WeeChat 4.2.2)
2024-06-17 19:40:24 ft joins (~ft@p3e9bcb39.dip0.t-ipconnect.de)
2024-06-17 20:11:59 × Solitary quits (~Solitary@user/solitary) (Ping timeout: 264 seconds)
2024-06-17 20:22:40 Solitary joins (~Solitary@user/solitary)
2024-06-17 20:32:23 × Solitary quits (~Solitary@user/solitary) (Ping timeout: 260 seconds)
2024-06-17 20:39:08 Solitary joins (~Solitary@user/solitary)
2024-06-17 20:42:38 × Solitary quits (~Solitary@user/solitary) (Read error: Connection reset by peer)
2024-06-17 20:46:27 Solitary joins (~Solitary@user/solitary)
2024-06-17 21:05:23 × redgloboli quits (~redglobol@user/redgloboli) (Ping timeout: 264 seconds)
2024-06-17 21:06:49 × srk quits (~sorki@user/srk) (Ping timeout: 268 seconds)
2024-06-17 21:07:54 redgloboli joins (~redglobol@user/redgloboli)
2024-06-17 21:12:50 <haskellbridge> <iqubic (she/her)> How does XMonad track dynamic state when I reload via "xmonad --restart"?
2024-06-17 21:16:25 <geekosaur> it writes the state to a file and passes it to the next invocation via the command line
2024-06-17 21:17:33 <geekosaur> each chunk (persistent extensible state, layout state, stackset) is separately serialized and will be discarded if it can't be parsed (practically, this can only happen to the layout)
2024-06-17 21:27:42 <haskellbridge> <iqubic (she/her)> But if I change the layout hook, then the old state won't work correctly to describe the new layouts I have.
2024-06-17 21:28:17 <geekosaur> right, which means it won't be able to deserialize that part of the state, so the layout geets reinitialized with defaults instead
2024-06-17 22:10:50 <haskellbridge> <iqubic (she/her)> https://dpaste.com/7DK35KQXB
2024-06-17 22:11:58 <haskellbridge> <iqubic (she/her)> I have no idea how this works... If I'm in "Mirror tall" and I toggle to fullscreen and back, XMonad remembers that I was in Mirror tall. How does it remember that?!?!
2024-06-17 22:18:39 <geekosaur> the ToggleLayouts data constructor holds state. Running a layout or sending a message can replace the constructor with a new value
2024-06-17 22:18:59 <geekosaur> In this case, the value is a Bool indicating whether the layout is toggled or not
2024-06-17 22:21:34 <haskellbridge> <iqubic (she/her)> Does I assume the (|||) layout combinator just tracks the state of which layout I'm using.
2024-06-17 22:21:50 <geekosaur> yes
2024-06-17 22:22:02 <geekosaur> its constructor is Choose, which contains a Bool
2024-06-17 22:22:20 <geekosaur> hm, actually I think it uses a bespoke type which is either Left or Right
2024-06-17 22:22:43 <geekosaur> when the layout is initialized, all Choose constructors have Left
2024-06-17 22:23:30 <geekosaur> every time you mod-space, every Choose constructor checks its state: if it's Left then it changes the state to Right; if it's Right then it relays the message to its rightward layout
2024-06-17 22:23:57 <geekosaur> when a layout is run, Choose runs either its Left or Right layout depending on the state
2024-06-17 22:25:53 <geekosaur> (iirc "Left" and "Right" are actually called "CL" and "CR")
2024-06-17 22:26:27 <haskellbridge> <iqubic (she/her)> CL and CR are the constructors, yeah.
2024-06-17 22:28:39 <haskellbridge> <iqubic (she/her)> So, the "Toggle" layout remembers the state of the two layouts it lets me toggle between.
2024-06-17 22:29:06 <geekosaur> right
2024-06-17 22:29:23 <geekosaur> it's ToggleLayout Bool leftlayout rightlayout
2024-06-17 22:29:46 <geekosaur> if the Bool is True then it's toggled on and runs leftlayout, otherwise rightlayout
2024-06-17 22:30:26 <geekosaur> er, ToggleLayouts. "ToggleLayout" is the message constructor which toggles the Bool
2024-06-17 22:30:43 <haskellbridge> <iqubic (she/her)> Is there a way I can debug why a namedScratchpadAction isn't working for me?
2024-06-17 22:31:38 <haskellbridge> <iqubic (she/her)> Like, I have a list of scratchpads defined and I have a keybinding set for it. But invoking the keybinding doesn't seem to do anything.
2024-06-17 22:37:24 <geekosaur> did you remember to add namedScratchpadManageHook to the manageHook? that's a fairly common mistake (and I've made it myself 🙂 )
2024-06-17 22:37:40 <haskellbridge> <iqubic (she/her)> Uh... I don't think I did that.
2024-06-17 22:37:45 <haskellbridge> <iqubic (she/her)> What should that look like?
2024-06-17 22:37:48 <geekosaur> pass it the list of NamedScratchPads
2024-06-17 22:38:02 <geekosaur> , manageHook = namedScratchpadManageHook scratchpads
2024-06-17 22:38:20 <geekosaur> as usual use <> <+> or composeAll to combine it with other manageHooks
2024-06-17 22:45:36 <haskellbridge> <iqubic (she/her)> Yeah. I know how to add a ManageHook to my already existing manage hooks.
2024-06-17 22:52:24 <haskellbridge> <iqubic (she/her)> I just added it to my manageHook and it's still not working.
2024-06-17 22:59:37 <geekosaur> https://github.com/geekosaur/xmonad.hs/blob/hilfy-2023/xmonad.hs#L166-L179 (manageHook) https://github.com/geekosaur/xmonad.hs/blob/hilfy-2023/xmonad.hs#L223-L235 (keys)
2024-06-17 23:01:47 <haskellbridge> <iqubic (she/her)> I found the error. In the first argument for NS, I used uppercased the first letter of the name. In the keybindings I used all lowercase names.
2024-06-17 23:12:09 <haskellbridge> <iqubic (she/her)> This looks really wonderful. I'm loving this: https://imgur.com/a/LiffReW
2024-06-17 23:35:29 <haskellbridge> <iqubic (she/her)> Is there a way that I can write a simple function to create a centered RationalRect? Like "centered :: Rational -> Rational -> RationalRect" where I give it a width and a height in fractions of the screen size, and it works out where the top left corner should be for me, so that the rectangle is centered.
2024-06-17 23:35:38 <haskellbridge> <iqubic (she/her)> Or is that something that already exists?
2024-06-17 23:36:55 <haskellbridge> <iqubic (she/her)> I want something like "doCenteredFloat" but with the ability to specify a height and a width.
2024-06-17 23:42:27 <geekosaur> doesn't look like we have anything conveniently prepackaged, but you can derive it from the local function `move` that's part of https://hackage.haskell.org/package/xmonad-contrib-0.18.0/docs/src/XMonad.Hooks.ManageHelpers.html#doSideFloat
2024-06-17 23:43:03 <haskellbridge> <iqubic (she/her)> Cool. Thanks!
2024-06-17 23:50:26 <geekosaur> hm, you might also need https://hackage.haskell.org/package/xmonad-0.18.0/docs/XMonad-Operations.html#v:floatLocation
2024-06-17 23:53:04 <haskellbridge> <iqubic (she/her)> Hmm... yeah, maybe.
2024-06-18 00:00:56 <geekosaur> unfortunately that's the only place where we generate a RationalRect from a Rectangle; everything else goes the other direction (scaling a Rectangle according to a RationalRect)
2024-06-18 00:02:09 <haskellbridge> <iqubic (she/her)> Well, I'm just gonna be passing this RationalRect into "customFloat" to place my Named Scratch Pad.
2024-06-18 01:48:00 <haskellbridge> <iqubic (she/her)> Does something like this work for doing scratchpad manage hooks? https://dpaste.com/3E3T9BR7J
2024-06-18 01:49:16 <haskellbridge> <iqubic (she/her)> I just have to fiddle with the values to get something I like, but I think that should work.
2024-06-18 01:51:47 <geekosaur> it should
2024-06-18 01:52:23 <geekosaur> I think I have something in my scratchpads where I messed with numbers until I got it to work (actually I think I computed it by hand and then adjusted until it works)
2024-06-18 01:53:08 <haskellbridge> <iqubic (she/her)> I am just messing with these numbers until I get something that looks good to me.
2024-06-18 01:53:29 <haskellbridge> <iqubic (she/her)> But that should make the windows centered right?
2024-06-18 01:56:05 <geekosaur> it should, yes
2024-06-18 01:57:06 <haskellbridge> <iqubic (she/her)> Just checking that I got my math right.
2024-06-18 01:59:11 <haskellbridge> <iqubic (she/her)> Is 222 lines of xmonad config too much?
2024-06-18 02:00:15 <geekosaur> I have just over 450 😛
2024-06-18 02:01:24 <haskellbridge> <iqubic (she/her)> Will longer config mean slower WM?
2024-06-18 02:01:34 <geekosaur> not necessarily
2024-06-18 02:02:06 <geekosaur> if you have a lot of handleEventHooks or a large logHook, you may have issues
2024-06-18 02:02:37 <geekosaur> a large keymap, for example, won't slow things down because it's compiled to (possibly nested) maps
2024-06-18 02:03:07 <haskellbridge> <iqubic (she/her)> Also, I've noticed that named scratchpads only change their size after I restart xmonad and also kill the window. It's like the manage hook is only run at window creation time.
2024-06-18 02:03:13 <haskellbridge> <iqubic (she/her)> Is that intended?
2024-06-18 02:03:21 <geekosaur> yes
2024-06-18 02:03:31 <haskellbridge> <iqubic (she/her)> Got it.
2024-06-18 02:04:52 <haskellbridge> <iqubic (she/her)> Also, these named scratchpads are gonna be wildly useful. It's awesome to be able to just quickly open up a terminal and have a process run in the background. Or even just being able to open up Emacs and jot down a few notes!
2024-06-18 02:19:16 <haskellbridge> <iqubic (she/her)> Why do you have to explicitly add a manageHook for named scratchpads?
2024-06-18 02:26:59 <geekosaur> because the manageHook is what handles all newly-opened windows, so the mini-managehooks in the scratchpad definition need to be hooked into it
2024-06-18 02:28:34 <haskellbridge> <iqubic (she/her)> Right. I see.
2024-06-18 02:30:35 <geekosaur> if the keybindings were part of the scratchpad definition, we could use a single combinator to hook everything in

All times are in UTC.