Add dotfiles
|
@ -1 +1 @@
|
||||||
config
|
modules/radix/secrets.scm
|
||||||
|
|
18
buer.scm
|
@ -1,10 +1,20 @@
|
||||||
#|Modules|#
|
#|Modules|#
|
||||||
(use-modules
|
(use-modules
|
||||||
#|GNU |# (gnu) (gnu artwork) (gnu services) (gnu system nss)
|
#|GNU |# (gnu)
|
||||||
#|Guix |# (guix gexp) (guix packages) (guix records)
|
(gnu artwork)
|
||||||
|
(gnu services)
|
||||||
|
#|Guix |# (guix gexp)
|
||||||
|
(guix packages)
|
||||||
|
(guix records)
|
||||||
#|Misc |# (ice-9 match)
|
#|Misc |# (ice-9 match)
|
||||||
#|Radix|# (radix packages linux) (radix services linux) (radix system setuid)
|
#|Radix|# (radix packages linux)
|
||||||
(radix utils) (radix config secrets))
|
(radix services linux)
|
||||||
|
(radix system setuid)
|
||||||
|
(radix secrets)
|
||||||
|
(radix utils))
|
||||||
|
|
||||||
|
(use-system-modules
|
||||||
|
#|N|# nss)
|
||||||
|
|
||||||
(use-service-modules
|
(use-service-modules
|
||||||
#|A|# admin
|
#|A|# admin
|
||||||
|
|
|
@ -0,0 +1,182 @@
|
||||||
|
Awesome WM Copycats
|
||||||
|
===================
|
||||||
|
|
||||||
|
-------------------------
|
||||||
|
Themes for Awesome WM 4.x
|
||||||
|
-------------------------
|
||||||
|
|
||||||
|
:Author: Luca CPZ
|
||||||
|
:Version: git
|
||||||
|
:License: BY-NC-SA_
|
||||||
|
:Source: https://github.com/lcpz/awesome-copycats
|
||||||
|
|
||||||
|
Description
|
||||||
|
===========
|
||||||
|
|
||||||
|
A set of themes for the Awesome_ window manager, version 4.x.
|
||||||
|
|
||||||
|
See branches_ for previous versions.
|
||||||
|
|
||||||
|
Purpose
|
||||||
|
=======
|
||||||
|
|
||||||
|
The main purpose of this repository is to spread ready to use configurations, which can also serve as a cookbook for customisation.
|
||||||
|
|
||||||
|
A secondary aim is to add new themes only when they constitute different UI/UX designs.
|
||||||
|
|
||||||
|
Features
|
||||||
|
========
|
||||||
|
|
||||||
|
- Modularity
|
||||||
|
- Autohide widgets
|
||||||
|
- Autostart windowless processes
|
||||||
|
- Fast MPD and volume shortcuts (first time this trick has been used in Awesome)
|
||||||
|
- Shortcuts for copying to the clipboard, toggle wiboxes, widgets popups, screenshots capture, moving and magnifying clients
|
||||||
|
- Quake drop-down terminal
|
||||||
|
- Calendar with current day highlighted and months switch with a click/scroll
|
||||||
|
- Notifications for new mails, current song, volume level, hdd critical state, low battery
|
||||||
|
- OpenWeatherMap integration
|
||||||
|
- Net carrier status notifier
|
||||||
|
- Symbolic tag names
|
||||||
|
- DWM-like textual layoutbox
|
||||||
|
- Cairo wibar
|
||||||
|
- Custom layouts
|
||||||
|
- No borders when there's only one visible client
|
||||||
|
- Freedesktop.org compliant menu and desktop icons
|
||||||
|
- Vi-like client focus
|
||||||
|
- Non-empty tag browsing
|
||||||
|
- On-the-fly useless gaps resize
|
||||||
|
- Dynamic tagging
|
||||||
|
|
||||||
|
Gallery
|
||||||
|
=======
|
||||||
|
|
||||||
|
**Multicolor**, inspired by lucamanni_
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/650.png
|
||||||
|
|
||||||
|
**Powerarrow**, porting of romockee_'s
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/1453.png
|
||||||
|
|
||||||
|
**Powerarrow Dark**
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/649.jpg
|
||||||
|
|
||||||
|
**Steamburn**, porting of ok100_'s dwm
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/648.png
|
||||||
|
|
||||||
|
**Blackburn**
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/553.png
|
||||||
|
|
||||||
|
**Dremora**
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/652.png
|
||||||
|
|
||||||
|
**Rainbow**
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/606.png
|
||||||
|
|
||||||
|
**Holo**, requested by amouly_
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/651.jpg
|
||||||
|
|
||||||
|
**Copland**, inspired by foozer_
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/655.png
|
||||||
|
|
||||||
|
**Vertex**, requested by swordfischer_
|
||||||
|
|
||||||
|
.. image:: http://dotshare.it/public/images/uploads/1432.jpg
|
||||||
|
|
||||||
|
Installation
|
||||||
|
============
|
||||||
|
|
||||||
|
.. code-block:: shell
|
||||||
|
|
||||||
|
git clone --recurse-submodules --remote-submodules --depth 1 -j 2 https://github.com/lcpz/awesome-copycats.git
|
||||||
|
mv -bv awesome-copycats/{*,.[^.]*} ~/.config/awesome; rm -rf awesome-copycats
|
||||||
|
|
||||||
|
In case you do not want the Git files, use the following as the second command:
|
||||||
|
|
||||||
|
.. code-block:: shell
|
||||||
|
|
||||||
|
mv -bv awesome-copycats/* ~/.config/awesome; rm -rf awesome-copycats
|
||||||
|
|
||||||
|
Usage
|
||||||
|
=====
|
||||||
|
|
||||||
|
The modular structure allows to
|
||||||
|
|
||||||
|
* set variables
|
||||||
|
* define startup processes
|
||||||
|
* change keybindings and layouts
|
||||||
|
* set client properties
|
||||||
|
|
||||||
|
in ``rc.lua``, and
|
||||||
|
|
||||||
|
* configure widgets
|
||||||
|
* define wiboxes and screen settings
|
||||||
|
|
||||||
|
in ``theme.lua``, so that you just need to change ``chosen_theme`` variable in ``rc.lua`` to preserve your preferences *and* switch the theme, instead of having file redundancy.
|
||||||
|
|
||||||
|
Just do the following:
|
||||||
|
|
||||||
|
.. code-block:: shell
|
||||||
|
|
||||||
|
$ cd ~/.config/awesome
|
||||||
|
$ cp rc.lua.template rc.lua
|
||||||
|
|
||||||
|
Then, set the variable ``chosen_theme`` in ``rc.lua`` to your preferred theme, do your settings, and restart Awesome (``Mod4 + ctrl + r``).
|
||||||
|
|
||||||
|
To customize a theme, head over to ``themes/$chosen_theme/theme.lua``.
|
||||||
|
|
||||||
|
Otherwise, if you want to be synced with upstream, modify the theme path in ``rc.lua`` like this:
|
||||||
|
|
||||||
|
.. code-block:: diff
|
||||||
|
|
||||||
|
-beautiful.init(string.format("%s/.config/awesome/themes/%s/theme.lua", os.getenv("HOME"), chosen_theme))
|
||||||
|
+beautiful.init(string.format("%s/.config/awesome/themes/%s/theme-personal.lua", os.getenv("HOME"), chosen_theme))
|
||||||
|
|
||||||
|
then, copy ``theme.lua`` to ``theme-personal.lua`` and do your customizations there.
|
||||||
|
|
||||||
|
This way, you can safely ``git pull`` anytime.
|
||||||
|
|
||||||
|
Notes
|
||||||
|
=====
|
||||||
|
|
||||||
|
Complements are provided by lain_ and freedesktop_. **Be sure** to satisfy their dependencies_. In particular, mail_ and weather_ widgets have **mandatory** arguments.
|
||||||
|
|
||||||
|
The fonts used in the screenshots are: Terminus_ (Multicolor, Powerarrow, Powerarrow Dark), Roboto_ (Holo, Vertex) and Tamzen_ (other ones).
|
||||||
|
|
||||||
|
As taglist font, Blackburn and Dremora use Icons_, Vertex uses FontAwesome_: be sure to have bitmaps enabled if running under Debian or Ubuntu_.
|
||||||
|
|
||||||
|
Every theme has a colorscheme_.
|
||||||
|
|
||||||
|
Additional default software used: ::
|
||||||
|
|
||||||
|
amixer dmenu librewolf mpc mpd scrot unclutter xbacklight xsel slock
|
||||||
|
|
||||||
|
.. _BY-NC-SA: http://creativecommons.org/licenses/by-nc-sa/4.0
|
||||||
|
.. _Awesome: http://github.com/awesomeWM/awesome
|
||||||
|
.. _branches: https://github.com/lcpz/awesome-copycats/branches
|
||||||
|
.. _lucamanni: https://github.com/lucamanni/awesome
|
||||||
|
.. _romockee: https://github.com/romockee/powerarrow
|
||||||
|
.. _ok100: http://ok100.deviantart.com/art/DWM-January-2013-348656846
|
||||||
|
.. _amouly: https://bbs.archlinux.org/viewtopic.php?pid=1307158#p1307158
|
||||||
|
.. _swordfischer: https://github.com/lcpz/awesome-copycats/issues/53
|
||||||
|
.. _foozer: http://dotshare.it/dots/499
|
||||||
|
.. _lain: https://github.com/lcpz/lain
|
||||||
|
.. _freedesktop: https://github.com/lcpz/awesome-freedesktop
|
||||||
|
.. _Terminus: http://terminus-font.sourceforge.net
|
||||||
|
.. _Roboto: https://fonts.google.com/specimen/Roboto
|
||||||
|
.. _Tamzen: https://github.com/sunaku/tamzen-font
|
||||||
|
.. _Icons: https://github.com/lcpz/dots/tree/master/.fonts
|
||||||
|
.. _FontAwesome: https://github.com/FortAwesome/Font-Awesome
|
||||||
|
.. _Ubuntu: https://wiki.ubuntu.com/Fonts#Enabling_Bitmapped_Fonts
|
||||||
|
.. _colorscheme: https://github.com/lcpz/dots/tree/master/.colors
|
||||||
|
.. _dependencies: https://github.com/lcpz/lain/wiki#dependencies
|
||||||
|
.. _mail: https://github.com/lcpz/lain/wiki/mail
|
||||||
|
.. _weather: https://github.com/lcpz/lain/wiki/weather
|
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 550 B |
After Width: | Height: | Size: 557 B |
After Width: | Height: | Size: 559 B |
After Width: | Height: | Size: 554 B |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 562 B |
After Width: | Height: | Size: 561 B |
After Width: | Height: | Size: 195 B |
After Width: | Height: | Size: 195 B |
After Width: | Height: | Size: 6.8 KiB |
After Width: | Height: | Size: 6.9 KiB |
After Width: | Height: | Size: 208 B |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 253 B |
After Width: | Height: | Size: 617 B |
After Width: | Height: | Size: 228 B |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 578 B |
After Width: | Height: | Size: 6.8 KiB |
After Width: | Height: | Size: 6.8 KiB |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 193 B |
After Width: | Height: | Size: 536 B |
After Width: | Height: | Size: 348 B |
After Width: | Height: | Size: 532 B |
After Width: | Height: | Size: 350 B |
After Width: | Height: | Size: 186 B |
After Width: | Height: | Size: 589 B |
After Width: | Height: | Size: 541 B |
After Width: | Height: | Size: 130 B |
After Width: | Height: | Size: 206 B |
After Width: | Height: | Size: 142 B |
After Width: | Height: | Size: 189 B |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 187 B |
After Width: | Height: | Size: 254 B |
After Width: | Height: | Size: 186 B |
After Width: | Height: | Size: 154 B |
After Width: | Height: | Size: 217 B |
After Width: | Height: | Size: 176 B |
After Width: | Height: | Size: 264 B |
After Width: | Height: | Size: 176 B |
After Width: | Height: | Size: 244 B |
BIN
files/awesome/themes/anemofilia-old/icons/titlebar/maximized_normal_inactive.png
Executable file
After Width: | Height: | Size: 174 B |
After Width: | Height: | Size: 184 B |
After Width: | Height: | Size: 161 B |
After Width: | Height: | Size: 224 B |
After Width: | Height: | Size: 171 B |
After Width: | Height: | Size: 184 B |
After Width: | Height: | Size: 155 B |
After Width: | Height: | Size: 235 B |
After Width: | Height: | Size: 165 B |
After Width: | Height: | Size: 548 B |
After Width: | Height: | Size: 552 B |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 607 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 1.2 KiB |
|
@ -0,0 +1,380 @@
|
||||||
|
--[[
|
||||||
|
_ __ _ _ _ _ _
|
||||||
|
/ \ _ __ ___ _ __ ___ ___ / _(_| (_) __ _ | |_| |__ ___ _ __ ___ ___
|
||||||
|
/ _ \ | '_ \ / _ | '_ ` _ \ / _ \| |_| | | |/ _` | | __| '_ \ / _ | '_ ` _ \ / _ \
|
||||||
|
/ ___ \| | | | __| | | | | | (_) | _| | | | (_| | | |_| | | | __| | | | | | __/
|
||||||
|
/_/ \_|_| |_|\___|_| |_| |_|\___/|_| |_|_|_|\__,_| \__|_| |_|\___|_| |_| |_|\___|
|
||||||
|
|
||||||
|
|
||||||
|
--]]
|
||||||
|
local gears = require("gears")
|
||||||
|
local lain = require("lain")
|
||||||
|
local awful = require("awful")
|
||||||
|
local wibox = require("wibox")
|
||||||
|
local dpi = require("beautiful.xresources").apply_dpi
|
||||||
|
|
||||||
|
local os = os
|
||||||
|
local my_table = awful.util.table or gears.table -- 4.{0,1} compatibility
|
||||||
|
|
||||||
|
local theme = {}
|
||||||
|
theme.dir = os.getenv("HOME") .. "/.config/awesome/themes/anemofilia"
|
||||||
|
theme.wallpaper = os.getenv("HOME") .. "Pictures/Wallpapers/\wall" --theme.dir .. "/wall.png"
|
||||||
|
theme.font = "Meslo LG M DZ 9"
|
||||||
|
theme.fg_normal = "#DDDDDD"
|
||||||
|
theme.fg_focus = "#8581E0"--"#EA6F81"
|
||||||
|
theme.fg_urgent = "#DCE081"--"#CC9393"
|
||||||
|
theme.bg_normal = "#1A1A1A"
|
||||||
|
theme.bg_focus = "#313131"
|
||||||
|
theme.bg_urgent = "#1A1A1A"
|
||||||
|
theme.border_width = dpi(1)
|
||||||
|
theme.border_normal = "#3F3F3F"
|
||||||
|
theme.border_focus = "#8581E0"--"#7F7F7F"
|
||||||
|
theme.border_marked = "#CC9393"
|
||||||
|
theme.tasklist_bg_focus = "#1A1A1A"
|
||||||
|
theme.titlebar_bg_focus = theme.bg_focus
|
||||||
|
theme.titlebar_bg_normal = theme.bg_normal
|
||||||
|
theme.titlebar_fg_focus = theme.fg_focus
|
||||||
|
theme.menu_height = dpi(20)
|
||||||
|
theme.menu_width = dpi(140)
|
||||||
|
theme.menu_submenu_icon = theme.dir .. "/icons/submenu.png"
|
||||||
|
theme.taglist_squares_sel = theme.dir .. "/icons/square_sel.png"
|
||||||
|
theme.taglist_squares_unsel = theme.dir .. "/icons/square_unsel.png"
|
||||||
|
theme.layout_tile = theme.dir .. "/icons/tile1.png"
|
||||||
|
theme.layout_tileleft = theme.dir .. "/icons/tileleft1.png"
|
||||||
|
theme.layout_tilebottom = theme.dir .. "/icons/tilebottom1.png"
|
||||||
|
theme.layout_tiletop = theme.dir .. "/icons/tiletop1.png"
|
||||||
|
theme.layout_fairv = theme.dir .. "/icons/fairv.png"
|
||||||
|
theme.layout_fairh = theme.dir .. "/icons/fairh.png"
|
||||||
|
theme.layout_spiral = theme.dir .. "/icons/spiral.png"
|
||||||
|
theme.layout_dwindle = theme.dir .. "/icons/dwindle.png"
|
||||||
|
theme.layout_max = theme.dir .. "/icons/max.png"
|
||||||
|
theme.layout_fullscreen = theme.dir .. "/icons/fullscreen.png"
|
||||||
|
theme.layout_magnifier = theme.dir .. "/icons/magnifier.png"
|
||||||
|
theme.layout_floating = theme.dir .. "/icons/floating1.png"
|
||||||
|
theme.widget_ac = theme.dir .. "/icons/ac.png"
|
||||||
|
theme.widget_battery_100 = theme.dir .. "/icons/battery_100.png"
|
||||||
|
theme.widget_battery_80 = theme.dir .. "/icons/battery_80.png"
|
||||||
|
theme.widget_battery_60 = theme.dir .. "/icons/battery_60.png"
|
||||||
|
theme.widget_battery_40 = theme.dir .. "/icons/battery_40.png"
|
||||||
|
theme.widget_battery_20 = theme.dir .. "/icons/battery_20.png"
|
||||||
|
theme.widget_mem = theme.dir .. "/icons/mem.png"
|
||||||
|
theme.widget_cpu = theme.dir .. "/icons/cpu.png"
|
||||||
|
theme.widget_temp = theme.dir .. "/icons/temp.png"
|
||||||
|
theme.widget_netdown = theme.dir .. "/icons/net_down.png"
|
||||||
|
theme.widget_netup = theme.dir .. "/icons/net_up.png"
|
||||||
|
theme.widget_hdd = theme.dir .. "/icons/hdd.png"
|
||||||
|
theme.widget_music = theme.dir .. "/icons/note.png"
|
||||||
|
theme.widget_music_on = theme.dir .. "/icons/note_on.png"
|
||||||
|
theme.widget_vol = theme.dir .. "/icons/vol.png"
|
||||||
|
theme.widget_vol_low = theme.dir .. "/icons/vol_low.png"
|
||||||
|
theme.widget_vol_no = theme.dir .. "/icons/vol_no.png"
|
||||||
|
theme.widget_vol_mute = theme.dir .. "/icons/vol_mute.png"
|
||||||
|
theme.widget_mail = theme.dir .. "/icons/mail.png"
|
||||||
|
theme.widget_mail_on = theme.dir .. "/icons/mail_on.png"
|
||||||
|
theme.tasklist_plain_task_name = false
|
||||||
|
theme.tasklist_disable_icon = true
|
||||||
|
theme.gap_single_client = true
|
||||||
|
theme.useless_gap = dpi(4)
|
||||||
|
theme.titlebar_close_button_focus = theme.dir .. "/icons/titlebar/close_focus.png"
|
||||||
|
theme.titlebar_close_button_normal = theme.dir .. "/icons/titlebar/close_normal.png"
|
||||||
|
theme.titlebar_ontop_button_focus_active = theme.dir .. "/icons/titlebar/ontop_focus_active.png"
|
||||||
|
theme.titlebar_ontop_button_normal_active = theme.dir .. "/icons/titlebar/ontop_normal_active.png"
|
||||||
|
theme.titlebar_ontop_button_focus_inactive = theme.dir .. "/icons/titlebar/ontop_focus_inactive.png"
|
||||||
|
theme.titlebar_ontop_button_normal_inactive = theme.dir .. "/icons/titlebar/ontop_normal_inactive.png"
|
||||||
|
theme.titlebar_sticky_button_focus_active = theme.dir .. "/icons/titlebar/sticky_focus_active.png"
|
||||||
|
theme.titlebar_sticky_button_normal_active = theme.dir .. "/icons/titlebar/sticky_normal_active.png"
|
||||||
|
theme.titlebar_sticky_button_focus_inactive = theme.dir .. "/icons/titlebar/sticky_focus_inactive.png"
|
||||||
|
theme.titlebar_sticky_button_normal_inactive = theme.dir .. "/icons/titlebar/sticky_normal_inactive.png"
|
||||||
|
theme.titlebar_floating_button_focus_active = theme.dir .. "/icons/titlebar/floating_focus_active.png"
|
||||||
|
theme.titlebar_floating_button_normal_active = theme.dir .. "/icons/titlebar/floating_normal_active.png"
|
||||||
|
theme.titlebar_floating_button_focus_inactive = theme.dir .. "/icons/titlebar/floating_focus_inactive.png"
|
||||||
|
theme.titlebar_floating_button_normal_inactive = theme.dir .. "/icons/titlebar/floating_normal_inactive.png"
|
||||||
|
theme.titlebar_maximized_button_focus_active = theme.dir .. "/icons/titlebar/maximized_focus_active.png"
|
||||||
|
theme.titlebar_maximized_button_normal_active = theme.dir .. "/icons/titlebar/maximized_normal_active.png"
|
||||||
|
theme.titlebar_maximized_button_focus_inactive = theme.dir .. "/icons/titlebar/maximized_focus_inactive.png"
|
||||||
|
theme.titlebar_maximized_button_normal_inactive = theme.dir .. "/icons/titlebar/maximized_normal_inactive.png"
|
||||||
|
|
||||||
|
local markup = lain.util.markup
|
||||||
|
local separators = lain.util.separators
|
||||||
|
|
||||||
|
local mykeyboardlayout = awful.widget.keyboardlayout:new()
|
||||||
|
|
||||||
|
-- Textclock
|
||||||
|
local clockicon = wibox.widget.imagebox(theme.widget_clock)
|
||||||
|
local clock = awful.widget.watch(
|
||||||
|
"date +'%a %d %b %R'", 60,
|
||||||
|
function(widget, stdout)
|
||||||
|
widget:set_markup(" " .. markup.font(theme.font, stdout))
|
||||||
|
end
|
||||||
|
)
|
||||||
|
|
||||||
|
-- Calendar
|
||||||
|
theme.cal = lain.widget.cal({
|
||||||
|
icons = "",
|
||||||
|
attach_to = { clock },
|
||||||
|
notification_preset = {
|
||||||
|
font = theme.font,
|
||||||
|
fg = theme.fg_normal,
|
||||||
|
bg = theme.bg_normal
|
||||||
|
}
|
||||||
|
})
|
||||||
|
--]]--
|
||||||
|
|
||||||
|
-- Mail IMAP check
|
||||||
|
local mailicon = wibox.widget.imagebox(theme.widget_mail)
|
||||||
|
--[[ commented because it needs to be set before use
|
||||||
|
mailicon:buttons(my_table.join(awful.button({ }, 1, function () awful.spawn(mail) end)))
|
||||||
|
theme.mail = lain.widget.imap({
|
||||||
|
timeout = 180,
|
||||||
|
server = "server",
|
||||||
|
mail = "luisguilhermecoelho@usp.br",
|
||||||
|
password = "ZeugmaTau-6,283Anemofilia",
|
||||||
|
settings = function()
|
||||||
|
if mailcount > 0 then
|
||||||
|
widget:set_markup(markup.font(theme.font, " " .. mailcount .. " "))
|
||||||
|
mailicon:set_image(theme.widget_mail_on)
|
||||||
|
else
|
||||||
|
widget:set_text("")
|
||||||
|
mailicon:set_image(theme.widget_mail)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
})
|
||||||
|
--]]
|
||||||
|
|
||||||
|
-- MPD
|
||||||
|
local musicplr = awful.util.terminal .. " -title Music -g 130x34-320+16 -e ncmpcpp"
|
||||||
|
local mpdicon = wibox.widget.imagebox(theme.widget_music)
|
||||||
|
mpdicon:buttons(my_table.join(
|
||||||
|
awful.button({ modkey }, 1, function () awful.spawn.with_shell(musicplr) end),
|
||||||
|
awful.button({ }, 1, function ()
|
||||||
|
os.execute("mpc prev")
|
||||||
|
theme.mpd.update()
|
||||||
|
end),
|
||||||
|
awful.button({ }, 2, function ()
|
||||||
|
os.execute("mpc toggle")
|
||||||
|
theme.mpd.update()
|
||||||
|
end),
|
||||||
|
awful.button({ }, 3, function ()
|
||||||
|
os.execute("mpc next")
|
||||||
|
theme.mpd.update()
|
||||||
|
end)))
|
||||||
|
theme.mpd = lain.widget.mpd({
|
||||||
|
settings = function()
|
||||||
|
if mpd_now.state == "play" then
|
||||||
|
artist = mpd_now.artist .. " "
|
||||||
|
title = mpd_now.title .. " "
|
||||||
|
mpdicon:set_image(theme.widget_music_on)
|
||||||
|
elseif mpd_now.state == "pause" then
|
||||||
|
artist = "mpd "
|
||||||
|
title = "paused "
|
||||||
|
else
|
||||||
|
artist = ""
|
||||||
|
title = ""
|
||||||
|
mpdicon:set_image(theme.widget_music)
|
||||||
|
end
|
||||||
|
|
||||||
|
widget:set_markup(markup.font(theme.font, markup("#EA6F81", artist) .. title))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- MEM
|
||||||
|
local memicon = wibox.widget.imagebox(theme.widget_mem)
|
||||||
|
local mem = lain.widget.mem({
|
||||||
|
settings = function()
|
||||||
|
widget:set_markup(markup.font(theme.font, mem_now.used .. "MB "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- CPU
|
||||||
|
local cpuicon = wibox.widget.imagebox(theme.widget_cpu)
|
||||||
|
local cpu = lain.widget.cpu({
|
||||||
|
settings = function()
|
||||||
|
widget:set_markup(markup.font(theme.font, cpu_now.usage .. "% "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Coretemp
|
||||||
|
local tempicon = wibox.widget.imagebox(theme.widget_temp)
|
||||||
|
local temp = lain.widget.temp({
|
||||||
|
settings = function()
|
||||||
|
widget:set_markup(markup.font(theme.font, math.ceil(coretemp_now) .. "°C "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- / fs
|
||||||
|
local fsicon = wibox.widget.imagebox(theme.widget_hdd)
|
||||||
|
--[[ commented because it needs Gio/Glib >= 2.54
|
||||||
|
theme.fs = lain.widget.fs({
|
||||||
|
notification_preset = { fg = theme.fg_normal, bg = theme.bg_normal, font = "Terminus 10" },
|
||||||
|
settings = function()
|
||||||
|
widget:set_markup(markup.font(theme.font, " " .. fs_now["/"].percentage .. "% "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
--]]
|
||||||
|
|
||||||
|
-- Battery
|
||||||
|
local baticon = wibox.widget.imagebox(theme.widget_battery)
|
||||||
|
local bat = lain.widget.bat({
|
||||||
|
settings = function()
|
||||||
|
if bat_now.status and bat_now.status ~= "N/A" then
|
||||||
|
if bat_now.ac_status == 1 then
|
||||||
|
baticon:set_image(theme.widget_ac)
|
||||||
|
elseif bat_now.perc and tonumber(bat_now.perc) < 25 then
|
||||||
|
baticon:set_image(theme.widget_battery_20)
|
||||||
|
elseif bat_now.perc and tonumber(bat_now.perc) < 45 then
|
||||||
|
baticon:set_image(theme.widget_battery_40)
|
||||||
|
elseif bat_now.perc and tonumber(bat_now.perc) < 65 then
|
||||||
|
baticon:set_image(theme.widget_battery_60)
|
||||||
|
elseif bat_now.perc and tonumber(bat_now.perc) < 85 then
|
||||||
|
baticon:set_image(theme.widget_battery_80)
|
||||||
|
else
|
||||||
|
baticon:set_image(theme.widget_battery_100)
|
||||||
|
end
|
||||||
|
widget:set_markup(markup.font(theme.font, bat_now.perc .. "% "))
|
||||||
|
else
|
||||||
|
widget:set_markup(markup.font(theme.font, "AC "))
|
||||||
|
baticon:set_image(theme.widget_ac)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- ALSA volume
|
||||||
|
local volicon = wibox.widget.imagebox(theme.widget_vol)
|
||||||
|
theme.volume = lain.widget.alsa({
|
||||||
|
settings = function()
|
||||||
|
if volume_now.status == "off" then
|
||||||
|
volicon:set_image(theme.widget_vol_mute)
|
||||||
|
elseif tonumber(volume_now.level) == 0 then
|
||||||
|
volicon:set_image(theme.widget_vol_no)
|
||||||
|
elseif tonumber(volume_now.level) <= 50 then
|
||||||
|
volicon:set_image(theme.widget_vol_low)
|
||||||
|
else
|
||||||
|
volicon:set_image(theme.widget_vol)
|
||||||
|
end
|
||||||
|
|
||||||
|
widget:set_markup(markup.font(theme.font, volume_now.level .. "% "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
theme.volume.widget:buttons(awful.util.table.join(
|
||||||
|
awful.button({}, 4, function ()
|
||||||
|
awful.util.spawn("amixer set Master 1%+")
|
||||||
|
theme.volume.update()
|
||||||
|
end),
|
||||||
|
awful.button({}, 5, function ()
|
||||||
|
awful.util.spawn("amixer set Master 1%-")
|
||||||
|
theme.volume.update()
|
||||||
|
end)
|
||||||
|
))
|
||||||
|
|
||||||
|
-- Net
|
||||||
|
local netdownicon = wibox.widget.imagebox(theme.widget_netdown)
|
||||||
|
local netdowninfo = wibox.widget.textbox()
|
||||||
|
local netupicon = wibox.widget.imagebox(theme.widget_netup)
|
||||||
|
local netupinfo = lain.widget.net({
|
||||||
|
settings = function()
|
||||||
|
widget:set_markup(markup.font(theme.font, net_now.sent .. " "))
|
||||||
|
netdowninfo:set_markup(markup.font(theme.font, net_now.received .. " "))
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
|
-- System tray
|
||||||
|
local systray = wibox.widget.systray()
|
||||||
|
systray:set_base_size(20)
|
||||||
|
systray:set_reverse(true)
|
||||||
|
|
||||||
|
-- Separators
|
||||||
|
local spr = wibox.widget.textbox(' ')
|
||||||
|
local arrl_dl = separators.arrow_left(theme.bg_focus, "alpha")
|
||||||
|
local arrl_ld = separators.arrow_left("alpha", theme.bg_focus)
|
||||||
|
|
||||||
|
function theme.at_screen_connect(s)
|
||||||
|
-- Quake application
|
||||||
|
s.quake = lain.util.quake({ app = awful.util.terminal })
|
||||||
|
|
||||||
|
-- If wallpaper is a function, call it with the screen
|
||||||
|
local wallpaper = theme.wallpaper
|
||||||
|
if type(wallpaper) == "function" then
|
||||||
|
wallpaper = wallpaper(s)
|
||||||
|
end
|
||||||
|
gears.wallpaper.maximized(wallpaper, s, true)
|
||||||
|
|
||||||
|
-- Tags
|
||||||
|
awful.tag(awful.util.tagnames, s, awful.layout.layouts)
|
||||||
|
|
||||||
|
-- Create a promptbox for each screen
|
||||||
|
s.mypromptbox = awful.widget.prompt()
|
||||||
|
-- Create an imagebox widget which will contains an icon indicating which layout we're using.
|
||||||
|
-- We need one layoutbox per screen.
|
||||||
|
s.mylayoutbox = awful.widget.layoutbox(s)
|
||||||
|
s.mylayoutbox:buttons(my_table.join(
|
||||||
|
awful.button({}, 1, function () awful.layout.inc( 1) end),
|
||||||
|
awful.button({}, 2, function () awful.layout.set( awful.layout.layouts[1] ) end),
|
||||||
|
awful.button({}, 3, function () awful.layout.inc(-1) end),
|
||||||
|
awful.button({}, 4, function () awful.layout.inc( 1) end),
|
||||||
|
awful.button({}, 5, function () awful.layout.inc(-1) end)))
|
||||||
|
-- Create a taglist widget
|
||||||
|
s.mytaglist = awful.widget.taglist(s, awful.widget.taglist.filter.all, awful.util.taglist_buttons)
|
||||||
|
|
||||||
|
-- Create a tasklist widget
|
||||||
|
s.mytasklist = awful.widget.tasklist(s, awful.widget.tasklist.filter.currenttags, awful.util.tasklist_buttons)
|
||||||
|
|
||||||
|
-- Create the wibox
|
||||||
|
s.mywibox = awful.wibar({ position = "top", screen = s, height = dpi(19), bg = theme.bg_normal, fg = theme.fg_normal })
|
||||||
|
|
||||||
|
-- Add widgets to the wibox
|
||||||
|
s.mywibox:setup {
|
||||||
|
layout = wibox.layout.align.horizontal,
|
||||||
|
{ -- Left widgets
|
||||||
|
layout = wibox.layout.fixed.horizontal,
|
||||||
|
--spr,
|
||||||
|
s.mytaglist,
|
||||||
|
s.mypromptbox,
|
||||||
|
spr,
|
||||||
|
},
|
||||||
|
s.mytasklist, -- Middle widget
|
||||||
|
{ -- Right widgets
|
||||||
|
layout = wibox.layout.fixed.horizontal,
|
||||||
|
--systray,
|
||||||
|
spr,
|
||||||
|
--arrl_dl,
|
||||||
|
--wibox.container.background(mpdicon, theme.bg_focus),
|
||||||
|
--wibox.container.background(theme.mpd.widget, theme.bg_focus),
|
||||||
|
arrl_ld,
|
||||||
|
--wibox.container.background(mailicon, theme.bg_focus),
|
||||||
|
--wibox.container.background(theme.mail.widget, theme.bg_focus),
|
||||||
|
wibox.container.background(netdownicon, theme.bg_focus),
|
||||||
|
wibox.container.background(netdowninfo, theme.bg_focus),
|
||||||
|
wibox.container.background(netupicon, theme.bg_focus),
|
||||||
|
wibox.container.background(netupinfo.widget, theme.bg_focus),
|
||||||
|
arrl_dl,
|
||||||
|
wibox.container.background(memicon, theme.bg_normal),
|
||||||
|
wibox.container.background(mem.widget, theme.bg_normal),
|
||||||
|
arrl_ld,
|
||||||
|
wibox.container.background(cpuicon, theme.bg_focus),
|
||||||
|
wibox.container.background(cpu.widget, theme.bg_focus),
|
||||||
|
arrl_dl,
|
||||||
|
wibox.container.background(tempicon, theme.bg_normal),
|
||||||
|
wibox.container.background(temp.widget, theme.bg_normal),
|
||||||
|
arrl_ld,
|
||||||
|
--wibox.container.background(fsicon, theme.bg_focus),
|
||||||
|
--wibox.container.background(theme.fs.widget, theme.bg_focus),
|
||||||
|
--arrl_dl,
|
||||||
|
wibox.container.background(volicon, theme.bg_focus),
|
||||||
|
wibox.container.background(theme.volume.widget, theme.bg_focus),
|
||||||
|
arrl_dl,
|
||||||
|
wibox.container.background(baticon, theme.bg_normal),
|
||||||
|
wibox.container.background(bat.widget, theme.bg_normal),
|
||||||
|
arrl_ld,
|
||||||
|
--wibox.container.background(neticon, theme.bg_focus),
|
||||||
|
--wibox.container.background(net.widget, theme.bg_focus),
|
||||||
|
--arrl_dl,
|
||||||
|
wibox.container.background(clock, theme.bg_focus),
|
||||||
|
wibox.container.background(spr, theme.bg_focus),
|
||||||
|
arrl_dl,
|
||||||
|
wibox.container.background(s.mylayoutbox, theme.bg_normal),
|
||||||
|
|
||||||
|
},
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
|
return theme
|
After Width: | Height: | Size: 79 KiB |
After Width: | Height: | Size: 6.0 MiB |
After Width: | Height: | Size: 177 B |
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 553 B |
After Width: | Height: | Size: 550 B |
After Width: | Height: | Size: 557 B |
After Width: | Height: | Size: 559 B |
After Width: | Height: | Size: 554 B |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 6.8 KiB |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 576 B |
After Width: | Height: | Size: 578 B |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 536 B |
After Width: | Height: | Size: 532 B |
After Width: | Height: | Size: 186 B |
After Width: | Height: | Size: 589 B |
After Width: | Height: | Size: 540 B |
After Width: | Height: | Size: 541 B |
After Width: | Height: | Size: 6.7 KiB |
After Width: | Height: | Size: 6.5 KiB |
After Width: | Height: | Size: 563 B |
After Width: | Height: | Size: 607 B |