;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- ;; Place your private configuration here! Remember, you do not need to run 'doom ;; sync' after modifying this file! ;; Some functionality uses this to identify you, e.g. GPG configuration, email ;; clients, file templates and snippets. (setq user-full-name "qvalentin" user-mail-address "dev@filefighter.de") ;; Doom exposes five (optional) variables for controlling fonts in Doom. Here ;; are the three important ones: ;; ;; + `doom-font' ;; + `Doom-Variable -pitch-font' ;; + `doom-big-font' -- used for `doom-big-font-mode'; use this for ;; presentations or streaming. ;; ;; They all accept either a font-spec, font string ("Input Mono-12"), or xlfd ;; font string. You generally only need these two: ;; (setq doom-font (font-spec :family "monospace" :size 12 :weight 'semi-light) ;; doom-variable-pitch-font (font-spec :family "sans" :size 13)) ;; There are two ways to load a theme. Both assume the theme is installed and ;; available. You can either set `doom-theme' or manually load a theme with the ;; `load-theme' function. This is the default: (setq doom-theme 'ewal-doom-one) ;; If you use `org' and don't want your org files in the default location below, ;; change `org-directory'. It must be set before org loads! (setq org-directory "~/org/") ;; This determines the style of line numbers in effect. If set to `nil', line ;; numbers are disabled. For relative line numbers, set this to `relative'. (setq display-line-numbers-type t) (setq fancy-splash-image (concat doom-private-dir "splash/mfdoom.png")) ;; Here are some additional functions/macros that could help you configure Doom: ;; ;; - `load!' for loading external *.el files relative to this one ;; - `use-package!' for configuring packages ;; - `after!' for running code after a package has loaded ;; - `add-load-path!' for adding directories to the `load-path', relative to ;; this file. Emacs searches the `load-path' when you load packages with ;; `require' or `use-package'. ;; - `map!' for binding new keys ;; ;; To get information about any of these functions/macros, move the cursor over ;; the highlighted symbol at press 'K' (non-evil users must press 'C-c c k'). ;; This will open documentation for it, including demos of how they are used. ;; ;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how ;; they are implemented. ;; (require 'exec-path-from-shell) ;; (when (display-graphic-p) ;; (exec-path-from-shell-initialize)) (map! :leader :desc "Comment Block" "c b" #'comment-region) (map! :leader :desc "Uncomment Block" "c B" #'uncomment-region) (map! :leader :desc "Magit Pull from upsteam" "g p" #'magit-pull-from-upstream) (map! :leader :desc "Magit Push" "g P" #'magit-push-current-to-pushremote) (require 'ox-latex) (add-to-list 'org-latex-packages-alist '("" "minted")) (add-to-list 'org-latex-packages-alist '("" "listingsutf8")) (setq org-latex-listings 'minted) (setq org-latex-pdf-process '("pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f" "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f")) (org-babel-do-load-languages 'org-babel-load-languages '((ditaa . t))) ; this line activates ditaa (after! ob-ditaa (setq! org-ditaa-jar-path "/usr/share/java/ditaa/ditaa-0.11.jar")) ;; Spelling stuff (setq ispell-program-name "hunspell" ; Use hunspell to correct mistakes ispell-dictionary "de_DE") ; Default dictionary to use (add-to-list 'ispell-skip-region-alist '("#\\+BEGIN_SRC" . "#\\+END_SRC")) (defun save-all () (interactive) (save-some-buffers t)) (add-hook 'deselect-frame-hook 'save-all) (defadvice! fix-centaur-tabs-project-name () :override #'centaur-tabs-project-name (let ((project-name (car (last (project-current))))) (if project-name (format "Project: %s" (expand-file-name project-name)) centaur-tabs-common-group-name))) ;; Centaur Tabs config, because the defaults are pretty ok (setq x-underline-at-descent-line t) ;; dependency for tab-set-bar under (setq centaur-tabs-set-bar 'under) (setq centaur-tabs-style "slant") ;; Fix Centaur Tabs when changing the theme (after! centaur-tabs (add-hook! 'doom-load-theme-hook (defun +tab-refresh-all-the-things-h () (setq centaur-tabs-active-bar (centaur-tabs--make-xpm 'centaur-tabs-active-bar-face 2 centaur-tabs-bar-height) centaur-tabs-background-color (face-background 'centaur-tabs-default)) (centaur-tabs-separator-reset-cache) (centaur-tabs-init-tabsets-store) (centaur-tabs-display-update) (centaur-tabs-headline-match) )))