Advertisement
Guest User

Untitled

a guest
Dec 29th, 2020
228
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.33 KB | None | 0 0
  1. # i3 config file (v4)
  2. #
  3. # Please see https://i3wm.org/docs/userguide.html for a complete reference!
  4. #
  5. # This config file uses keycodes (bindsym) and was written for the QWERTY
  6. # layout.
  7. #
  8. # To get a config file with the same key positions, but for your current
  9. # layout, use the i3-config-wizard
  10. #
  11.  
  12. # Font for window titles. Will also be used by the bar unless a different font
  13. # is used in the bar {} block below.
  14. font pango:Fira Code 12
  15.  
  16. # Hide titlebars
  17. default_border pixel 3
  18.  
  19. # Allow space for polybar
  20. gaps top 28
  21.  
  22. # The combination of xss-lock, nm-applet and pactl is a popular choice, so
  23. # they are included here as an example. Modify as you see fit.
  24.  
  25. # xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
  26. # screen before suspend. Use loginctl lock-session to lock your screen.
  27. exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
  28.  
  29. # NetworkManager is the most popular way to manage wireless networks on Linux,
  30. # and nm-applet is a desktop environment-independent system tray GUI for it.
  31. exec --no-startup-id nm-applet
  32.  
  33. # Set super key
  34. set $super Mod4
  35.  
  36. # Startup script
  37. exec $HOME/.scripts/startup
  38.  
  39. # Navigation Keys
  40. set $up k
  41. set $down j
  42. set $left h
  43. set $right l
  44.  
  45. # Drag floating windows
  46. floating_modifier $super
  47.  
  48. # Start terminal
  49. bindsym $super+Return exec $TERMINAL
  50.  
  51. # Kill windows
  52. bindsym $super+w kill
  53. bindsym --release button2 kill
  54.  
  55. # Program launcher
  56. bindsym $super+space exec rofi -show run
  57.  
  58. # Change focus
  59. bindsym $super+$up focus up
  60. bindsym $super+Up focus up
  61. bindsym $super+$down focus down
  62. bindsym $super+Down focus down
  63. bindsym $super+$left focus left
  64. bindsym $super+Left focus left
  65. bindsym $super+$right focus right
  66. bindsym $super+Right focus right
  67.  
  68. # Move focused window
  69. bindsym $super+Shift+$up move up
  70. bindsym $super+Shift+Up move up
  71. bindsym $super+Shift+$down move down
  72. bindsym $super+Shift+Down move down
  73. bindsym $super+Shift+$left move left
  74. bindsym $super+Shift+Left move left
  75. bindsym $super+Shift+$right move right
  76. bindsym $super+Shift+Right move right
  77.  
  78. # Split in horizontal orientation
  79. bindsym $super+Control+space split v
  80. bindsym $super+Control+Return split h
  81.  
  82. # Enter fullscreen mode for the focused container
  83. bindsym $super+shift+f fullscreen toggle
  84.  
  85. # Change container layout
  86. bindsym $super+t split toggle, layout tabbed
  87. bindsym $super+Shift+t layout toggle split
  88.  
  89. # Toggle tiling / floating
  90. bindsym $super+s floating toggle
  91.  
  92. # Change focus between tiling / floating windows
  93. bindsym $super+shift+s focus mode_toggle
  94.  
  95. # Focus the parent container
  96. bindsym $super+a focus parent
  97.  
  98. # Focus the child container
  99. bindsym $super+d focus child
  100.  
  101. # Move the currently focused window to the scratchpad
  102. bindsym $super+Shift+minus move scratchpad
  103.  
  104. # Switch between workspaces
  105. bindsym $super+i exec $HOME/.scripts/i3-goto-workspace -1
  106. bindsym $super+o exec $HOME/.scripts/i3-goto-workspace 1
  107. bindsym $super+Shift+i exec $HOME/.scripts/i3-move-container-to-workspace -1
  108. bindsym $super+Shift+o exec $HOME/.scripts/i3-move-container-to-workspace 1
  109.  
  110. # Show the next scratchpad window or hide the focused scratchpad window.
  111. # If there are multiple scratchpad windows, this command cycles through them.
  112. bindsym $super+minus scratchpad show
  113.  
  114. # Reload the configuration file
  115. bindsym $super+BackSpace reload
  116.  
  117. # Restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
  118. bindsym $super+Shift+BackSpace restart
  119.  
  120. # Exit i3 (logs you out of your X session)
  121. bindsym $super+Control+Shift+BackSpace exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"
  122.  
  123. # Program shortcuts
  124. bindsym $super+1 exec $TERMINAL -e $FILE
  125. bindsym $super+Shift+Control+1 exec $FILEGUI
  126. bindsym $super+2 exec $BROWSER
  127. bindsym $super+3 exec $TERMINAL -e ncmpcpp
  128.  
  129. # Bind multimedia keys
  130. set $refresh_i3status killall -SIGUSR1 i3status
  131. bindsym XF86AudioRaiseVolume exec pulseaudio-ctl up
  132. bindsym XF86AudioLowerVolume exec pulseaudio-ctl down
  133. bindsym XF86AudioMute exec pulseaudio-ctl mute
  134. bindsym XF86AudioPlay exec mpc toggle
  135. bindsym XF86AudioPrev exec mpc prev
  136. bindsym XF86AudioNext exec mpc next
  137. bindsym Print exec $HOME/.scripts/screenshot
  138.  
  139. # Resize window (you can also use the mouse for that)
  140. mode "resize" {
  141. # These bindings trigger as soon as you enter the resize mode
  142.  
  143. # Pressing left will shrink the window’s width.
  144. # Pressing right will grow the window’s width.
  145. # Pressing up will shrink the window’s height.
  146. # Pressing down will grow the window’s height.
  147. bindsym $left resize shrink width 10 px or 10 ppt
  148. bindsym $down resize grow height 10 px or 10 ppt
  149. bindsym $up resize shrink height 10 px or 10 ppt
  150. bindsym $right resize grow width 10 px or 10 ppt
  151.  
  152. # Same bindings, but for the arrow keys
  153. bindsym Left resize shrink width 10 px or 10 ppt
  154. bindsym Down resize grow height 10 px or 10 ppt
  155. bindsym Up resize shrink height 10 px or 10 ppt
  156. bindsym Right resize grow width 10 px or 10 ppt
  157.  
  158. # Back to normal: Enter or Escape or $super+r
  159. bindsym Return mode "default"
  160. bindsym Escape mode "default"
  161. bindsym $super+r mode "default"
  162. }
  163.  
  164. bindsym $super+r mode "resize"
  165.  
  166. # Start polybar
  167. exec_always --no-startup-id $HOME/.config/polybar/scripts/start-poly.sh
  168.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement