blob: cceba894142465fb93bf5dc16fdf653ca78daf6b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
local vars = require "misc.vars"
local wibox = require "wibox"
local h = require "misc.helpers"
local brightness = wibox.widget {
widget = wibox.container.place,
{
widget = wibox.widget.textbox,
font = vars.font,
text = ""
},
}
h.tooltip({ brightness }, function()
return math.floor(tonumber(io.popen("brightnessctl g"):read("*a"):sub(0, -2)) / 255 * 100) .. "%"
end)
return brightness
|