Re: FVWM: Invoking a menu for a window through a function

From: Mikhael Goikhman <migo_at_homemail.com>
Date: Wed, 1 Jan 2003 12:22:20 +0000

On 01 Jan 2003 12:51:25 +0100, Marcus Lundblad wrote:
>
> I have the following definitions
>
> # for the title bar buttons:
> Mouse 0 1 A Window-Menu-Func
> Mouse 0 2 A Maximize-and-Raise-toggle
> Mouse 0 4 A Iconify
>
> and
>
> AddToFunc Window-Menu-Func
> + I Current (HasHandles) Menu Window-Menu Interior 0 0 Close
> + I Current (!HasHandles) Menu Window-Menu-No-Handles Interior
> 0 0 Close
>
> This works, but only for windows that can take focus. When clicking the
> menu button on for example fvwm tear-off menus or xclock, nothing happens.

You probably use MouseFocus. With SloppyFocus you would not see
"nothing happens".

> I also set
> Style * Lenience
>
> but this doesn't help.
>
> Is it not possible to use Current to achive this?

Current works on the currently focused window, not on the pressed window.
All decoration/window based bindings are executed in the window context,
to use it there is ThisWindow conditional.

  ThisWindow (HasHandles) Menu Window-Menu Interior 0 0 Close

Regards,
Mikhael.
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Wed Jan 01 2003 - 06:23:45 GMT

This archive was generated by hypermail 2.3.0 : Mon Aug 29 2016 - 19:37:54 BST