Add theme variable `find_margin`

This commit is contained in:
David Kosorin 2024-10-18 00:55:18 +02:00
parent d073a83188
commit ed55dbe1e7
No known key found for this signature in database
1 changed files with 4 additions and 2 deletions

View File

@ -393,6 +393,8 @@ function widget.new(args)
beautiful.hotkeys_find_ul_cursor
self.find_font = args.find_font or
beautiful.hotkeys_find_font or self.font
self.find_margin = args.find_margin or
beautiful.hotkeys_find_margin or self.group_margin
self.label_colors = beautiful.xresources.get_current_theme()
self._widget_settings_loaded = true
end
@ -771,8 +773,8 @@ function widget.new(args)
end
function widget_instance:_create_find_data()
local margin = self.group_margin
local textbox = wibox.widget.textbox("", true)
local margin = self.find_margin
local textbox = wibox.widget.textbox()
local container = wibox.container.margin(textbox, margin, margin, margin, margin)
local height = beautiful.get_font_height(self.find_font) + 2 * margin
return {