You can switch in a direction!

BridgeWhen I posted yesterday’s squib, I really didn’t expect six people to say they’d use it. Someone plaintively left a message on the bug saying “Please make it possible for devilspie to add this feature!” Well, it is possible for devilspie or any other addon to add this feature, and for that reason it’s not a big difficulty to write it as an external script.  As an added bonus, it should work with Compiz or KWin or any other EWMH-aware window manager.

To play with the script:

  1. Download the current version from GNOME bug 152661.
  2. Put it in your path as metacity-direction.
  3. Install X11::Protocol by typing:
    sudo cpan X11::Protocol
  4. Open gconf-editor and set /apps/metacity/keybinding_commands/command_n, where n is any set of four unused values, to:
    metacity-direction e
    metacity-direction s
    metacity-direction w
    metacity-direction n
  5. Set /apps/metacity/global_keybindings/run_command_n to an appropriate set of values, like “<Shift><Alt>Right”, etc.
  6. Enjoy.

The algorithm is supposed to be the same as fvwm’s, but if you have suggestions for tweaking it, let me know.  The program should also demonstrate how to do fun EWMH things from Perl.

Photo (c) Katie Sutton, cc-by-nc-sa.

Squib of the day: prefix system for keybindings

Old ad, with Prefixes for phone numbersIn GNOME bug 310842 the suggestion is raised that there should be an option to require all keybindings to be prefixed with a particular keystroke, to minimise the number of keystrokes which can’t be used by applications– there would be only one keystroke, the prefix, that was globally grabbed.  Such a system would be reminiscent of ctrl-A in GNU Screen or ctrl-T in ratpoison.  The default would be to keep things the way they are, of course.

It’s certainly doable, but would this be of use to anyone in the real world?  Do any of you fancy justifying this idea?

Photo © Lauren, cc-by-nc-nd.

Squib of the day: move in a direction

ma quando sono gentili le bobbiesIn GNOME bug 152661 someone is asking for the ability to move in a particular direction from a given window (as opposed to from a given workspace).  So you could move to the closest window to the right of the focussed window, for example.  Apparently FVWM has this feature.  (I assume this would be an unbound keybinding by default.)

I really don’t see why this feature would be useful to anyone.  Would anyone care to try to justify its inclusion before I close the bug?

Photo © lavalen, cc-by-sa.

Metacity Journal: 2009-01-27

Your chronicler is once again reminded to overhaul this script. Those who are reading this from other projects– would you be interested in a copy when it’s more polished?

Bugs

As ever, feel free to join these conversations.

  • GNOME bug 171174 Xephyr crash– is this still a problem?
  • GNOME bug 437910 option to switch resize/menu keys, often asked for; will someone test this patch who isn’t Thomas?
  • GNOME bug 475038 applications should open on the workspace you launch them from
  • GNOME bug 504729 alt-tab speed (today’s squib)
  • GNOME bug 518712 not sure I understand this well enough to summarise; some GL problem with the compositor
  • GNOME bug 521914 switch to using Zenity– research continues on how to replicate current behaviour; today, transience
  • GNOME bug 531512 someone thinks freedesktop should move EWMH efforts onto dbus
  • GNOME bug 549886 refactoring of window property handlers completed; some more optimisation is certainly possible, though
  • GNOME bug 569289 metacity’s desktop file should ask for it to be restarted automatically
  • GNOME bug 569366 too many expose events when switching desktops

Inbox Zero

1 day passed from when there were 447 bugs; there are still 445 from yesterday, because new ones have been opened in the meantime; if this continues we will need 7 months. Still on target, though.

Checkins on trunk

Links

A bit short on links this time.  Post something in your own blog about Metacity– either something you’ve read here or something you come up with independently– and we’ll notice and (probably) link it here.  And it’s always good when people link us so we get more readers joining in discussions: link away!

Till we meet again, gentle reader, farewell.

Photo: The Cricketers, St Albans. Photo by Gary Houston, public domain.

Squib of the day: speed up alt-tab under compositing

Light Switch ComplicatorGNOME bug 504729 suggests that switching with alt-tab, while using compositing, is too slow. This is because all the images of the windows are scaled on the client side before the window is displayed.

There are two possible answers to this problem.

Firstly, we can check for key release while scaling is happening, and if one is received, abort scaling and simply switch to the next application.

