4

I want to replace the welcome screen with the calendar.

I've tried adding (calendar) to my .emacs but it opens calendar in addition to the welcome screen not instead of it.


EDIT: I'm trying what is suggested by @Drew, I press M-x customize-option and then enter initial-buffer-choice. Which brings me here.

enter image description here

Would I enter the Calendar command on this page, or did something go wrong?

Philip Kirkbride
  • 557
  • 5
  • 14
  • Choose `Value Menu` to see the possibilities. Refer to my answer for more info, including this: *ensure that when you start up Emacs the necessary **function has been defined** or the named **buffer has been created***. And read the relevant manual section. IOW, find out about this and understand it before you try to use Customize to set the value. – Drew Aug 14 '17 at 14:34

3 Answers3

9

You can customize option initial-buffer-choice (using M-x customize-option).

The value can be a buffer name (the name of your calendar buffer, if it exists - e.g. "*Calendar*") or a function that returns a buffer. The buffer is displayed in place of the welcome (aka "splash") screen.

It is of course up to you to ensure that when you start up Emacs the necessary function has been defined or the named buffer has been created.

See the Emacs manual, node Entering Emacs.

Drew
  • 75,699
  • 9
  • 109
  • 225
1

I hope so ...

  • You should append into ~/.emacs file, as a first line, next command:(setq inhibit-splash-screen t) ;; it'll disable splash screen
  • At the end of ~/.emacs join the next sequence:
    (let ((buffer-cal "\*Calendar\*"))
      ;;
      ;; next commands:
      ;;
      ;; create calendar and pass focus to it
      ;;
      (and
       (calendar) (bufferp (get-buffer buffer-cal))
       (switch-to-buffer buffer-cal)
       )
      (delete-other-windows)
    )
    
Stefan
  • 26,154
  • 3
  • 46
  • 84
joe
  • 27
  • 2
1

If you use org-agenda you can try the extension Emacs Dashboard. https://github.com/rakanalh/emacs-dashboard

msel
  • 19
  • 1
  • 1
    Please consider elaborating - describe what the solution provided by that link does - how it solves the problem. So far, this is a link-only answer, which thus risks being deleted. – Drew Aug 17 '17 at 15:28