This is an automatically generated e-mail. To reply, visit: http://git.reviewboard.kde.org/r/104070/

On March 30th, 2012, 8:35 a.m., Martin Gräßlin wrote:

ah sorry for the late reply here on reviewboard.

In general I think it is very inconsistent to only add Left/Right. If we change this it has to become more generic. Why not just the left edge (right edge for synergy)?

If we go for a everything configurable approach the current approach for implementing it won't scale at all. If we don't go for a generic approach and accept it we have to ask ourself what this should help. It looks like a solution for a specific usecase.

Maybe it would be better to think about other solutions. Maybe window rules to block a screenedge? Maybe KWin scripting support for screen edges?
Thomas proposed an alternative @ https://git.reviewboard.kde.org/r/104073/ which generated a long discussion in the mailing list.  The gist of it is I'll be attempting to implement global shortcuts as custom screen edge actions.  Thomas opposed my patch (this one) as too specific to the virtualbox/KRDC use-case.  I contend that virtualization/remote access is a large affected user-base, but I have no numbers to support that claim.

In the meantime, I've continued using my patch, which works flawlessly.  There is no simple alternative for use of fullscreen virtualbox or KRDC with desktop edge switching.  Virtualbox and KRDC only offer their pop-out toolboxes on the upper or lower edges, which prompted my implementation of left/right only.  Note that Left/Right only mode as I implemented it ensures all desktops are reachable by using "Previous Desktop" and "Next Desktop" functions instead of "Desktop to the Left" and "Desktop to the Right".

Left/Right only also matches the default switching modes of the 3-D effects.  Existing KWin switching action ignores the switching effects' settings.

From my perspective as a virtualization end-user, I greatly prefer my solution due to its simplicity.  One setting in one obvious place ensures full functionality.  Only one new UI string, too.

I considered window rules to block screen edges, but that idea requires continuous maintenance to ensure the correct windows are identified, and even then, some desktops could become unreachable.

KWin scripting sounds like an attractive alternative to a complex selector for custom actions, but does lack the simplicity of a single obvious setting.

- Philip


On February 24th, 2012, 6:14 p.m., Philip Turmel wrote:

Review request for kwin.
By Philip Turmel.

Updated Feb. 24, 2012, 6:14 p.m.

Description

This patch exposes another choice in the system setting for screen edge
switching: "Always Enabled, Left/Right Only"

When selected, desktop switching only reserves the "electric borders" for the
left and right edges, and performs switching without regard to the pager
layout.  The settings UI is adjusted to allow custom actions on top & bottom
edges in this case, or pass through to applications.

Permits other applications, like virtualbox or various remote desktop
solutions to use the top or bottom screen edge hot spots for their own
purposes.

Testing

This applies to and works against kwin-4.8.0 on my gentoo laptop.  (The patch
is applied locally by placing in /etc/portage/patches/kde-base/kwin-4.8.0, for
those gentoo folks who are interested.)
Bugs: 293011

Diffs

  • kwin/desktoplayout.cpp (7578559)
  • kwin/geometry.cpp (7f36586)
  • kwin/kcmkwin/kwinscreenedges/main.cpp (1819459)
  • kwin/kcmkwin/kwinscreenedges/main.ui (759f896)
  • kwin/options.h (9dc29cf)
  • kwin/screenedge.h (cf08164)
  • kwin/screenedge.cpp (9734a1e)
  • kwin/workspace.h (092b6a7)
  • kwin/workspace.cpp (b4fd277)

View Diff