Advertisement
shutdown57

i3config

Oct 6th, 2017
225
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 16.82 KB | None | 0 0
  1. # i3 config file (v4)
  2. # Please see http://i3wm.org/docs/userguide.html for a complete reference!
  3.  
  4. # Set mod key (Mod1=<Alt>, Mod4=<Super>)
  5. set $mod Mod4
  6.  
  7. # set default desktop layout (default is tiling)
  8. # workspace_layout tabbed <stacking|tabbed>
  9.  
  10. # Configure border style <normal|1pixel|pixel xx|none|pixel>
  11. new_window pixel 4
  12. new_float pixel 4
  13.  
  14. # Hide borders
  15. hide_edge_borders none
  16.  
  17. # change borders
  18. bindsym $mod+u border none
  19. bindsym $mod+y border pixel 1
  20. bindsym $mod+n border normal
  21.  
  22. # Font for window titles. Will also be used by the bar unless a different font
  23. # is used in the bar {} block below.
  24. font xft:Noto Sans 10
  25.  
  26. # Use Mouse+$mod to drag floating windows
  27. floating_modifier $mod
  28.  
  29. # start a terminal
  30. bindsym $mod+Return exec terminal
  31.  
  32. # kill focused window
  33. bindsym $mod+Shift+q kill
  34.  
  35. # start program launcher
  36. bindsym $mod+d exec --no-startup-id dmenu_recency
  37.  
  38. # launch categorized menu
  39. bindsym $mod+z exec --no-startup-id morc_menu
  40.  
  41. ################################################################################################
  42. ## sound-section - DO NOT EDIT if you wish to automatically upgrade Alsa -> Pulseaudio later! ##
  43. ################################################################################################
  44.  
  45. exec --no-startup-id volumeicon
  46. bindsym $mod+Ctrl+m exec terminal -e 'alsamixer'
  47. #exec --no-startup-id pulseaudio
  48. #exec --no-startup-id pa-applet
  49. #bindsym $mod+Ctrl+m exec pavucontrol
  50.  
  51. ################################################################################################
  52.  
  53. # Screen brightness controls
  54. # bindsym XF86MonBrightnessUp exec "xbacklight -inc 10; notify-send 'brightness up'"
  55. # bindsym XF86MonBrightnessDown exec "xbacklight -dec 10; notify-send 'brightness down'"
  56.  
  57. # Start Applications
  58. bindsym $mod+Ctrl+b exec terminal -e 'bmenu'
  59. bindsym $mod+F2 exec palemoon
  60. bindsym $mod+F3 exec pcmanfm
  61. # bindsym $mod+F3 exec ranger
  62. bindsym $mod+Shift+F3 exec gksu pcmanfm
  63. bindsym $mod+F5 exec terminal -e 'mocp'
  64. bindsym $mod+t exec --no-startup-id pkill compton
  65. bindsym $mod+Ctrl+t exec --no-startup-id compton -b
  66. bindsym $mod+Shift+d --release exec "killall dunst; exec notify-send 'restart dunst'"
  67. bindsym Print exec --no-startup-id i3-scrot
  68. bindsym $mod+Print --release exec --no-startup-id i3-scrot -w
  69. bindsym $mod+Shift+Print --release exec --no-startup-id i3-scrot -s
  70. bindsym $mod+Shift+h exec xdg-open /usr/share/doc/manjaro/i3_help.pdf
  71. bindsym $mod+Ctrl+x --release exec --no-startup-id xkill
  72.  
  73. # focus_follows_mouse no
  74.  
  75. # change focus
  76. bindsym $mod+j focus left
  77. bindsym $mod+k focus down
  78. bindsym $mod+l focus up
  79. bindsym $mod+semicolon focus right
  80.  
  81. # alternatively, you can use the cursor keys:
  82. bindsym $mod+Left focus left
  83. bindsym $mod+Down focus down
  84. bindsym $mod+Up focus up
  85. bindsym $mod+Right focus right
  86.  
  87. # move focused window
  88. bindsym $mod+Shift+j move left
  89. bindsym $mod+Shift+k move down
  90. bindsym $mod+Shift+l move up
  91. bindsym $mod+Shift+semicolon move right
  92.  
  93. # alternatively, you can use the cursor keys:
  94. bindsym $mod+Shift+Left move left
  95. bindsym $mod+Shift+Down move down
  96. bindsym $mod+Shift+Up move up
  97. bindsym $mod+Shift+Right move right
  98.  
  99. # workspace back and forth (with/without active container)
  100. workspace_auto_back_and_forth yes
  101. bindsym $mod+b workspace back_and_forth
  102. bindsym $mod+Shift+b move container to workspace back_and_forth; workspace back_and_forth
  103.  
  104. # split orientation
  105. bindsym $mod+h split h;exec notify-send 'tile horizontally'
  106. bindsym $mod+v split v;exec notify-send 'tile vertically'
  107. bindsym $mod+q split toggle
  108.  
  109. # toggle fullscreen mode for the focused container
  110. bindsym $mod+f fullscreen toggle
  111.  
  112. # change container layout (stacked, tabbed, toggle split)
  113. bindsym $mod+s layout stacking
  114. bindsym $mod+w layout tabbed
  115. bindsym $mod+e layout toggle split
  116.  
  117. # toggle tiling / floating
  118. bindsym $mod+Shift+space floating toggle
  119.  
  120. # change focus between tiling / floating windows
  121. bindsym $mod+space focus mode_toggle
  122.  
  123. # toggle sticky
  124. bindsym $mod+Shift+s sticky toggle
  125.  
  126. # focus the parent container
  127. bindsym $mod+a focus parent
  128.  
  129. # move the currently focused window to the scratchpad
  130. bindsym $mod+Shift+minus move scratchpad
  131.  
  132. # Show the next scratchpad window or hide the focused scratchpad window.
  133. # If there are multiple scratchpad windows, this command cycles through them.
  134. bindsym $mod+minus scratchpad show
  135.  
  136. #navigate workspaces next / previous
  137. bindsym $mod+Ctrl+Right workspace next
  138. bindsym $mod+Ctrl+Left workspace prev
  139.  
  140. # Workspace names
  141. # to display names or symbols instead of plain workspace numbers you can use
  142. # something like: set $ws1 1:mail
  143. # set $ws2 2:
  144. set $ws1 1
  145. set $ws2 2
  146. set $ws3 3
  147. set $ws4 4
  148. set $ws5 5
  149. set $ws6 6
  150. set $ws7 7
  151. set $ws8 8
  152.  
  153. # switch to workspace
  154. bindsym $mod+1 workspace $ws1
  155. bindsym $mod+2 workspace $ws2
  156. bindsym $mod+3 workspace $ws3
  157. bindsym $mod+4 workspace $ws4
  158. bindsym $mod+5 workspace $ws5
  159. bindsym $mod+6 workspace $ws6
  160. bindsym $mod+7 workspace $ws7
  161. bindsym $mod+8 workspace $ws8
  162.  
  163. # Move focused container to workspace
  164. bindsym $mod+Ctrl+1 move container to workspace $ws1
  165. bindsym $mod+Ctrl+2 move container to workspace $ws2
  166. bindsym $mod+Ctrl+3 move container to workspace $ws3
  167. bindsym $mod+Ctrl+4 move container to workspace $ws4
  168. bindsym $mod+Ctrl+5 move container to workspace $ws5
  169. bindsym $mod+Ctrl+6 move container to workspace $ws6
  170. bindsym $mod+Ctrl+7 move container to workspace $ws7
  171. bindsym $mod+Ctrl+8 move container to workspace $ws8
  172.  
  173. # Move to workspace with focused container
  174. bindsym $mod+Shift+1 move container to workspace $ws1; workspace $ws1
  175. bindsym $mod+Shift+2 move container to workspace $ws2; workspace $ws2
  176. bindsym $mod+Shift+3 move container to workspace $ws3; workspace $ws3
  177. bindsym $mod+Shift+4 move container to workspace $ws4; workspace $ws4
  178. bindsym $mod+Shift+5 move container to workspace $ws5; workspace $ws5
  179. bindsym $mod+Shift+6 move container to workspace $ws6; workspace $ws6
  180. bindsym $mod+Shift+7 move container to workspace $ws7; workspace $ws7
  181. bindsym $mod+Shift+8 move container to workspace $ws8; workspace $ws8
  182.  
  183. # Open applications on specific workspaces
  184. # assign [class="Thunderbird"] $ws1
  185. # assign [class="Pale moon"] $ws2
  186. # assign [class="Pcmanfm"] $ws3
  187. # assign [class="Skype"] $ws5
  188.  
  189. # Open specific applications in floating mode
  190. for_window [title="alsamixer"] floating enable border pixel 1
  191. for_window [class="Calamares"] floating enable border normal
  192. for_window [class="Clipgrab"] floating enable
  193. for_window [title="File Transfer*"] floating enable
  194. for_window [class="Galculator"] floating enable border pixel 1
  195. for_window [class="GParted"] floating enable border normal
  196. for_window [title="i3_help"] floating enable sticky enable border normal
  197. for_window [class="Lightdm-gtk-greeter-settings"] floating enable
  198. for_window [class="Lxappearance"] floating enable sticky enable border normal
  199. for_window [class="Manjaro-hello"] floating enable
  200. for_window [class="Manjaro Settings Manager"] floating enable border normal
  201. for_window [title="MuseScore: Play Panel"] floating enable
  202. for_window [class="Nitrogen"] floating enable sticky enable border normal
  203. for_window [class="Oblogout"] fullscreen enable
  204. for_window [class="octopi"] floating enable
  205. for_window [title="About Pale Moon"] floating enable
  206. for_window [class="Pamac-manager"] floating enable
  207. for_window [class="Pavucontrol"] floating enable
  208. for_window [class="qt5ct"] floating enable sticky enable border normal
  209. for_window [class="Qtconfig-qt4"] floating enable sticky enable border normal
  210. for_window [class="Simple-scan"] floating enable border normal
  211. for_window [class="(?i)System-config-printer.py"] floating enable border normal
  212. for_window [class="Skype"] floating enable border normal
  213. for_window [class="Thus"] floating enable border normal
  214. for_window [class="Timeset-gui"] floating enable border normal
  215. for_window [class="(?i)virtualbox"] floating enable border normal
  216. for_window [class="Xfburn"] floating enable
  217.  
  218. # switch to workspace with urgent window automatically
  219. for_window [urgent=latest] focus
  220.  
  221. # reload the configuration file
  222. bindsym $mod+Shift+c reload
  223.  
  224. # restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
  225. bindsym $mod+Shift+r restart
  226.  
  227. # exit i3 (logs you out of your X session)
  228. bindsym $mod+Shift+e 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'"
  229.  
  230. # Set shut down, restart and locking features
  231. bindsym $mod+0 mode "$mode_system"
  232. set $mode_system (l)ock, (e)xit, switch_(u)ser, (s)uspend, (h)ibernate, (r)eboot, (Shift+s)hutdown
  233. mode "$mode_system" {
  234. bindsym l exec --no-startup-id i3exit lock, mode "default"
  235. bindsym s exec --no-startup-id i3exit suspend, mode "default"
  236. bindsym u exec --no-startup-id i3exit switch_user, mode "default"
  237. bindsym e exec --no-startup-id i3exit logout, mode "default"
  238. bindsym h exec --no-startup-id i3exit hibernate, mode "default"
  239. bindsym r exec --no-startup-id i3exit reboot, mode "default"
  240. bindsym Shift+s exec --no-startup-id i3exit shutdown, mode "default"
  241.  
  242. # exit system mode: "Enter" or "Escape"
  243. bindsym Return mode "default"
  244. bindsym Escape mode "default"
  245. }
  246.  
  247. # Resize window (you can also use the mouse for that)
  248. bindsym $mod+r mode "resize"
  249. mode "resize" {
  250. # These bindings trigger as soon as you enter the resize mode
  251. # Pressing left will shrink the window’s width.
  252. # Pressing right will grow the window’s width.
  253. # Pressing up will shrink the window’s height.
  254. # Pressing down will grow the window’s height.
  255. bindsym j resize shrink width 5 px or 5 ppt
  256. bindsym k resize grow height 5 px or 5 ppt
  257. bindsym l resize shrink height 5 px or 5 ppt
  258. bindsym semicolon resize grow width 5 px or 5 ppt
  259.  
  260. # same bindings, but for the arrow keys
  261. bindsym Left resize shrink width 10 px or 10 ppt
  262. bindsym Down resize grow height 10 px or 10 ppt
  263. bindsym Up resize shrink height 10 px or 10 ppt
  264. bindsym Right resize grow width 10 px or 10 ppt
  265.  
  266. # exit resize mode: Enter or Escape
  267. bindsym Return mode "default"
  268. bindsym Escape mode "default"
  269. }
  270.  
  271. # Lock screen
  272. bindsym $mod+9 exec --no-startup-id blurlock
  273.  
  274. # Autostart applications
  275. exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
  276. exec --no-startup-id nitrogen --restore; sleep 1; compton -b
  277. #exec --no-startup-id manjaro-hello
  278. exec --no-startup-id nm-applet
  279. exec --no-startup-id xfce4-power-manager
  280. exec --no-startup-id pamac-tray
  281. exec --no-startup-id clipit
  282. # exec --no-startup-id blueman
  283. # exec_always --no-startup-id sbxkb
  284. exec --no-startup-id start_conky_grey
  285. # exec --no-startup-id start_conky_green
  286. exec --no-startup-id xautolock -time 10 -locker blurlock
  287. exec_always --no-startup-id ff-theme-util
  288. exec_always --no-startup-id fix_xcursor
  289.  
  290. # Color palette used for the terminal ( ~/.extend.Xresources file )
  291. # Colors are gathered based on the documentation:
  292. # https://i3wm.org/docs/userguide.html#xresources
  293. # Change the variable name at the place you want to match the color
  294. # of your terminal like this:
  295. # [example]
  296. # If you want your bar to have the same background color as your
  297. # terminal background change the line 362 from:
  298. # background $i3_background
  299. # to:
  300. # background $term_background
  301. # Same logic applied to everything else.
  302. set_from_resource $term_background background
  303. set_from_resource $term_foreground foreground
  304. set_from_resource $term_color0 color0
  305. set_from_resource $term_color1 color1
  306. set_from_resource $term_color2 color2
  307. set_from_resource $term_color3 color3
  308. set_from_resource $term_color4 color4
  309. set_from_resource $term_color5 color5
  310. set_from_resource $term_color6 color6
  311. set_from_resource $term_color7 color7
  312. set_from_resource $term_color8 color8
  313. set_from_resource $term_color9 color9
  314. set_from_resource $term_color10 color10
  315. set_from_resource $term_color11 color11
  316. set_from_resource $term_color12 color12
  317. set_from_resource $term_color13 color13
  318. set_from_resource $term_color14 color14
  319. set_from_resource $term_color15 color15
  320.  
  321. # Color palette used for i3
  322. # Variables are set based on the documentation:
  323. # https://i3wm.org/dovs/userguide.html#variables
  324. # Changing the value of one of the variables will
  325. # effect all the areas with the same color.
  326. #set $i3_background #2B2C2B
  327. #set $i3_text #F9FAF9
  328. set $i3_background #141314
  329. set $i3_text #eeeeee
  330. set $i3_separator #454947
  331. set $i3_color1 #f9faf9
  332. set $i3_color2 #595B5B
  333. set $i3_color3 #353836
  334. set $i3_color4 #16A085
  335. set $i3_color5 #FDF6E3
  336. set $i3_color6 #EEE8D5
  337. set $i3_color7 #E5201D
  338. set $i3_color8 #808380
  339. set $i3_color9 #434745
  340. set $i3_color10 #454948
  341. set $i3_color11 #80FFF9
  342. set $i3_color12 #FDF6E3
  343. set $i3_color13 #CB4B16
  344. set $i3_color14 #268BD2
  345. set $i3_color15 #000000
  346. set $i3_color16 #ffffff
  347. set $i3_color17 #0c0c0c
  348.  
  349. # Start i3bar to display a workspace bar (plus the system information i3status if available)
  350. bar {
  351. status_command i3status
  352. position bottom
  353.  
  354. ## please set your primary output first. Example: 'xrandr --output eDP1 --primary'
  355. # tray_output primary
  356. # tray_output eDP1
  357.  
  358. bindsym button4 nop
  359. bindsym button5 nop
  360. font xft:Noto Sans 10.5
  361. strip_workspace_numbers yes
  362.  
  363. colors {
  364. # background $transparent
  365. background #141314
  366. statusline #3DA6FF
  367. separator #3DA6FF
  368.  
  369. # border backgr. text
  370. focused_workspace #141314 #4B4D46 #3DA6FF
  371. active_workspace #141314 #4B4D46 #3DA6FF
  372. inactive_workspace #141314 #4B4D46 #3DA6FF
  373. urgent_workspace #141314 #4B4D46 #3DA6FF
  374. }
  375. }
  376.  
  377. # hide/unhide i3status bar
  378. bindsym $mod+m bar mode toggle
  379.  
  380. # Theme colors
  381. # class border backgr. text indic. child_border
  382. ## client.focused $i3_color8 $i3_color8 $i3_color11 $i3_color12
  383. ## client.focused_inactive $i3_color9 $i3_color9 $i3_color4 $i3_color10
  384. ## client.unfocused $i3_color9 $i3_color9 $i3_color4 $i3_color10
  385. ## client.urgent $i3_color13 $i3_color12 $i3_color4 $i3_color14
  386. ## client.placeholder $i3_color15 $i3_color17 $i3_color16 $i3_color15 $i3_color17
  387.  
  388. ## client.background $i3_background
  389. client.focused #141314 #3da6ff #3da6ff
  390. client.unfocused #141314 #3da6ff #3da6ff
  391. client.focused_inactive #141314 #3da6ff #3da6ff
  392. client.urgent #141314 #3da6ff #3da6ff
  393. focus_follows_mouse yes
  394. hide_edge_borders both
  395.  
  396. #############################
  397. ### settings for i3-gaps: ###
  398. #############################
  399.  
  400. # Set inner/outer gaps
  401. gaps inner 10
  402. gaps outer -4
  403.  
  404. # Additionally, you can issue commands with the following syntax. This is useful to bind keys to changing the gap size.
  405. # gaps inner|outer current|all set|plus|minus <px>
  406. # gaps inner all set 10
  407. # gaps outer all plus 5
  408.  
  409. # Smart gaps (gaps used if only more than one container on the workspace)
  410. smart_gaps on
  411.  
  412. # Smart borders (draw borders around container only if it is not the only container on this workspace)
  413. # on|no_gaps (on=always activate and no_gaps=only activate if the gap size to the edge of the screen is 0)
  414. smart_borders on
  415.  
  416. # Press $mod+Shift+g to enter the gap mode. Choose o or i for modifying outer/inner gaps. Press one of + / - (in-/decrement for current workspace) or 0 (remove gaps for current workspace). If you also press Shift with these keys, the change will be global for all workspaces.
  417. set $mode_gaps Gaps: (o) outer, (i) inner
  418. set $mode_gaps_outer Outer Gaps: +|-|0 (local), Shift + +|-|0 (global)
  419. set $mode_gaps_inner Inner Gaps: +|-|0 (local), Shift + +|-|0 (global)
  420. bindsym $mod+Shift+g mode "$mode_gaps"
  421.  
  422. mode "$mode_gaps" {
  423. bindsym o mode "$mode_gaps_outer"
  424. bindsym i mode "$mode_gaps_inner"
  425. bindsym Return mode "default"
  426. bindsym Escape mode "default"
  427. }
  428. mode "$mode_gaps_inner" {
  429. bindsym plus gaps inner current plus 5
  430. bindsym minus gaps inner current minus 5
  431. bindsym 0 gaps inner current set 0
  432.  
  433. bindsym Shift+plus gaps inner all plus 5
  434. bindsym Shift+minus gaps inner all minus 5
  435. bindsym Shift+0 gaps inner all set 0
  436.  
  437. bindsym Return mode "default"
  438. bindsym Escape mode "default"
  439. }
  440. mode "$mode_gaps_outer" {
  441. bindsym plus gaps outer current plus 5
  442. bindsym minus gaps outer current minus 5
  443. bindsym 0 gaps outer current set 0
  444.  
  445. bindsym Shift+plus gaps outer all plus 5
  446. bindsym Shift+minus gaps outer all minus 5
  447. bindsym Shift+0 gaps outer all set 0
  448.  
  449. bindsym Return mode "default"
  450. bindsym Escape mode "default"
  451. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement