mirror of
https://github.com/awesomeWM/awesome
synced 2024-11-17 07:47:41 +01:00
fullscreen: Add a beautiful option to remove borders.
This was previously done in a callback, but wasn't really clean and/or bug free. Borders could end up leaking on other screens as proven by an integration test. Fix #171
This commit is contained in:
parent
4ea6e133f8
commit
0bf8bb6a64
1 changed files with 16 additions and 0 deletions
|
@ -24,6 +24,10 @@ local ewmh = {
|
|||
-- @beautiful beautiful.maximized_honor_padding
|
||||
-- @tparam[opt=true] boolean maximized_honor_padding
|
||||
|
||||
--- Hide the border on fullscreen clients.
|
||||
-- @beautiful beautiful.fullscreen_hide_border
|
||||
-- @tparam[opt=true] boolean fullscreen_hide_border
|
||||
|
||||
--- The list of all registered generic request::activate (focus stealing)
|
||||
-- filters. If a filter is added to only one context, it will be in
|
||||
-- `ewmh.contextual_activate_filters`["context_name"].
|
||||
|
@ -285,7 +289,19 @@ function ewmh.geometry(c, context, hints)
|
|||
props.honor_padding = beautiful.maximized_honor_padding ~= false
|
||||
end
|
||||
|
||||
if original_context == "fullscreen" and beautiful.fullscreen_hide_border ~= false then
|
||||
props.ignore_border_width = true
|
||||
end
|
||||
|
||||
aplace[context](c, props)
|
||||
|
||||
-- Remove the border to get a "real" fullscreen.
|
||||
if original_context == "fullscreen" and beautiful.fullscreen_hide_border ~= false then
|
||||
local original = repair_geometry_lock
|
||||
repair_geometry_lock = true
|
||||
c.border_width = 0
|
||||
repair_geometry_lock = original
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue