2022-04-22 02:54:47 +00:00
|
|
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
|
|
;; DESKTOP
|
|
|
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
2022-08-26 01:42:23 +00:00
|
|
|
; pdf-tools related stuff
|
|
|
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
|
|
; additional packages
|
|
|
|
(add-to-list 'package-selected-packages
|
|
|
|
'(pdf-tools)
|
|
|
|
)
|
|
|
|
(pdf-tools-install)
|
|
|
|
|
2022-04-22 02:54:47 +00:00
|
|
|
; Personal startup screen (Desktop)
|
|
|
|
; - preferred org agenda as dedicated window at the top of the frame, n lines high
|
|
|
|
; - common org files open in the bottom window
|
|
|
|
(add-hook 'after-init-hook (lambda ()
|
|
|
|
(interactive)
|
2022-08-26 13:59:45 +00:00
|
|
|
(org-agenda nil "r")
|
2022-04-22 02:54:47 +00:00
|
|
|
(set-window-dedicated-p (selected-window) "t")
|
|
|
|
(delete-other-windows)
|
|
|
|
(split-window-below 15)
|
|
|
|
(next-multiframe-window)
|
|
|
|
(find-file "~/org/_index_phone.org")
|
|
|
|
(find-file "~/org/_todo.org")
|
|
|
|
(find-file "~/org/_index.org")
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
; Make sure emacs and org don't keep opening new windows (Desktop)
|
|
|
|
(setq pop-up-windows nil)
|
|
|
|
(setq inhibit-same-window nil)
|
|
|
|
(setq inhibit-switch-frame nil)
|
|
|
|
(setq split-height-threshold 200)
|
|
|
|
(setq split-width-threshold 200)
|
|
|
|
(defun my-display-buffer-function (buf not-this-window)
|
|
|
|
(if (and (not pop-up-frames)
|
|
|
|
(one-window-p)
|
|
|
|
(or not-this-window
|
|
|
|
(not (eq (window-buffer (selected-window)) buf)))
|
|
|
|
(> (frame-width) 162))
|
|
|
|
(split-window-horizontally))
|
|
|
|
;; Note: Some modules sets `pop-up-windows' to t before calling
|
|
|
|
;; `display-buffer' -- Why, oh, why!
|
|
|
|
(let ((display-buffer-function nil)
|
|
|
|
(pop-up-windows nil))
|
|
|
|
(display-buffer buf nil)))
|
|
|
|
|
|
|
|
(setq display-buffer-function 'my-display-buffer-function)
|
2022-08-26 01:42:23 +00:00
|
|
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|