Secondly, scaling can be faster if it’s done server-side.  This is possible but apparently there’s a common bug that it hits.  Fixing this would also mean that we got to have animated previews easily.

I think the first solution should be added in any case, and the second should be added when it’s possible.  I can add the first solution; I’m not sure I know enough to fix the second.

Photo © L. Marie, cc-by.

Exposé, part two

Light Strikes #  104Quick on the heels of our previous post on this matter, and Iain’s explanation of how it can be done in an external process and spawned on a keypress, malept points out Skippy, a program to do just that.  However, it appears to be unmaintained.  Does anyone fancy picking up the reins?  Possibly there should be some Metacity-specific tweaks, like being able to un-Skippy by pressing the same key you used to launch it.

I think the existence of Skippy is good enough reason to close the bug.  If anyone wants an Exposé-like effect, they should be able to install Skippy and tell Metacity about it without much effort.  Perhaps some distros might even ship them together.  If we had an FAQ, this should go in the FAQ.  Maybe I’ll write an FAQ.

(Yes, the same principle can in theory be used to get the rotating cube effect.  No, I don’t want to write it.  But since it can be an external program, there’s absolutely nothing stopping someone else writing it and then I’ll post about it here!)

Photo © Taylor James, cc-by-nc-nd.

Squib of the day: Exposé

ExposeIn GNOME bug 502491 someone is asking for an effect like Exposé on OS X.  Iain, who wrote the compositor and ought to know, believes it would be better done as a separate program.  There was an attempt to do this a while back, called Expocity, but nothing much came of it.  Does this mean the bug is INVALID?  Should the external program exist?  Anyone fancy doing it?

Includes the memorable exchange:
“Every time I propose an enhancement, you say ‘go for it’.  What are you doing?”
“I’m cooking my dinner.  What are you doing?”

If it was a separate program, it could be activated by a mouse button or a keybinding in the same way that, say, Print Screen is currently activated.  The program could move windows about using the EWMH, but I don’t see how an external utility could tell the compositor to scale the contents of windows down and back again.  Iain, can you throw me a clue? Update: Thanks.

Someone said yesterday in the discussion on animated previews in the alt-tab switcher that an Exposé-like effect would be good for everything that animated previews would, and more.

Photo © Underpuppy, cc-by-nd-sa.

Metacity Journal: 2009-01-25

The Inn on the Park, St Albans. Photo by Gary Houston, public domain.Your chronicler attempted to produce this version of the Metacity Journal using the old script; however, it had not run for so long that it listed hundreds of changes. Therefore it was largely pared down by hand, and only the changes from the last few days have been mentioned. If you’d like to dive in on any of these discussions, please do so!

Bugs

  • GNOME bug 567757 – live preview in alt-tab – the current bug of the day
  • GNOME bug 425899 – clock swings confuse resizes. _NET_WM_MOVERESIZE_CANCEL is now in trunk, but the reporter says that doesn’t fix the problem.
  • GNOME bug 553981 – patch was committed ages ago, should have been closed
  • GNOME bug 526723 – also fixed ages ago
  • GNOME bug 339692 – possibly a struts issue
  • GNOME bug 555909 – should the frontmost transient get focus by default? (Yes.)
  • GNOME bug 445479 – edge resistance is currently in pixels; should really be in millimetres
  • GNOME bug 475038 – the launcher should be telling us on which workspace a program should appear
  • GNOME bug 513866 – does anyone know how to make keybinding translations work?
  • GNOME bug 437910 – switch resize and menu buttons; patch written; will probably go in

Tobias Mueller has been very helpfully closing bugs which are INCOMPLETE.

Inbox Zero
0 days passed from when there were 447 bugs; there are now 445; if this continues we will need 7 months. On target.

Checkins on various branches

There’s been some work on veracity (a test system), and a few other “labs” ideas, checked into svn branches. Veracity will need to be working before some of the bugs we currently have can be closed.

    Checkins on trunk

      Links
      Too many to list this time.

      Photo: The Inn on the Park, St Albans. Photo by Gary Houston, public domain.

      Squib of the day: Live previews in alt-tab

      True to my promise, here’s the first bug/squib of the day.

      In GNOME bug 567757 someone is asking for live previews in the alt-tab window.  I can’t think why this would actually be useful, as opposed to pretty, and it sounds like a lot of work and a source of new bugs.  I am therefore minded to say no.  Can anyone think of why it might be worth the trouble?

      Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported
      This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported.