diff --git a/lib/awful/menu.lua b/lib/awful/menu.lua index 0635e7c58..42440e948 100644 --- a/lib/awful/menu.lua +++ b/lib/awful/menu.lua @@ -116,7 +116,7 @@ local function load_theme(a, b) ret.border = a.border_color or b.menu_border_color or b.border_normal or fallback.menu_border_color or fallback.border_normal ret.border_width= a.border_width or b.menu_border_width or b.border_width or - fallback.menu_border_width or fallback.border_width or 0 + fallback.menu_border_width or fallback.border_width or dpi(0) ret.fg_focus = a.fg_focus or b.menu_fg_focus or b.fg_focus or fallback.menu_fg_focus or fallback.fg_focus ret.bg_focus = a.bg_focus or b.menu_bg_focus or b.bg_focus or @@ -130,9 +130,9 @@ local function load_theme(a, b) ret.submenu = a.submenu or b.menu_submenu or b.submenu or fallback.menu_submenu or fallback.submenu or "▶" ret.height = a.height or b.menu_height or b.height or - fallback.menu_height or 16 + fallback.menu_height or dpi(16) ret.width = a.width or b.menu_width or b.width or - fallback.menu_width or 100 + fallback.menu_width or dpi(100) ret.font = a.font or b.font or fallback.font for _, prop in ipairs({"width", "height", "menu_width"}) do if type(ret[prop]) ~= "number" then ret[prop] = tonumber(ret[prop]) end diff --git a/themes/default/theme.lua b/themes/default/theme.lua index 0a6b1792f..b0be48012 100644 --- a/themes/default/theme.lua +++ b/themes/default/theme.lua @@ -24,7 +24,7 @@ theme.fg_focus = "#ffffff" theme.fg_urgent = "#ffffff" theme.fg_minimize = "#ffffff" -theme.useless_gap = 0 +theme.useless_gap = dpi(0) theme.border_width = dpi(1) theme.border_normal = "#000000" theme.border_focus = "#535d6c" diff --git a/themes/sky/theme.lua b/themes/sky/theme.lua index c7d531766..0aa7d1bd6 100644 --- a/themes/sky/theme.lua +++ b/themes/sky/theme.lua @@ -25,7 +25,7 @@ theme.fg_focus = "#2e3436" theme.fg_urgent = "#2e3436" theme.fg_minimize = "#2e3436" -theme.useless_gap = 0 +theme.useless_gap = dpi(0) theme.border_width = dpi(2) theme.border_normal = "#dae3e0" theme.border_focus = "#729fcf" diff --git a/themes/zenburn/theme.lua b/themes/zenburn/theme.lua index af10fae60..2b6fa08a8 100644 --- a/themes/zenburn/theme.lua +++ b/themes/zenburn/theme.lua @@ -4,6 +4,7 @@ ------------------------------- local themes_path = require("gears.filesystem").get_themes_dir() +local dpi = require("beautiful.xresources").apply_dpi -- {{{ Main local theme = {} @@ -24,8 +25,8 @@ theme.bg_systray = theme.bg_normal -- }}} -- {{{ Borders -theme.useless_gap = 0 -theme.border_width = 2 +theme.useless_gap = dpi(0) +theme.border_width = dpi(2) theme.border_normal = "#3F3F3F" theme.border_focus = "#6F6F6F" theme.border_marked = "#CC9393" @@ -66,8 +67,8 @@ theme.mouse_finder_color = "#CC9393" -- Variables set for theming the menu: -- menu_[bg|fg]_[normal|focus] -- menu_[border_color|border_width] -theme.menu_height = 15 -theme.menu_width = 100 +theme.menu_height = dpi(15) +theme.menu_width = dpi(100) -- }}} -- {{{ Icons