Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lisp 0.89 KB | None | 0 0
  1. (defun my-window-setup (pane-number)
  2.   "Creates favourite window layout.
  3.  
  4.  Prompts user for choice of either two or three panes."
  5.   (interactive "nNumber of panes: ")
  6.   (cond ((eq pane-number 3)
  7.          ((delete-other-windows)
  8.           (split-window-horizontally)
  9.           (split-window-horizontally)
  10.           (windmove-right)
  11.           (windmove-right)
  12.           (balance-windows)
  13.           (split-window-vertically)
  14.           (windmove-left)
  15.           (windmove-left)))
  16.         ((eq pane-number 2)
  17.          ((delete-other-windows)
  18.           (split-window-horizontally)
  19.           (windmove-right)
  20.           (balance-windows)
  21.           (split-window-vertically)
  22.           (windmove-left)))))
  23.  
  24. (defun my-2-window-setup ()
  25.   (interactive)
  26.   (delete-other-windows)
  27.   (split-window-horizontally)
  28.   (windmove-right)
  29.   (balance-windows)
  30.   (split-window-vertically)
  31.   (windmove-left))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement