I just did a MAJOR cleanup of main-x11 - I split the core X11 stuff out leaving main-x11.c as a more Angband Term centric file.
I managed to get rid of practically all of the global variables, apart from metadpy which is kind of a global 'Display' object, so not too fussed about that.
All that ugly xxx_set() crap is gone - side effect being a few more parameters to several functions, but now the code make more sense.
And I fixed the issue with Angband not remembering where you moved windows too - YAY!... BUT... there could be a problem...
Does anyone know what this is all about?
This:
was changed to this:
Now when a window is moved, X Windows generates a ConfigureNotify event which we pick up in CheckEvent(). The handler updates td->win->x and ts->win->y which USED to be saved to the x11 preferences file.
Long short short - if I revert the code, it works perfectly fine on my machine - Fedora, Mutter (Muffin). Question is, which window managers 'didn't work' which resulted in the nuking of a very useful feature?
I managed to get rid of practically all of the global variables, apart from metadpy which is kind of a global 'Display' object, so not too fussed about that.
All that ugly xxx_set() crap is gone - side effect being a few more parameters to several functions, but now the code make more sense.
And I fixed the issue with Angband not remembering where you moved windows too - YAY!... BUT... there could be a problem...
Does anyone know what this is all about?
Code:
/* * This doesn't seem to work under various WMs * since the decoration messes the position up * * Hack -- Use saved window positions. * This means that we won't remember ingame repositioned * windows, but also means that WMs won't screw predefined * positions up. -CJN- */
Code:
/* Window specific location (x) */ file_putf(fff, "AT_X_%d=%d\n", i, td->win->x); /* Window specific location (y) */ file_putf(fff, "AT_Y_%d=%d\n", i, td->win->y);
Code:
/* Window specific location (x) */ file_putf(fff, "AT_X_%d=%d\n", i, td->win->x_save); /* Window specific location (y) */ file_putf(fff, "AT_Y_%d=%d\n", i, td->win->y_save);
Long short short - if I revert the code, it works perfectly fine on my machine - Fedora, Mutter (Muffin). Question is, which window managers 'didn't work' which resulted in the nuking of a very useful feature?
Comment