about summary refs log tree commit diff
path: root/awesome/.config/awesome/rc.lua
diff options
context:
space:
mode:
authorNguyễn Gia Phong <vn.mcsinyx@gmail.com>2019-06-01 15:51:21 +0700
committerNguyễn Gia Phong <vn.mcsinyx@gmail.com>2019-06-01 15:51:21 +0700
commit92fa2f573eadd41b35aa115402d282829f40e824 (patch)
tree26428e03e76b943ff87287149562b054820f36e9 /awesome/.config/awesome/rc.lua
parentcfc3a0f3d53e2a5dd3ba6f898d6c055b07a94312 (diff)
downloaddotfiles-92fa2f573eadd41b35aa115402d282829f40e824.tar.gz
Update 2019-06-01
Diffstat (limited to 'awesome/.config/awesome/rc.lua')
-rw-r--r--awesome/.config/awesome/rc.lua26
1 files changed, 19 insertions, 7 deletions
diff --git a/awesome/.config/awesome/rc.lua b/awesome/.config/awesome/rc.lua
index 4ffa8a3..485e4d2 100644
--- a/awesome/.config/awesome/rc.lua
+++ b/awesome/.config/awesome/rc.lua
@@ -88,7 +88,7 @@ awful.layout.layouts = {
   --awful.layout.suit.spiral,
   --awful.layout.suit.spiral.dwindle,
   awful.layout.suit.max,
-  --awful.layout.suit.max.fullscreen,
+  awful.layout.suit.max.fullscreen,
   --awful.layout.suit.magnifier,
   --awful.layout.suit.corner.nw,
   --awful.layout.suit.corner.ne,
@@ -286,14 +286,22 @@ local tasklist_buttons = awful.util.table.join(
   awful.button({}, 5, function () awful.client.focus.byidx(-1) end)
 )
 
---local function set_bg(s) end
--- Re-set background color when a screen's geometry changes
---screen.connect_signal("property::geometry", set_bg)
+local function set_wallpaper(s)
+  -- Wallpaper
+  if beautiful.wallpaper then
+    local wallpaper = beautiful.wallpaper
+    -- If wallpaper is a function, call it with the screen
+    if type(wallpaper) == "function" then
+      wallpaper = wallpaper(s)
+    end
+    gears.wallpaper.maximized(wallpaper, s, true)
+  end
+end
 
-awful.screen.connect_for_each_screen(function (s)
-  -- Background color
-  --set_bg(s)
+-- Re-set wallpaper when a screen's geometry changes (e.g. different resolution)
+screen.connect_signal("property::geometry", set_wallpaper)
 
+awful.screen.connect_for_each_screen(function (s)
   -- Each screen has its own tag table.
   awful.tag({"1", "2", "3", "4", "5", "6", "7", "8", "9"}, s,
             awful.layout.layouts[1])
@@ -471,6 +479,8 @@ local globalkeys = awful.util.table.join(
             {description = "open Guile interpreter", group = "launcher"}),
   awful.key({modkey}, "o", spawner(octave),
             {description = "open Octave", group = "launcher"}),
+  awful.key({modkey, "Shift"}, "o", spawner"geogebra-classic",
+            {description = "open GeoGebra", group = "launcher"}),
   awful.key({modkey}, "z", spawner"zathura",
             {description = "open zathura document viewer", group = "launcher"}),
   awful.key({modkey}, "d", spawner"diodon",
@@ -497,6 +507,8 @@ local globalkeys = awful.util.table.join(
             {description = "Audacious: previous track", group = "multimedia"}),
   awful.key({}, "XF86AudioNext", spawner(audacious_forward),
             {description = "Audacious: next track", group = "multimedia"}),
+  awful.key({}, "XF86Display", spawner"arandr",
+            {description = "open Arandr", group = "multimedia"}),
   awful.key({}, "Print", nil, spawner(scrot_select),
             {description = "shoot a window or rectangle selected with a mouse",
              group = "multimedia"}),