all repos — ryudo @ db9b136766e5a3b24ca87a9a2f3810c668ba4bf9

the floatiling window manager that flows; fork of rio from plan9port

fix microsleep and add config option; update manual; v1.4.1
Iris Lightshard nilix@nilfm.cc
PGP Signature
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEkFh6dA+k/6CXFXU4O3+8IhROY5gFAmPTE9YACgkQO3+8IhRO
Y5h4TA//aaXBKyJzqmDdiVfqWoXzKbI6exEvSnqod561KwVxi+KzB2uTdtnT6wya
UBPuHmgvfAH9NUes1MBGpw3JMmxxXrAkSFmulzf/TxBps+Ms0Ex1tGFT93QAulHh
JKdHeq0047b4hGTP4pyLkuJodeRbiQsSVVgyyuDRrxGFN+KhP3ZWDggQ/PuoJbPR
XZn2bYCAA9t7u0hfyvJxeyi786UBx65uN/qHz91TIoL/jUxUgZgvFiSVnMpVsa6u
DRioUZV2/8Yzgk/qdhMDyVi5iXK5vc9U04zkxNmSHGoV51Yrhm3u1WpL3KkIX5We
b/rlFEPOiYPvTG9iO/Sv7UjY+egL1OZH66hxfS1pbRx8w75e5grbslHDtBFLTmqT
itpXVzNDTpcsqv6ZPKYRYn1ZBUcNEI5Izx7zMGK6CxWp7pMpoiMc58jRr/N0tnkB
LsMjrx/b5Y/GTM/GCaphwOX7CFaNkKxavSeMWQE6jQ95NUxNuQAcj0Iq3Mi4nb4F
Q4K/Ffa9i0dqqCXkvrOEcgwBiKqLhaRnzEivA1/Rnw7zaW9Buv6jAgOKsYcpXhdk
Omwb6ko5lP5tZYwfFVGf3Jnc+Np5R/KBdsGqYlQ3/g1FFOFrnFZCZI9jVndxbm8E
Fp9Vn7o0IUxIb1S1cUGmCRRONDQVI3FJuhM9VFUmkX0eDo7Oaa8=
=qLGr
-----END PGP SIGNATURE-----
commit

db9b136766e5a3b24ca87a9a2f3810c668ba4bf9

parent

9612bd6ee2d7033ad66292cd817d1253f5a1567a

6 files changed, 33 insertions(+), 28 deletions(-)

jump to
M config.def.hconfig.def.h

@@ -54,6 +54,7 @@ #define TRANSPARENTLIST { \

"Alacritty", \ "kate", \ "acme", \ + "st-256color",\ 0 \ }

@@ -101,6 +102,12 @@ /************

* BEHAVIOR * [Everything in this section is optional unless otherwise noted] ***********/ +/* Microseconds to wait before centering terminal windows spawned by keyboard; + * if your system is wicked fast you can lower this; if very old/slow, you may + * have to raise it. + */ +#define MICROSLEEP_DELAY 100000 + /* This sets the size ratio for windows spawned via keyboard or * center-snapped; CENTERNUM should be >= 2, so use 2/4 instead of 1/2 */

@@ -146,6 +153,7 @@

#define AUTOSTICK {\ "XOsview", \ "XClock", \ + "xneralie", \ 0 \ }

@@ -156,6 +164,7 @@ * terminating lines!

*/ #define TERMINALS {\ + "st-256color", \ "term", \ "Term", \ "xvt", \
M event.cevent.c

@@ -18,6 +18,10 @@ #include "dat.h"

#include "fns.h" #include "patchlevel.h" +#ifndef MICROSLEEP_DELAY +#define MICROSLEEP_DELAY 100000 +#endif + void mainloop(int shape_event) { static XEvent ev; static Client* c;

@@ -212,6 +216,9 @@

void mapreq(XMapRequestEvent* e) { Client* c; int i; + XRRMonitorInfo monitor; + + monitor = monitorinfo[getmonitorbymouse()]; curtime = CurrentTime; c = getclient(e->window, 0);

@@ -233,6 +240,15 @@ return;

} } + if (kbLaunch) { + usleep(MICROSLEEP_DELAY); +#ifdef CENTERVMAX + centerclient(c, monitor, 1); +#else + centerclient(c, monitor, 0); +#endif + kbLaunch = 0; + } switch (c->state) { case WithdrawnState: if (c->parent == c->screen->root) {

@@ -298,9 +314,6 @@

void newwindow(XCreateWindowEvent* e) { Client* c; ScreenInfo* s; - XRRMonitorInfo monitor; - - monitor = monitorinfo[getmonitorbymouse()]; /* we don't set curtime as nothing here uses it */ if (e->override_redirect)

@@ -341,16 +354,6 @@ (unsigned char*)&opacity,

1); } #endif - - if (kbLaunch) { - usleep(100000); -#ifdef CENTERVMAX - centerclient(c, monitor, 1); -#else - centerclient(c, monitor, 0); -#endif - kbLaunch = 0; - } } void destroy(Window w) {
M main.cmain.c

@@ -22,7 +22,7 @@ #include "fns.h"

#include "patchlevel.h" char* version[] = { - "ryudo version 1.3.3\nCopyright (c) 1994-1996 David Hogan,\n(c) 2004 Russ " + "ryudo version 1.4.1\nCopyright (c) 1994-1996 David Hogan,\n(c) 2004 Russ " "Cox,\n(c) 2019-2022 Derek Stevens", 0};
M ryudo.1ryudo.1

