help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Use *scratch* for startup messages?


From: Christopher Schmidt
Subject: Re: Use *scratch* for startup messages?
Date: Wed, 9 Jan 2013 23:53:44 +0000 (GMT)

Florian Lindner <address@hidden> writes:
> I have (setq inhibit-startup-message t) so I start up with the
> *scratch* buffer which I hardly ever use. A thought crossed my mind to
> use this buffer as a output for some user generated start up messages,
> such as org-mode's TODO list or content of refile buffer, ...
>
> So when Emacs starts, it presents a scratch buffer with my current
> TODO list. All other properties of the buffer keep the same (like it's
> not being saved).
>
> Since I consider myself still novice with Emacs I'm unsure how to
> program that into my .emacs and if there problems with this to be
> expected....

with-current-buffer should be fine.

    (with-current-buffer "*scratch*"
      (insert "Ich bin im Skratsch"))

    (with-current-buffer "*scratch*"
      (insert
       (save-window-excursion
         (org-agenda-list)
         (buffer-string))))

        Christopher



reply via email to

[Prev in Thread] Current Thread [Next in Thread]