all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* split-window documentation
@ 2004-07-11  9:26 Matthias
  2004-07-12  7:23 ` David Vanderschel
  0 siblings, 1 reply; 4+ messages in thread
From: Matthias @ 2004-07-11  9:26 UTC (permalink / raw)


Hi,

I have written a function to setup a window configuration I find
useful. But when working in a terminal with a small text height, the
function `split-window' may return the following error:

 Window height 3 too small (after splitting)

This feature is not documented in the elisp manual nor the doc spec of
`split-window'. May one give me some information so that I can add
some test in my function?

Here is the function (any comment welcome):

(defun alt-setup-configuration ()
  (interactive)
  (if (window-configuration-p (car (get-register ?1)))
      (jump-to-register ?1)
    (when (not (one-window-p t))
      (delete-other-windows (get-largest-window)))
    (let ((window1 (selected-window))
          (window2 (split-window nil 28))
          (window3 (split-window nil 34 t)))
      (save-excursion
        (diary)
        (when (not (gnus-alive-p))
          (gnus))
        (list-buffers t))
      (set-window-buffer window1 "*Group*")
      (set-window-buffer window2 "*Buffer List*")
      (set-window-point window2 (point-min))
      (set-window-buffer window3 "*Fancy Diary Entries*")
      (window-configuration-to-register ?1))))

Thank you for your help,
-- 
Matthias

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-07-12 20:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-11  9:26 split-window documentation Matthias
2004-07-12  7:23 ` David Vanderschel
2004-07-12  8:34   ` Matthias
2004-07-12 20:41     ` Kevin Rodgers

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.