@@ -1,7 +1,7 @@

.\" generated with Ronn/v0.7.3 .\" http://github.com/rtomayko/ronn/tree/0.7.3 . -.TH "RYUDO" "1" "March 2022" "" "" +.TH "RYUDO" "1" "January 2023" "" "" . .SH "NAME" \fBryudo\fR \- The floatiling window manager that flows

@@ -180,10 +180,7 @@ .

.IP "" 0 . .SH "BUGS AND CAVEATS" -Click events don\'t pass through when clicking to activate a window\. -. -.P -Clicking mouse button 2/3 on an inactive window brings up the Button 2/3 Menu instead of focusing the window\. I personally sometimes find this behavior useful\. +Switching very fast back and forth between virtual desktops may cause the window manager to stop managing some windows\. Still looking into why\. . .P Programs that expect to run fullscreen will probably just open in a window the size of whatever resolution they expect to run at\. Depending on the implementation, they may respond well to being maximized or you may have to change your screen resolution manually before doing so\. If the program expects to run at the current screen resolution, the window\-wrangling heuristics should maximize it and you\'ll be golden\. If the window is in override\-redirect mode, it should just run fullscreen without a hitch\.
M ryudo.1.htmlryudo.1.html

@@ -178,9 +178,7 @@

<h2 id="BUGS-AND-CAVEATS">BUGS AND CAVEATS</h2> -<p>Click events don't pass through when clicking to activate a window.</p> - -<p>Clicking mouse button 2/3 on an inactive window brings up the Button 2/3 Menu instead of focusing the window. I personally sometimes find this behavior useful.</p> +<p>Switching very fast back and forth between virtual desktops may cause the window manager to stop managing some windows. Still looking into why.</p> <p>Programs that expect to run fullscreen will probably just open in a window the size of whatever resolution they expect to run at. Depending on the implementation, they may respond well to being maximized or you may have to change your screen resolution manually before doing so. If the program expects to run at the current screen resolution, the window-wrangling heuristics should maximize it and you'll be golden. If the window is in override-redirect mode, it should just run fullscreen without a hitch.</p>

@@ -191,8 +189,8 @@

<h2 id="AUTHORS">AUTHORS</h2> <ul> -<li>Derek Stevens <a href="&#109;&#97;&#x69;&#x6c;&#x74;&#x6f;&#58;&#x6e;&#105;&#108;&#x69;&#x78;&#64;&#x6e;&#x69;&#108;&#102;&#109;&#46;&#99;&#99;" data-bare-link="true">&#110;&#105;&#108;&#x69;&#x78;&#x40;&#x6e;&#105;&#x6c;&#102;&#x6d;&#x2e;&#x63;&#99;</a></li> -<li>Russ Cox <a href="&#x6d;&#97;&#105;&#108;&#116;&#111;&#x3a;&#x72;&#x73;&#99;&#64;&#x73;&#119;&#116;&#x63;&#104;&#x2e;&#x63;&#x6f;&#x6d;" data-bare-link="true">&#114;&#115;&#99;&#64;&#x73;&#119;&#116;&#99;&#x68;&#x2e;&#99;&#111;&#x6d;</a></li> +<li>Derek Stevens <a href="&#109;&#97;&#x69;&#x6c;&#116;&#111;&#x3a;&#x6e;&#x69;&#108;&#x69;&#x78;&#x40;&#x6e;&#105;&#x6c;&#102;&#109;&#46;&#99;&#99;" data-bare-link="true">&#x6e;&#105;&#x6c;&#x69;&#x78;&#x40;&#x6e;&#x69;&#108;&#102;&#x6d;&#x2e;&#x63;&#99;</a></li> +<li>Russ Cox <a href="&#x6d;&#x61;&#105;&#108;&#x74;&#111;&#x3a;&#114;&#115;&#x63;&#64;&#x73;&#x77;&#116;&#99;&#x68;&#46;&#x63;&#x6f;&#x6d;" data-bare-link="true">&#x72;&#115;&#99;&#64;&#x73;&#x77;&#116;&#x63;&#104;&#46;&#x63;&#x6f;&#x6d;</a></li> <li>David Hogan, RIP</li> </ul>

@@ -204,7 +202,7 @@

<ol class='man-decor man-foot man foot'> <li class='tl'></li> - <li class='tc'>March 2022</li> + <li class='tc'>January 2023</li> <li class='tr'>ryudo(1)</li> </ol>
M ryudo.1.mdryudo.1.md

@@ -93,9 +93,7 @@ - `Center/Alternate` (Super + Shift + C): Center the currently active window (alternate geometry preference).

## BUGS AND CAVEATS -Click events don't pass through when clicking to activate a window. - -Clicking mouse button 2/3 on an inactive window brings up the Button 2/3 Menu instead of focusing the window. I personally sometimes find this behavior useful. +Switching very fast back and forth between virtual desktops may cause the window manager to stop managing some windows. Still looking into why. Programs that expect to run fullscreen will probably just open in a window the size of whatever resolution they expect to run at. Depending on the implementation, they may respond well to being maximized or you may have to change your screen resolution manually before doing so. If the program expects to run at the current screen resolution, the window-wrangling heuristics should maximize it and you'll be golden. If the window is in override-redirect mode, it should just run fullscreen without a hitch.