diff --git a/XMonad/Util/Hacks.hs b/XMonad/Util/Hacks.hs index 0c5fa8af..56f5c48d 100644 --- a/XMonad/Util/Hacks.hs +++ b/XMonad/Util/Hacks.hs @@ -9,7 +9,7 @@ -- Portability : unportable -- -- This module is a collection of random fixes, workarounds and other functions --- that rely on somewhat hacky implementations which may have unwanted sideeffects. +-- that rely on somewhat hacky implementations which may have unwanted side effects. -- -- Import this module as qualified like so: -- @@ -41,14 +41,21 @@ import Control.Monad (when) -- can cause issues, where the window does not correctly see the size of the window -- when displaying the fullscreen content, thus cutting off the window content. -- --- This module works around that issue by forcing the window to recalculate their +-- This function works around that issue by forcing the window to recalculate their -- dimensions after initiating fullscreen, thus making chrome-based applications -- behave properly when in windowed fullscreen. -- +-- The following gif shows the behaviour of chrome (left) without this fix +-- compared to firefox, which already behaves as expected by default: +-- <> +-- +-- Using this function, chrome will now behave as expected as well: +-- <> +-- -- Usage: -- add to handleEventHook as follows: -- --- > handleEventHook = handleEventHook def <+> windowedFullscreenFixEventHook +-- > handleEventHook = handleEventHook def <+> Hacks.windowedFullscreenFixEventHook -- -- | Fixes fullscreen behaviour of chromium based apps by quickly applying and undoing a resize.