Floating windows do not maintain position

Issue #48 resolved
Rahul Garg created an issue

Unless I have a misconfiguration, I cannot seem to get persistent positioning for floating windows. This should be relatively straightforward to reproduce.

I have attached my dkrc and sxhkdrc for reference (specifically line#86 in dkrc which sets the rule for Pavucontrol).

The expectation is that pavucontrol should always open at the specified location. It would be even better if I could specify something like:

dkcmd rule class="^Pavucontrol$" float=true center=true

and dk would honor the center=true value.

Comments (6)

  1. Nate Maia repo owner
    x=center y=center
    

    see the manual or readme on rules and positioning

    • x change the x coordinate, can be an integer or one of the following.

      • center left and right gravitate on the x coordinate.
    • y change the y coordinate, can be an integer or one of the following.

      • center top and bottom gravitate on the y coordinate.

    let me know if it doesn’t work

  2. Nate Maia repo owner

    Floating windows are intentionally arranged into a 3x3 grid as best as possible, so if you run floating and open a few windows dk does it’s best to not entirely overlap them (like having all of them in the center), rules avoid this. Also if a window specifies it’s location by remembering dk will respect it, many do, many don’t

  3. Rahul Garg reporter

    I noticed x=center and y=center right after posting the issue. That seems to work and thank you for explaining the 3x3 grid to avoid overlaps, that makes sense. Please consider this issue resolved!

  4. Log in to comment