[xmonad] Accessing minimized windows in Xmonad.Layout.Minimize
adam vogt
vogt.adam at gmail.com
Thu Nov 15 00:15:28 CET 2012
On Tue, Nov 13, 2012 at 5:10 PM, Raghavendra D Prabhu
<raghu.prabhu13 at gmail.com> wrote:
> Hi,
>
> I am using Xmonad.Layout.Minimize with BoringWindows. When I minimize more
> windows, I would like to access them out of order than do one by one through
> RestoreNextMinimizedWin or restore from taskbar (I don't have taskbar,
> trayer + xmobar). Is there a way to hook it into Xmonad.Prompt or
> XMonad.Actions.WindowBringer etc.? It will also be helpful since if I
> forget which windows have been minimized.
Hi Raghavendra
To be able to restore and then bring, the function might look like:
bringRestored :: Window -> X ()
bringRestored w =do
broadcastMessage (RestoreMinimizedWin w)
windows (bringWindow w) -- or something else like
XMonad.StackSet.focusWindow
Then you could to hook up XMonad.Prompt doing something similar to
http://xmonad.org/xmonad-docs/xmonad-contrib/src/XMonad-Prompt-Window.html#windowPromptBring
to supply that Window argument. Using XMonad.Util.Dmenu is shorter but
might be broken depending on how your dmenu version matches up with
your contrib version. In any case you should get the idea of how it
can be done.
bringRestoredWindow = do
wm <- windowMap
w <- dmenu (M.keys wm)
whenJust (M.lookup w wm) bringRestored
--
Adam
More information about the xmonad
mailing list