]>
git.madduck.net Git - etc/awesome.git/blobdiff - .config/awesome/rc.lua
madduck's git repository
Every one of the projects in this repository is available at the canonical
URL git://git.madduck.net/madduck/pub/<projectpath> — see
each project's metadata for the exact URL.
All patches and comments are welcome. Please squash your changes to logical
commits before using git-format-patch and git-send-email to
patches@ git. madduck. net .
If you'd read over the Git project's submission guidelines and adhered to them,
I'd be especially grateful.
SSH access, as well as push access can be individually
arranged .
If you use my repositories frequently, consider adding the following
snippet to ~/.gitconfig and using the third clone URL listed for each
project:
[url "git://git.madduck.net/madduck/"]
insteadOf = madduck:
-- forced_width = 4,
-- widget = wibox.widget.separator
--}
-- forced_width = 4,
-- widget = wibox.widget.separator
--}
-local spacer = wibox.widget.textbox()
-spacer:set_text(" │ ")
+local function make_spacer(text)
+ local spacer = wibox.widget.textbox()
+ spacer:set_text(text or " │ ")
+ return spacer
+end
-- Keyboard map indicator and switcher
mykeyboardlayout = awful.widget.keyboardlayout()
-- Keyboard map indicator and switcher
mykeyboardlayout = awful.widget.keyboardlayout()
clocksarray = clocksarray.get_clocksarray("%a %d %b %H:%M:%S %Z", {
["NZ"] = "Pacific/Auckland",
["DE"] = "Europe/Berlin"
clocksarray = clocksarray.get_clocksarray("%a %d %b %H:%M:%S %Z", {
["NZ"] = "Pacific/Auckland",
["DE"] = "Europe/Berlin"
-- Create a wibox for each screen and add it
local taglist_buttons = gears.table.join(
-- Create a wibox for each screen and add it
local taglist_buttons = gears.table.join(
-- Add widgets to the wibox
local right_widgets = gears.table.join(clocksarray, {
-- Add widgets to the wibox
local right_widgets = gears.table.join(clocksarray, {
- spacer,
- --spacing = 4,
- --spacing_widget = spacer,
+ make_spacer(" "),
+ wibox.widget.systray(),
s.mylayoutbox,
layout = wibox.layout.fixed.horizontal,
})
if s == screen.primary then
right_widgets = gears.table.join({
s.mylayoutbox,
layout = wibox.layout.fixed.horizontal,
})
if s == screen.primary then
right_widgets = gears.table.join({
- wibox.widget.systray(),
- spacer,
}, right_widgets)
end
s.mywibox:setup {
layout = wibox.layout.align.horizontal,
{ -- Left widgets
}, right_widgets)
end
s.mywibox:setup {
layout = wibox.layout.align.horizontal,
{ -- Left widgets
- spacing = 4,
- spacing_widget = spacer,
layout = wibox.layout.fixed.horizontal,
--s.namebox,
s.mytaglist,
layout = wibox.layout.fixed.horizontal,
--s.namebox,
s.mytaglist,
s.mypromptbox,
},
s.mytasklist, -- Middle widget
s.mypromptbox,
},
s.mytasklist, -- Middle widget
bg_cursor = '#ff0000',
textbox = widget,
history_path = awful.util.get_cache_dir() .. "/history",
bg_cursor = '#ff0000',
textbox = widget,
history_path = awful.util.get_cache_dir() .. "/history",
+ completion_callback = awful.completion.shell,
hooks = {
-- Replace the 'normal' Return with a custom one
{{ }, 'Return', function(command)
hooks = {
-- Replace the 'normal' Return with a custom one
{{ }, 'Return', function(command)
awful.key({ modkey, }, "d", th.delete_tag,
{description = "delete the current tag", group = "tag"}),
awful.key({ modkey, "Shift", }, "a", function()
awful.key({ modkey, }, "d", th.delete_tag,
{description = "delete the current tag", group = "tag"}),
awful.key({ modkey, "Shift", }, "a", function()
- move_to_new_tag(nil,nil,true,true,true)
+ th. move_to_new_tag(nil,nil,true,true,true)
end,
{description = "add a volatile tag with the focused client", group = "tag"}),
awful.key({ modkey, "Shift", "Control" }, "a", function()
end,
{description = "add a volatile tag with the focused client", group = "tag"}),
awful.key({ modkey, "Shift", "Control" }, "a", function()
- move_to_new_tag(nil,nil,false,true,true)
+ th. move_to_new_tag(nil,nil,false,true,true)
end,
{description = "add a permanent tag with the focused client", group = "tag"}),
awful.key({ modkey, "Mod1" }, "a", th.copy_tag,
end,
{description = "add a permanent tag with the focused client", group = "tag"}),
awful.key({ modkey, "Mod1" }, "a", th.copy_tag,
- { rule_any = { class = {
- "Gscan2pdf",
- "Gimp",
- },
- instance = {
- "libreoffice",
- }
- },
- properties = { new_tag = {
- layout = layouts.maximised,
- volatile = true,
- },
- switchtotag = true,
- focus = true,
- },
- },
+-- { rule_any = { class = {
+-- "Gscan2pdf",
+-- "Gimp",
+-- },
+-- instance = {
+-- "libreoffice",
+-- }
+-- },
+-- properties = { new_tag = {
+-- layout = layouts.maximised,
+-- volatile = true,
+-- },
+-- switchtotag = true,
+-- focus = true,
+-- },
+-- },
--XX-- { rule = { class = "Gscan2pdf" },
--XX-- properties = {
--XX-- switchtotag = true
--XX-- { rule = { class = "Gscan2pdf" },
--XX-- properties = {
--XX-- switchtotag = true
}, context) then
gears.timer.delayed_call(function()
-- we need a delayed call so that we execute *after layout changes
}, context) then
gears.timer.delayed_call(function()
-- we need a delayed call so that we execute *after layout changes
- centre_mouse_on_area(client.focus)
+ if hints.raise and c == client.focus and client.focus:isvisible() then
+ move_mouse_to_area(client.focus)
+ end
- else
- dbg.dump(c, context, hints)