]>
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:
-- Table of layouts to cover with awful.layout.inc, order matters.
local layouts = {
default = awful.layout.suit.fair,
-- Table of layouts to cover with awful.layout.inc, order matters.
local layouts = {
default = awful.layout.suit.fair,
+ default_horiz = awful.layout.suit.fair.horizontal,
tiled = awful.layout.suit.tile,
tiled = awful.layout.suit.tile,
+ tiled_horiz = awful.layout.suit.tile.top,
floating = awful.layout.suit.floating,
maximised = awful.layout.suit.max
}
floating = awful.layout.suit.floating,
maximised = awful.layout.suit.max
}
layouts.tiled,
layouts.maximised,
layouts.floating,
layouts.tiled,
layouts.maximised,
layouts.floating,
+ layouts.default_horiz,
+ layouts.tiled_horiz,
local function initialise_to_autorandr_profile()
local profile
local function initialise_to_autorandr_profile()
local profile
local function process_line(line)
if profile then return end
local function process_line(line)
if profile then return end
- local match = string.match(line, "^([^%s]+) %(detected%)$ ")
+ local match = string.match(line, "^([^%s]+) %(detected%)")
if match then
profile = match
end
if match then
profile = match
end
end
awful.spawn.with_line_callback('autorandr', {
end
awful.spawn.with_line_callback('autorandr', {
output_done = output_done,
exit = handle_exit
})
output_done = output_done,
exit = handle_exit
})
selected = true,
exec_once = { terminal .. " -name irc -e env MOSH_TITLE_NOPREFIX=true mosh -4 -- irc-host tmux new -As irc irssi" },
instance = { "irc" },
selected = true,
exec_once = { terminal .. " -name irc -e env MOSH_TITLE_NOPREFIX=true mosh -4 -- irc-host tmux new -As irc irssi" },
instance = { "irc" },
- targets = { "catalyst/eDP1", "mtvic/eDP1" },
+ targets = { "catalyst/eDP1", "mtvic/eDP1", "gauting/eDP1", "lehel/DisplayPort-2" },
selected = true,
exec_once = { "revolt" },
instance = { "Revolt" },
selected = true,
exec_once = { "revolt" },
instance = { "Revolt" },
- targets = { "catalyst/eDP1", "mtvic/eDP1" },
+ targets = { "catalyst/eDP1", "mtvic/eDP1", "gauting/eDP1", "lehel/DisplayPort-2" },
layout = layouts.default,
exec_once = { "thunderbird" },
class = { "Thunderbird" },
layout = layouts.default,
exec_once = { "thunderbird" },
class = { "Thunderbird" },
- targets = { "catalyst/HDMI1", "mtvic/eDP1" },
+ targets = { "catalyst/HDMI1", "mtvic/eDP1", "gauting/eDP1", "lehel/DisplayPort-1" },
layout = layouts.default,
exec_once = { "chromium" },
class = { "Chromium" },
layout = layouts.default,
exec_once = { "chromium" },
class = { "Chromium" },
- targets = { "catalyst/HDMI1", "mtvic/eDP1" },
+ targets = { "catalyst/HDMI1", "mtvic/eDP1", "gauting/eDP1", "lehel/DisplayPort-1" },
layout = layouts.default,
exec_once = { "firefox" },
class = { "Firefox" },
layout = layouts.default,
exec_once = { "firefox" },
class = { "Firefox" },
- targets = { "catalyst/HDMI1", "mtvic/eDP1" },
+ targets = { "catalyst/HDMI1", "mtvic/eDP1", "gauting/eDP1", "lehel/DisplayPort-1" },
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,
awful.key({ cmdkey }, "Home", function () awful.spawn("pactl set-source-mute 1 toggle") end),
awful.key(nil, "XF86MonBrightnessDown", function () awful.spawn("xbacklight -dec 5%") end),
awful.key(nil, "XF86MonBrightnessUp", function () awful.spawn("xbacklight -inc 5%") end),
awful.key({ cmdkey }, "Home", function () awful.spawn("pactl set-source-mute 1 toggle") end),
awful.key(nil, "XF86MonBrightnessDown", function () awful.spawn("xbacklight -dec 5%") end),
awful.key(nil, "XF86MonBrightnessUp", function () awful.spawn("xbacklight -inc 5%") end),
-awful.key(nil, "XF86Display", function () awful.spawn("" ) end),
+awful.key(nil, "XF86Display", function () awful.spawn("autorandr --change --force"); initialise_to_autorandr_profile( ) end),
awful.key(nil, "XF86WLAN", function () awful.spawn("") end),
awful.key(nil, "XF86Tools", function () awful.spawn("") end),
awful.key(nil, "XF86Search", function () awful.spawn("") end),
awful.key(nil, "XF86WLAN", function () awful.spawn("") end),
awful.key(nil, "XF86Tools", function () awful.spawn("") end),
awful.key(nil, "XF86Search", function () awful.spawn("") end),
{ rule = { class = "URxvt" },
properties = { size_hints_honor = false, }
},
{ rule = { class = "URxvt" },
properties = { size_hints_honor = false, }
},
- { rule = { instance = "irc" },
+ { rule = { instance = "irc" },
callback = move_to_tag_by_name(nil, "irc"),
},
{ rule = { class = "Revolt" },
callback = move_to_tag_by_name(nil, "irc"),
},
{ rule = { class = "Revolt" },
{ rule_any = { class = {
"MuPDF",
"Wicd-client.py",
{ rule_any = { class = {
"MuPDF",
"Wicd-client.py",
+ "Gxmessage",
+ "Pinentry"
}},
properties = { floating = true,
}},
properties = { floating = true,
- placement = function(c)
- float_client_in_the_middle_with_margins(c, 50, 25)
- end,
+ placement = awful.placement.centered,
- { rule_any = { class = {
- "Gscan2pdf",
- "Gimp",
- },
- instance = {
- "libreoffice",
- }
- },
- properties = { new_tag = {
- layout = layouts.maximised,
- volatile = true,
- },
- switchtotag = true,
+ { rule_any = { instance = {
+ "tridactyl-edit",
+ "libreoffice"
+ }},
+ properties = { floating = true,
+ maximized = false,
+ placement = awful.placement.centered,
+-- { 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)