Move Window doesn't raise window

Bug #695570 reported by Chow Loong Jin
34
This bug affects 5 people
Affects Status Importance Assigned to Milestone
compiz (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

  affects ubuntu/compiz
  subscribe smspillaz

When "Click to Focus" is enabled, and "Raise on Click" is disabled, using
Alt+Mouse1 (move window) does not raise the window. Compiz 0.8 raises the window
on Alt+Mouse1 though.

--
Kind regards,
Loong Jin

Tags: patch
Revision history for this message
Chow Loong Jin (hyperair) wrote :

This one-liner patch seems to do the trick.

tags: added: patch
Revision history for this message
Chow Loong Jin (hyperair) wrote :

Just so it doesn't get lost, the patch was forward-ported from compiz-0.8:

a32f5bf9 (Danny Baumann 2008-10-17 17:27:35 +0200 210) if (d->opt[COMP_DISPLAY_OPTION_RAISE_ON_CLICK].value.b)
a32f5bf9 (Danny Baumann 2008-10-17 17:27:35 +0200 211) updateWindowAttributes (w,
a32f5bf9 (Danny Baumann 2008-10-17 17:27:35 +0200 212) CompStackingUpdateModeAboveFullscreen);

Changed in compiz (Ubuntu):
status: New → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package compiz - 1:0.9.2.1+glibmainloop4-0ubuntu1

---------------
compiz (1:0.9.2.1+glibmainloop4-0ubuntu1) natty; urgency=low

  [ Didier Roche ]
  * New upstream release:
    - Fixed a high number of wakeups (LP: #681696)
    - Fixed links not working in some gtk windows
    - Raise the window when it is moved if raise on click is enabled
    - Fix crash when loading plugins on the command line
    - Fix focus issues on window close and reopen rapidly
    - Fix focus issues with multiple X screens
    - Glib plugin removed
    - Fix bug where not moving the mouse and clicking button 2 or 3 in
      scale addon would close the current active window, not the window the
      mouse hovers over
    - Add unity-window-decorator
    - Move window doesn't raise window (LP: #695570)
    - gtk.Label <a href> link-activate signal broken with compiz in natty
      (LP: #687732)
  * debian/patches/060_move_checks_to_compiz.patch:
    - remove GNOME failsafe detection as now handled as a session type in
      gnome-session
  * Remove deprecated or now merge upstream patches:
    - 01_backport_trunk_fix.patch
    - 002_ship_splited_gconf_cmakeext_files.patch
    - 004_packagemode_is_release_debug_for_plugins.patch
    - 005_no_glib_plugin.patch
    - 017_always_unredirect_screensaver_on_nvidia.patch
    - 080_migrate_gconf_from_alpha1.patch
  * debian/compiz-gnome.gconf-defaults,
    debian/patches/029_default_options.patch:
    - new settings for natty. Also set the 2x2 layout by default
  * unity-decorator:
    - debian/compiz-decorator:
      launch unity-compiz-decorator in gnome sessions
    - debian/compiz-gnome.install:
      install it
    - debian/control:
      depends on latest metacity having the right extension
    - debian/patches/01_unity_window_decorator.patch:
      add unity-window-decorator
  * debian/patches/02_add_debug_spewer_for_apport.patch:
    - new plugin (not activated for now) to get additional info for apport

  [ Bryce Harrington ]
  * compiz-core.install, compiz-core.links, source_compiz.py:
    Replace the compiz apport hook with a link to xorg's apport script.
 -- Didier Roche <email address hidden> Thu, 13 Jan 2011 21:50:27 +0100

Changed in compiz (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Tom Jaeger (thjaeger) wrote :

This bug has not been fixed. Alt+Click should raise the window unconditionally (just like clicking on the title bar does), irrespective of what 'raise-on-click' is set too. This was also the behavior of compiz-0.8. Patch is attached, please reopen.

Revision history for this message
Sam Spilsbury (smspillaz) wrote : Re: [Bug 695570] Re: Move Window doesn't raise window

On Sat, Mar 12, 2011 at 5:39 AM, Tom Jaeger <email address hidden> wrote:
> This bug has not been fixed.  Alt+Click should raise the window
> unconditionally (just like clicking on the title bar does), irrespective
> of what 'raise-on-click' is set too.  This was also the behavior of
> compiz-0.8.  Patch is attached, please reopen.

I won't accept this patch because click raise should be disabled for
both the window *and* the titlebar in the case that the option get
returns false and that should apply even when moving the window. If
the titlebar is also raising the window, then this is something that
needs to be fixed in the decorators (maybe I need to add an integrated
option key to gtk-w-d and unity-w-d for this case)

>
> ** Patch added: "0001-move-resize-Always-raise-the-window-on.patch"
>   https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+attachment/1902305/+files/0001-move-resize-Always-raise-the-window-on.patch
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/695570
>
> Title:
>  Move Window doesn't raise window
>
> Status in “compiz” package in Ubuntu:
>  Fix Released
>
> Bug description:
>    affects ubuntu/compiz
>    subscribe smspillaz
>
>  When "Click to Focus" is enabled, and "Raise on Click" is disabled, using
>  Alt+Mouse1 (move window) does not raise the window. Compiz 0.8 raises the window
>  on Alt+Mouse1 though.
>
>  --
>  Kind regards,
>  Loong Jin
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+subscribe
>

--
Sam Spilsbury

Revision history for this message
Tom Jaeger (thjaeger) wrote :

How is one supposed to raise a window then when 'click to raise' is
disabled if not by clicking on the title bar or by doing Alt+Click?

On 03/11/2011 09:48 PM, Sam "SmSpillaz" Spilsbury wrote:
> On Sat, Mar 12, 2011 at 5:39 AM, Tom Jaeger <email address hidden> wrote:
>> This bug has not been fixed. Alt+Click should raise the window
>> unconditionally (just like clicking on the title bar does), irrespective
>> of what 'raise-on-click' is set too. This was also the behavior of
>> compiz-0.8. Patch is attached, please reopen.
>
> I won't accept this patch because click raise should be disabled for
> both the window *and* the titlebar in the case that the option get
> returns false and that should apply even when moving the window. If
> the titlebar is also raising the window, then this is something that
> needs to be fixed in the decorators (maybe I need to add an integrated
> option key to gtk-w-d and unity-w-d for this case)
>
>>
>> ** Patch added: "0001-move-resize-Always-raise-the-window-on.patch"
>> https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+attachment/1902305/+files/0001-move-resize-Always-raise-the-window-on.patch
>>
>> --
>> You received this bug notification because you are a direct subscriber
>> of the bug.
>> https://bugs.launchpad.net/bugs/695570
>>
>> Title:
>> Move Window doesn't raise window
>>
>> Status in “compiz” package in Ubuntu:
>> Fix Released
>>
>> Bug description:
>> affects ubuntu/compiz
>> subscribe smspillaz
>>
>> When "Click to Focus" is enabled, and "Raise on Click" is disabled, using
>> Alt+Mouse1 (move window) does not raise the window. Compiz 0.8 raises the window
>> on Alt+Mouse1 though.
>>
>> --
>> Kind regards,
>> Loong Jin
>>
>> To unsubscribe from this bug, go to:
>> https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+subscribe
>>
>
>

Revision history for this message
Sam Spilsbury (smspillaz) wrote :

On Sat, Mar 12, 2011 at 11:03 AM, Tom Jaeger <email address hidden> wrote:
> How is one supposed to raise a window then when 'click to raise' is
> disabled if not by clicking on the title bar or by doing Alt+Click?

When click raise is disabled raise happens on a timeout. The way the
options works is confusing though, I agree - really there should be an
option for "raise on timeout" and it should be off by default.

>
> On 03/11/2011 09:48 PM, Sam "SmSpillaz" Spilsbury wrote:
>> On Sat, Mar 12, 2011 at 5:39 AM, Tom Jaeger <email address hidden> wrote:
>>> This bug has not been fixed.  Alt+Click should raise the window
>>> unconditionally (just like clicking on the title bar does), irrespective
>>> of what 'raise-on-click' is set too.  This was also the behavior of
>>> compiz-0.8.  Patch is attached, please reopen.
>>
>> I won't accept this patch because click raise should be disabled for
>> both the window *and* the titlebar in the case that the option get
>> returns false and that should apply even when moving the window. If
>> the titlebar is also raising the window, then this is something that
>> needs to be fixed in the decorators (maybe I need to add an integrated
>> option key to gtk-w-d and unity-w-d for this case)
>>
>>>
>>> ** Patch added: "0001-move-resize-Always-raise-the-window-on.patch"
>>>   https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+attachment/1902305/+files/0001-move-resize-Always-raise-the-window-on.patch
>>>
>>> --
>>> You received this bug notification because you are a direct subscriber
>>> of the bug.
>>> https://bugs.launchpad.net/bugs/695570
>>>
>>> Title:
>>>  Move Window doesn't raise window
>>>
>>> Status in “compiz” package in Ubuntu:
>>>  Fix Released
>>>
>>> Bug description:
>>>    affects ubuntu/compiz
>>>    subscribe smspillaz
>>>
>>>  When "Click to Focus" is enabled, and "Raise on Click" is disabled, using
>>>  Alt+Mouse1 (move window) does not raise the window. Compiz 0.8 raises the window
>>>  on Alt+Mouse1 though.
>>>
>>>  --
>>>  Kind regards,
>>>  Loong Jin
>>>
>>> To unsubscribe from this bug, go to:
>>> https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+subscribe
>>>
>>
>>
>
> --
> You received this bug notification because you are a direct subscriber
> of the bug.
> https://bugs.launchpad.net/bugs/695570
>
> Title:
>  Move Window doesn't raise window
>
> Status in “compiz” package in Ubuntu:
>  Fix Released
>
> Bug description:
>    affects ubuntu/compiz
>    subscribe smspillaz
>
>  When "Click to Focus" is enabled, and "Raise on Click" is disabled, using
>  Alt+Mouse1 (move window) does not raise the window. Compiz 0.8 raises the window
>  on Alt+Mouse1 though.
>
>  --
>  Kind regards,
>  Loong Jin
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/ubuntu/+source/compiz/+bug/695570/+subscribe
>

--
Sam Spilsbury

Revision history for this message
Tom Jaeger (thjaeger) wrote :

This is not correct. There is an option 'auto-raise' in the settings,
but it only works if 'click to focus' and 'raise on click' are both
disabled (this conceivably might be a bug, not that I think 'auto-raise'
is particularly useful).

This is not how it should be either. 'Raise on click' off means that
the user should have full control of the stacking order --- you raise a
window by clicking on its title bar. This is how every window manager
under the sun (including compiz!) implements 'raise on click'.

On 03/12/2011 09:06 AM, Sam "SmSpillaz" Spilsbury wrote:
> On Sat, Mar 12, 2011 at 11:03 AM, Tom Jaeger <email address hidden> wrote:
>> How is one supposed to raise a window then when 'click to raise' is
>> disabled if not by clicking on the title bar or by doing Alt+Click?
>
> When click raise is disabled raise happens on a timeout. The way the
> options works is confusing though, I agree - really there should be an
> option for "raise on timeout" and it should be off by default.

Revision history for this message
James Pharaoh (jamespharaoh) wrote :

This bug is very real and you can easily compare the difference in Metacity, which works fine.

The point is that the window manager is in charge of, for each window, the location, size and stacking. The title bar and window borders are one way to adjust all of these. Another way is to use the meta key. The meta key method is useful because it will work in any part of a window, making it faster to use and also possible when the title bar is hidden.

The problem is that while we can still control the position and size of a window using the meta key (meta+drag left for location, meta+drag middle for size, meta+click right for menu), the bring to top command has stopped working in compiz. This has normally been available with meta+click left.

This should work regardless of the click to raise settings, just as clicking on the title bar continues to work. The two are equivalent and should function the same. By holding the meta key you are specifically telling the window manager that you are talking to it and not to the application.

As I said, this can easily be seen working in Metacity. This is a blocker for me using unity. I love focus follows mouse precisely because of the ability to place windows exactly where I want them. Without this ability it takes longer to do so than it should.

Revision history for this message
Chow Loong Jin (hyperair) wrote :

On 20/10/2011 16:29, James Pharaoh wrote:
> This bug is very real and you can easily compare the difference in
> Metacity, which works fine.
>
> The point is that the window manager is in charge of, for each window,
> the location, size and stacking. The title bar and window borders are
> one way to adjust all of these. Another way is to use the meta key. The
> meta key method is useful because it will work in any part of a window,
> making it faster to use and also possible when the title bar is hidden.
>
> The problem is that while we can still control the position and size of
> a window using the meta key (meta+drag left for location, meta+drag
> middle for size, meta+click right for menu), the bring to top command
> has stopped working in compiz. This has normally been available with
> meta+click left.
>
> This should work regardless of the click to raise settings, just as
> clicking on the title bar continues to work. The two are equivalent and
> should function the same. By holding the meta key you are specifically
> telling the window manager that you are talking to it and not to the
> application.
>
> As I said, this can easily be seen working in Metacity. This is a
> blocker for me using unity. I love focus follows mouse precisely because
> of the ability to place windows exactly where I want them. Without this
> ability it takes longer to do so than it should.
>

This bug is fixed though. Alt+Click does raise the window, and I have been using
focus-follows-mouse since Natty. If not, you can configure both Raise Window and
Move Window to Alt+Button1 in ccsm, and click "Set keybinding anyway" or
something like that when the dialogue about the key binding conflict arises.
Then Alt+Click will do both things. This was the workaround I used in Maverick
before the bug got fixed.

--
Kind regards,
Loong Jin

Revision history for this message
James Pharaoh (jamespharaoh) wrote :

Sorry, I think my issue is with the fix, as well as the situation before.

In my case I have click to raise DISABLED but still expect META+CLICK to perform a raise, for the reasons mentioned above. I think the original fix for this bug stoped this situation from working.

To be honest I have just been playing with unity and it has locked up about three times in five minutes. The "2d" option seems to give me metacity as before which is working fine so far so I'm going to stick with that for now. I'll probably come back to this in six months when I do another upgrade and maybe sort it out myself then.

James

Revision history for this message
James Pharaoh (jamespharaoh) wrote :

Ok, I've bitten the bullet and implemented the missing behaviour. It requires a slightly different approach because we only want to raise on a click, not on a drag.

As I explained before, this behaviour is seen in other window managers, notably metacity, which compiz is supposed to be a drop in replacement for. In my previous comment I justified this raise behaviour with raise-on-click disabled. Basically the point is that this is a specific command to raise the window rather than a click intended for the application.

The patch is attached. I have a feeling it might need some modifications, possibly its behaviour could be disabled if raise-on-click is enabled. I am not sure that would make much difference practically.

I am really keen to get this in. It is absolutely a regression from the behaviour of metacity and this can be easily tested. Let me know if you need any more information, or if I need to create a new bug report or anything.

Revision history for this message
Tristan Schmelcher (tschmelcher) wrote :

FYI, setting Raise Window to Alt + Button1 and ignoring the conflict works fine for me.

Maybe Compiz should just set Alt + Button1 as the default for Raise Window?

Revision history for this message
lenooh (lenooh) wrote :

What about the other way around? I want to move a window (with alt+click) without raising it. I have focus follows mouse, so I click only when I want to raise. In my case alt+click should not raise window.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.