awful.menu: handling with strings

Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
dodo 2011-03-31 11:56:11 +02:00 committed by Uli Schlachter
parent cd201bdf6a
commit 3a4761732c
1 changed files with 3 additions and 0 deletions

View File

@ -88,6 +88,9 @@ local function load_theme(a, b)
fallback.menu_height or 16
ret.width = a.width or b.menu_width or b.width or
fallback.menu_width or 100
for _, prop in ipairs({"width", "height", "menu_width"}) do
if type(ret[prop]) ~= "number" then ret[prop] = tonumber(ret[prop]) end
end
return ret
end