emacs.d/bundle/bundle--gui.el

182 lines
6.1 KiB
EmacsLisp
Raw Normal View History

2024-04-14 15:37:06 +02:00
(setq-default mode-line-format
'("%e" mode-line-front-space "%b %*%n %I %l:%c %p" (vc-mode vc-mode) " " mode-line-modes mode-line-misc-info mode-line-end-spaces))
(unless (memq 'hs-headline mode-line-format)
(setq mode-line-format
(append '(" " hs-headline) mode-line-format)))
(set-face-attribute 'mode-line nil
:slant 'italic
:weight 'bold
:background (face-attribute 'default :background)
:foreground
(cond ((member 'doom-one custom-enabled-themes) "#5B6268")
((member 'doom-nord custom-enabled-themes) "#9099AB")
(t (face-attribute 'mode-line-inactive :foreground)))
:box '(:line-width (1 . 8) :style flat-button))
(set-face-attribute 'mode-line-inactive nil
:inherit 'mode-line
:weight 'normal
:box '(:line-width (1 . 8) :style flat-button))
(use-package tab-bar
:custom
(tab-bar-auto-width nil)
(tab-bar-auto-width-max '(250 25))
(tab-bar-format '(tab-bar-format-history tab-bar-format-tabs-groups))
(tab-bar-tab-name-function 'tab-bar-tab-name-truncated)
2024-04-16 14:05:22 +02:00
(tab-bar-close-button-show nil)
(tab-bar-new-button-show nil)
2024-04-14 15:37:06 +02:00
:config
(set-face-attribute 'tab-bar nil
:inherit 'mode-line-inactive
:background (face-attribute 'mode-line-inactive :background))
(set-face-attribute 'tab-bar-tab nil
:inherit 'mode-line
:foreground (face-attribute 'mode-line :foreground)
:box '(:line-width 8 :style flat-button))
(set-face-attribute 'tab-bar-tab-inactive nil
:inherit 'mode-line-inactive
:box '(:line-width 8 :style flat-button)))
2023-11-03 11:20:40 +01:00
2023-10-04 19:58:04 +02:00
(setq default-frame-alist
2023-11-01 20:56:03 +01:00
`((font . "MonoLisa-11")
2024-01-02 17:33:02 +01:00
(width . 85)
(height . 50)
(vertical-scroll-bars)
,@(cond ((eq system-type 'gnu/linux)
'((fullscreen . maximized)
2024-08-18 22:03:46 +02:00
(undecorated . t))))))
2023-10-07 16:17:00 +02:00
2023-10-07 12:23:57 +02:00
(setq frame-resize-pixelwise t)
(defun center-frame (&optional frame)
"Center FRAME on the screen."
(interactive)
(let ((frame (or frame (selected-frame))))
(let ((frame-width (frame-pixel-width frame))
(frame-height (frame-pixel-height frame))
(display-width (display-pixel-width))
(display-height (display-pixel-height)))
(set-frame-position frame
(/ (- display-width frame-width) 2)
(/ (- display-height frame-height) 2)))))
2024-04-14 15:37:06 +02:00
(add-hook 'after-make-frame-functions #'center-frame)
2023-10-07 12:23:57 +02:00
2024-01-02 17:33:02 +01:00
(use-package all-the-icons
:commands all-the-icons-install-fonts
:init
(unless (find-font (font-spec :name "all-the-icons"))
(all-the-icons-install-fonts t)))
(use-package all-the-icons-dired
:after all-the-icons
2024-01-02 17:33:02 +01:00
:hook (dired-mode . all-the-icons-dired-mode))
(use-package emojify
2024-03-30 10:33:45 +01:00
:hook (erc-mode . emojify-mode)
:commands emojify-mode
2024-01-02 17:33:02 +01:00
:config
(when (member "Segoe UI Emoji" (font-family-list))
;; https://ianyepan.github.io/posts/emacs-emojis/
(set-fontset-font t 'symbol (font-spec :family "Segoe UI Emoji") nil 'prepend)
(setq emojify-display-style 'unicode)
(setq emojify-emoji-styles '(unicode))))
2023-11-09 07:48:42 +01:00
;; (defun my-vc-info ()
;; (when vc-mode
;; (concat (substring vc-mode 5)
;; " ["
;; (substring (vc-working-revision (buffer-file-name)) 0 8)
;; "] ")))
;; (defun my-project-name ()
;; (let ((proj (project-current)))
;; (if proj (file-name-base (directory-file-name (project-root proj)))
;; "NoProject")))
2023-10-25 08:56:55 +02:00
;; (setq-default header-line-format
;; (list "-%M"
;; '(:eval (my-project-name)) " "
;; system-name " " user-login-name " "
;; "-%-"))
;; (setq-default mode-line-format
;; (list "-%b %*%n %I %l:%c %p "
;; '(:eval mode-name) " "
;; '(:eval (my-vc-info))
;; '(:eval (if mode-line-process (concat ":" mode-line-process " ") ""))
;; 'default-directory
;; "-%-"))
2023-11-09 07:48:42 +01:00
;; (set-face-attribute 'mode-line nil :weight 'bold)
;; (set-face-attribute 'header-line nil :weight 'bold)
2023-12-27 14:03:56 +01:00
;; (use-package doom-modeline
;; :hook (after-init . doom-modeline-mode)
;; :custom
;; (doom-modeline-height 30)
;; (doom-modeline-bar-width 4)
;; (doom-modeline-icon nil)
;; (doom-modeline-major-mode-icon nil)
;; (doom-modeline-unicode-fallback nil)
;; (doom-modeline-minor-modes nil)
;; (doom-modeline-buffer-encoding nil)
;; (doom-modeline-battery nil))
2022-05-06 19:31:15 +02:00
(use-package helpful
2023-10-02 11:52:21 +02:00
:commands (helpful-callable helpful-variable helpful-command helpful-key)
:bind ([remap describe-command] . helpful-command) ([remap describe-key] . helpful-key))
2024-04-14 15:37:06 +02:00
(use-package rainbow-delimiters
:hook (prog-mode . rainbow-delimiters-mode))
2022-05-06 19:31:15 +02:00
(use-package olivetti
2023-10-02 11:52:21 +02:00
:custom (olivetti-body-width 83)
:bind ("<f6>" . olivetti-mode))
2023-10-02 11:52:21 +02:00
(add-hook 'Info-mode-hook
(lambda ()
(make-local-variable 'olivetti-body-width)
(setq olivetti-body-width 75)
(olivetti-mode)))
2023-08-18 19:10:32 +02:00
(use-package ace-window :init (global-set-key (kbd "M-o") 'ace-window))
2023-02-02 20:53:53 +01:00
;; (use-package vertico :init (vertico-mode))
2022-05-06 19:31:15 +02:00
(use-package webjump
2023-10-02 11:52:21 +02:00
:bind ("C-c j" . webjump)
:custom
(webjump-sites
(append '(("Wikipedia_de" . [simple-query "de.wikipedia.org" "https://de.wikipedia.org/wiki/" ""])
("leo.org" . [simple-query "dict.leo.org" "https://dict.leo.org/german-english/" ""]))
webjump-sample-sites)))
2023-10-07 16:13:28 +02:00
(use-package doc-view
:ensure nil
:custom
(doc-view-dvipdfm-program "mutool")
(doc-view-odf->odf-converter-program "soffice")
(dov-view-odf->pdf-converter-function 'doc-view-odf->pdf-converter-soffice)
(doc-view-pdf->png-converter-function 'doc-view-pdf->png-converter-mupdf)
2023-12-07 16:57:15 +01:00
(doc-view-resolution 300))
2023-12-11 18:09:49 +01:00
(use-package yasnippet
:init
(yas-global-mode 1))
2024-04-04 15:27:18 +02:00
2024-05-04 14:48:17 +02:00
;(pixel-scroll-precision-mode +1)
2024-04-14 15:37:06 +02:00
(use-package hideshow
2024-05-22 09:21:53 +02:00
:hook ((prog-mode . (lambda () (hs-minor-mode 1))))
2024-04-14 15:37:06 +02:00
:bind (:map prog-mode-map
("M-<return>" . hs-toggle-hiding))
:custom
2024-04-22 09:36:19 +02:00
(hs-allow-nesting t))
2024-06-22 20:41:43 +02:00
(add-hook 'prog-mode-hook (lambda () (setq line-spacing 4)))