https://github.com/joshdk/awesome-textvolume
A volume widget for Awesome WM
https://github.com/joshdk/awesome-textvolume
List: awesome-textvolume
Last synced: 2 months ago
JSON representation
A volume widget for Awesome WM
- Host: GitHub
- URL: https://github.com/joshdk/awesome-textvolume
- Owner: joshdk
- License: other
- Created: 2013-01-05T05:23:10.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2013-09-17T06:27:23.000Z (almost 13 years ago)
- Last Synced: 2025-11-02T06:01:47.445Z (8 months ago)
- Language: Lua
- Size: 133 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
awesome-textvolume
==================
A volume widget for Awesome WM
Installing
----------
# make install
Uninstalling
------------
# make uninstall
Using
-----
Import the module
```lua
-- Add this line at the top of your rc.lua
local textvolume = require("textvolume");
```
Create a widget instance (at the start of the Wibox section in rc.lua):
```lua
-- Create the textclock widget
local mytextclock = awful.widget.textclock()
-- Create our textvolume widget
local mytextvolume = textvolume("Master", 5)
```
Add our instance (near the end of the Wibox section in rc.lua):
```lua
-- Add the textvolume widget
right_layout:add(mytextvolume)
right_layout:add(mytextclock)
right_layout:add(mylayoutbox[s])
```
Start binding!
```lua
-- Keybinding that lowers volume by 5%
awful.key({ }, "XF86AudioLowerVolume",
function ()
mytextvolume:dec(5)
end
)
-- Keybinding that raises volume by 5%
awful.key({ }, "XF86AudioRaiseVolume",
function ()
mytextvolume:inc(5)
end
)
-- Keybinding that toggles mute
awful.key({ }, "XF86AudioMute",
function ()
mytextvolume:toggle()
end
)
```