summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemsen2012-09-17 19:51:59 +0200
committerGravatar Tom Willemsen2012-09-17 19:51:59 +0200
commit7a9412b11fcf044572ea7e7d8d550f5ad5085d39 (patch)
tree16e76ca31deba81d13263889f189e6bee16cc276
parent5857c6138296743b464d8a748dc40400143bdab4 (diff)
downloadbw-7a9412b11fcf044572ea7e7d8d550f5ad5085d39.tar.gz
bw-7a9412b11fcf044572ea7e7d8d550f5ad5085d39.zip
Add some instructions
Don't `local-set-key' either, doesn't do anything anymore.
-rw-r--r--bw.el31
1 files changed, 27 insertions, 4 deletions
diff --git a/bw.el b/bw.el
index 0c4844d..453c1ab 100644
--- a/bw.el
+++ b/bw.el
@@ -21,7 +21,31 @@
;;; Commentary:
-;; Show stuff in a bottom window.
+;; Show stuff in a bottom window. The idea is taken from ide-skel,
+;; which is a very nice extension, but doesn't fit into my workflow at
+;; all, the only really nice thing is that all *buffers* appear in a
+;; specialized window.
+
+;;; Usage:
+
+;; Make sure it's loadable, you should be able to do this by using:
+
+;; M-x package-install-file RET /path/to/bw.el RET
+
+;; or if you don't use package.el you could use:
+
+;; (add-to-list 'load-path "/path/to/bw/directory")
+;; (require 'bw)
+
+;; Once that is done you can set it up for use:
+
+;; (add-to-list 'display-buffer-alist
+;; '("^\\*.*\\*$"
+;; . ((bw-display-in-bottom-window . nil)))
+
+;; And perhaps even bind a key to it:
+
+;; (global-set-key (kbd "<f11>") 'bw-toggle-bottom-window)
;;; Code:
@@ -58,16 +82,14 @@
(window-list))
win))
+;;;###autoload
(defun bw-display-in-bottom-window (buffer alist)
"Show BUFFER in the bottom window, discard ALIST."
(let ((win (or (bw-get-window) (bw-create-window))))
(set-window-buffer win buffer)
(setq bw-last-shown-buffer buffer)
- (local-set-key (kbd "C-c C-q") 'delete-window)
win))
-(add-to-list 'display-buffer-alist
- '("^\\*.*\\*$" . ((bw-display-in-bottom-window . nil))))
(add-to-list 'window-persistent-parameters (cons 'bw-bottom t))
(defun bw-find-appropriate-buffer ()
@@ -83,6 +105,7 @@
(setq buffer "*scratch*"))
buffer))
+;;;###autoload
(defun bw-toggle-bottom-window ()
"Either show or delete the bottom window."
(interactive)