From 3ea6964c0b5e3e1158488adff9468054bd456fc4 Mon Sep 17 00:00:00 2001 From: James Patrick Date: Sun, 28 Apr 2019 21:41:21 -0400 Subject: [PATCH] Fixed Formatting and added print function. --- sway/config | 210 +++++++++++++++++++++++++--------------------------- 1 file changed, 102 insertions(+), 108 deletions(-) diff --git a/sway/config b/sway/config index 4742624..9bf2a7d 100644 --- a/sway/config +++ b/sway/config @@ -103,118 +103,128 @@ font pango:Fira Code 9 # # Basics: # - # start a terminal - bindsym $mod+Return exec $term +# start a terminal +bindsym $mod+Return exec $term - # kill focused window - bindsym $mod+q kill +# kill focused window +bindsym $mod+q kill - # start your launcher - bindsym $mod+d exec $menu +# start your launcher +bindsym $mod+d exec $menu - # Drag floating windows by holding down $mod and left mouse button. - # Resize them with right mouse button + $mod. - # Despite the name, also works for non-floating windows. - # Change normal to inverse to use left mouse button for resizing and right - # mouse button for dragging. - floating_modifier $mod normal +# Drag floating windows by holding down $mod and left mouse button. +# Resize them with right mouse button + $mod. +# Despite the name, also works for non-floating windows. +# Change normal to inverse to use left mouse button for resizing and right +# mouse button for dragging. +floating_modifier $mod normal - # reload the configuration file - bindsym $mod+Shift+c reload +# reload the configuration file +bindsym $mod+Shift+c reload - # exit sway (logs you out of your Wayland session) - bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -b 'Yes, exit sway' 'swaymsg exit' +# exit sway (logs you out of your Wayland session) +bindsym $mod+Shift+e exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -b 'Yes, exit sway' 'swaymsg exit' # # Moving around: # - # Move your focus around - bindsym $mod+$left focus left - bindsym $mod+$down focus down - bindsym $mod+$up focus up - bindsym $mod+$right focus right - # or use $mod+[up|down|left|right] - bindsym $mod+Left focus left - bindsym $mod+Down focus down - bindsym $mod+Up focus up - bindsym $mod+Right focus right +# Move your focus around +bindsym $mod+$left focus left +bindsym $mod+$down focus down +bindsym $mod+$up focus up +bindsym $mod+$right focus right +# or use $mod+[up|down|left|right] +bindsym $mod+Left focus left +bindsym $mod+Down focus down +bindsym $mod+Up focus up +bindsym $mod+Right focus right - # _move_ the focused window with the same, but add Shift - bindsym $mod+Shift+$left move left - bindsym $mod+Shift+$down move down - bindsym $mod+Shift+$up move up - bindsym $mod+Shift+$right move right - # ditto, with arrow keys - bindsym $mod+Shift+Left move left - bindsym $mod+Shift+Down move down - bindsym $mod+Shift+Up move up - bindsym $mod+Shift+Right move right +# _move_ the focused window with the same, but add Shift +bindsym $mod+Shift+$left move left +bindsym $mod+Shift+$down move down +bindsym $mod+Shift+$up move up +bindsym $mod+Shift+$right move right +# ditto, with arrow keys +bindsym $mod+Shift+Left move left +bindsym $mod+Shift+Down move down +bindsym $mod+Shift+Up move up +bindsym $mod+Shift+Right move right # # Workspaces: # - # switch to workspace - bindsym $mod+1 workspace 1 - bindsym $mod+2 workspace 2 - bindsym $mod+3 workspace 3 - bindsym $mod+4 workspace 4 - bindsym $mod+5 workspace 5 - bindsym $mod+6 workspace 6 - bindsym $mod+7 workspace 7 - bindsym $mod+8 workspace 8 - bindsym $mod+9 workspace 9 - bindsym $mod+0 workspace 10 - # move focused container to workspace - bindsym $mod+Shift+1 move container to workspace 1 - bindsym $mod+Shift+2 move container to workspace 2 - bindsym $mod+Shift+3 move container to workspace 3 - bindsym $mod+Shift+4 move container to workspace 4 - bindsym $mod+Shift+5 move container to workspace 5 - bindsym $mod+Shift+6 move container to workspace 6 - bindsym $mod+Shift+7 move container to workspace 7 - bindsym $mod+Shift+8 move container to workspace 8 - bindsym $mod+Shift+9 move container to workspace 9 - bindsym $mod+Shift+0 move container to workspace 10 - # Note: workspaces can have any name you want, not just numbers. - # We just use 1-10 as the default. +# switch to workspace +bindsym $mod+1 workspace 1 +bindsym $mod+2 workspace 2 +bindsym $mod+3 workspace 3 +bindsym $mod+4 workspace 4 +bindsym $mod+5 workspace 5 +bindsym $mod+6 workspace 6 +bindsym $mod+7 workspace 7 +bindsym $mod+8 workspace 8 +bindsym $mod+9 workspace 9 +bindsym $mod+0 workspace 10 +# move focused container to workspace +bindsym $mod+Shift+1 move container to workspace 1 +bindsym $mod+Shift+2 move container to workspace 2 +bindsym $mod+Shift+3 move container to workspace 3 +bindsym $mod+Shift+4 move container to workspace 4 +bindsym $mod+Shift+5 move container to workspace 5 +bindsym $mod+Shift+6 move container to workspace 6 +bindsym $mod+Shift+7 move container to workspace 7 +bindsym $mod+Shift+8 move container to workspace 8 +bindsym $mod+Shift+9 move container to workspace 9 +bindsym $mod+Shift+0 move container to workspace 10 +# Note: workspaces can have any name you want, not just numbers. +# We just use 1-10 as the default. # +bindsym print exec file=~/Pictures/Screenshots/Screenshot-$(date '+%Y%m%d%H%M%S').png \ + && grim -g "$(slurp)" $file \ + && wl-copy $file \ + && notify-send -i $file "File copied to clipboard" + +#bindsym $mod+print exec file=~/Pictures/Screenshots/Screenshot-$(date '+%Y%m%d%H%M%S').mp4 \ +## && wf-recorder -g "$(slurp)" $file \ +## && wl-copy $file \ +## && notify-send -i $file "File copied to clipboard" # Layout stuff: # - # You can "split" the current object of your focus with - # $mod+b or $mod+v, for horizontal and vertical splits - # respectively. - bindsym $mod+b splith - bindsym $mod+v splitv - # Switch the current container between different layout styles - bindsym $mod+s layout stacking - bindsym $mod+w layout tabbed - bindsym $mod+e layout toggle split +# You can "split" the current object of your focus with +# $mod+b or $mod+v, for horizontal and vertical splits +# respectively. +bindsym $mod+b splith +bindsym $mod+v splitv - # Make the current focus fullscreen - bindsym $mod+f fullscreen +# Switch the current container between different layout styles +bindsym $mod+s layout stacking +bindsym $mod+w layout tabbed +bindsym $mod+e layout toggle split - # Adding Sticky mode. This will keep a floating window on all screens. - bindsym $mod+Shift+s sticky toggle +# Make the current focus fullscreen +bindsym $mod+f fullscreen - # Toggle the current focus between tiling and floating mode - bindsym $mod+Shift+space floating toggle +# Adding Sticky mode. This will keep a floating window on all screens. +bindsym $mod+Shift+s sticky toggle - # Swap focus between the tiling area and the floating area - bindsym $mod+space focus mode_toggle +# Toggle the current focus between tiling and floating mode +bindsym $mod+Shift+space floating toggle - # move focus to the parent container - bindsym $mod+a focus parent +# Swap focus between the tiling area and the floating area +bindsym $mod+space focus mode_toggle + +# move focus to the parent container +bindsym $mod+a focus parent # # Scratchpad: # - # Sway has a "scratchpad", which is a bag of holding for windows. - # You can send windows there and get them back later. +# Sway has a "scratchpad", which is a bag of holding for windows. +# You can send windows there and get them back later. - # Move the currently focused window to the scratchpad - bindsym $mod+Shift+minus move scratchpad +# Move the currently focused window to the scratchpad +bindsym $mod+Shift+minus move scratchpad - # Show the next scratchpad window or hide the focused scratchpad window. - # If there are multiple scratchpad windows, this command cycles through them. - bindsym $mod+minus scratchpad show +# Show the next scratchpad window or hide the focused scratchpad window. +# If there are multiple scratchpad windows, this command cycles through them. +bindsym $mod+minus scratchpad show # # Resizing containers: # @@ -243,17 +253,16 @@ bindsym $mod+r mode "resize" # # Media Keys # - bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5% - bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5% - bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle - bindsym XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle - bindsym XF86MonBrightnessDown exec brightnessctl set 5%- - bindsym XF86MonBrightnessUp exec brightnessctl set +5% +bindsym XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5% +bindsym XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5% +bindsym XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle +bindsym XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle +bindsym XF86MonBrightnessDown exec brightnessctl set 5%- +bindsym XF86MonBrightnessUp exec brightnessctl set +5% # GTK 3 settings # See https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland for more info. - exec_always ~/.config/sway/import-gsettings \ gtk-theme:gtk-theme-name \ icon-theme:gtk-icon-theme-name \ @@ -264,20 +273,5 @@ exec_always ~/.config/sway/import-gsettings \ bar { swaybar_command waybar } -# -# Read `man 5 sway-bar` for more information about this section. -#bar { -# position top -# -# # When the status_command prints a new line to stdout, swaybar updates. -# # The default just shows the current date and time. -# status_command while date +'%Y-%m-%d %l:%M:%S %p'; do sleep 1; done -# -# colors { -# statusline #ffffff -# background #323232 -# inactive_workspace #32323200 #32323200 #5c5c5c -# } -#} #include /etc/sway/config.d/*