From 88d382c1ae4cb25fedf259cfd76774bc28db9f8b Mon Sep 17 00:00:00 2001 From: Tristan Druyen Date: Mon, 17 Mar 2025 23:19:48 +0100 Subject: [PATCH] Remove tab customization --- ext/doom/config.el | 150 ++++++++++++++++++++++----------------------- ext/doom/init.el | 2 +- 2 files changed, 76 insertions(+), 76 deletions(-) diff --git a/ext/doom/config.el b/ext/doom/config.el index feda49a..0ce54b9 100644 --- a/ext/doom/config.el +++ b/ext/doom/config.el @@ -252,89 +252,89 @@ (setq! uniquify-separator "/") (setq! uniquify-buffer-name-style 'forward) -(use-package centaur-tabs - :init - (setq centaur-tabs-enable-key-bindings t) - :config - (setq centaur-tabs-style "wave" - centaur-tabs-height 32 - centaur-tabs-set-icons t - centaur-tabs-show-new-tab-button t - centaur-tabs-show-navigation-buttons t - centaur-tabs-set-bar 'under - centaur-tabs-show-count t - centaur-tabs-gray-out-icons 'buffer - x-underline-at-descent-line t - centaur-tabs-set-modified-marker t - centaur-tabs-modified-marker "•" - centaur-tabs-close-button "x" - centaur-tabs-cycle-scope 'tabs - centaur-tabs-adjust-buffer-order t - centaur-tabs-left-edge-margin nil) +;; (use-package centaur-tabs +;; :init +;; (setq centaur-tabs-enable-key-bindings t) +;; :config +;; (setq centaur-tabs-style "wave" +;; centaur-tabs-height 32 +;; centaur-tabs-set-icons t +;; centaur-tabs-show-new-tab-button t +;; centaur-tabs-show-navigation-buttons t +;; centaur-tabs-set-bar 'under +;; centaur-tabs-show-count t +;; centaur-tabs-gray-out-icons 'buffer +;; x-underline-at-descent-line t +;; centaur-tabs-set-modified-marker t +;; centaur-tabs-modified-marker "•" +;; centaur-tabs-close-button "x" +;; centaur-tabs-cycle-scope 'tabs +;; centaur-tabs-adjust-buffer-order t +;; centaur-tabs-left-edge-margin nil) - (centaur-tabs-change-fonts (face-attribute 'default :font) 110) - (centaur-tabs-headline-match) - (centaur-tabs-group-by-projectile-project) - ;; (centaur-tabs-enable-buffer-alphabetical-reordering) - (centaur-tabs-mode t) +;; (centaur-tabs-change-fonts (face-attribute 'default :font) 110) +;; (centaur-tabs-headline-match) +;; (centaur-tabs-group-by-projectile-project) +;; ;; (centaur-tabs-enable-buffer-alphabetical-reordering) +;; (centaur-tabs-mode t) - (defvar categories-alist - '( - (:name "org" :modes (org-mode org-agenda-mode) :buffer-name () :type global) - (:name "gptel" :modes nil :buffer-name ("*llama-cpp*" "*llama-cpp-code*" "*llama-cpp-bigchat*" "*llama-cpp-biggerchat*" "*gptel*" "*groq*" "*gptel-context*" "*gptel-query*") :type global) - (:name "terminal" :modes (vterm-mode term-mode) :buffer-name () :type per-project) - (:name "misc" :modes (+doom-dashboard-mode native-comp-limple-mode messages-buffer-mode) :buffer-name () :type global) - (:name "misc" :modes (special-mode fundamental-mode) :buffer-name () :type per-project) - ) - "Mapping of categories to modes with their respective type logic.") +;; (defvar categories-alist +;; '( +;; (:name "org" :modes (org-mode org-agenda-mode) :buffer-name () :type global) +;; (:name "gptel" :modes nil :buffer-name ("*llama-cpp*" "*llama-cpp-code*" "*llama-cpp-bigchat*" "*llama-cpp-biggerchat*" "*gptel*" "*groq*" "*gptel-context*" "*gptel-query*") :type global) +;; (:name "terminal" :modes (vterm-mode term-mode) :buffer-name () :type per-project) +;; (:name "misc" :modes (+doom-dashboard-mode native-comp-limple-mode messages-buffer-mode) :buffer-name () :type global) +;; (:name "misc" :modes (special-mode fundamental-mode) :buffer-name () :type per-project) +;; ) +;; "Mapping of categories to modes with their respective type logic.") - (defun get-project-name-or-default (default-name) - "Return the project name if available, or DEFAULT-NAME." - (if-let ((project-root (condition-case _err - (projectile-project-root) - (error nil)))) - (concat (projectile-project-name) "::" default-name) - default-name)) +;; (defun get-project-name-or-default (default-name) +;; "Return the project name if available, or DEFAULT-NAME." +;; (if-let ((project-root (condition-case _err +;; (projectile-project-root) +;; (error nil)))) +;; (concat (projectile-project-name) "::" default-name) +;; default-name)) - (defun get-category-name (buffer) - "Get category name for the given BUFFER." - (let (category-name) - (dolist (category categories-alist category-name) - (let ((buffer-names (plist-get category :buffer-name)) - (modes (plist-get category :modes))) - (cond - ((and buffer-names (member (buffer-name buffer) buffer-names)) - (setq category-name - (if (eq (plist-get category :type) 'per-project) - (get-project-name-or-default (plist-get category :name)) - (plist-get category :name)))) - ((and modes (with-current-buffer buffer (memq major-mode modes))) - (setq category-name - (if (eq (plist-get category :type) 'per-project) - (get-project-name-or-default (plist-get category :name)) - (plist-get category :name))))))))) +;; (defun get-category-name (buffer) +;; "Get category name for the given BUFFER." +;; (let (category-name) +;; (dolist (category categories-alist category-name) +;; (let ((buffer-names (plist-get category :buffer-name)) +;; (modes (plist-get category :modes))) +;; (cond +;; ((and buffer-names (member (buffer-name buffer) buffer-names)) +;; (setq category-name +;; (if (eq (plist-get category :type) 'per-project) +;; (get-project-name-or-default (plist-get category :name)) +;; (plist-get category :name)))) +;; ((and modes (with-current-buffer buffer (memq major-mode modes))) +;; (setq category-name +;; (if (eq (plist-get category :type) 'per-project) +;; (get-project-name-or-default (plist-get category :name)) +;; (plist-get category :name))))))))) - (defun centaur-tabs-group-name-by-category () - "Get tab group name based on category." - (let ((mode-category (get-category-name (current-buffer)))) - (if mode-category - (list mode-category) - (list (get-project-name-or-default "main"))))) +;; (defun centaur-tabs-group-name-by-category () +;; "Get tab group name based on category." +;; (let ((mode-category (get-category-name (current-buffer)))) +;; (if mode-category +;; (list mode-category) +;; (list (get-project-name-or-default "main"))))) - (defun centaur-tabs-projectile-buffer-groups () - "Return the list of group names BUFFER belongs to." - (if centaur-tabs-projectile-buffer-group-calc - (symbol-value 'centaur-tabs-projectile-buffer-group-calc) - (set (make-local-variable 'centaur-tabs-projectile-buffer-group-calc) - (centaur-tabs-group-name-by-category)))) +;; (defun centaur-tabs-projectile-buffer-groups () +;; "Return the list of group names BUFFER belongs to." +;; (if centaur-tabs-projectile-buffer-group-calc +;; (symbol-value 'centaur-tabs-projectile-buffer-group-calc) +;; (set (make-local-variable 'centaur-tabs-projectile-buffer-group-calc) +;; (centaur-tabs-group-name-by-category)))) - (add-hook! '(+doom-dashboard-mode-hook +popup-buffer-mode-hook) - (defun +tabs-disable-centaur-tabs-mode-maybe-h () - "Disable `centaur-tabs-mode' in current buffer." - (when (centaur-tabs-mode-on-p) - (centaur-tabs-local-mode)))) - ) +;; (add-hook! '(+doom-dashboard-mode-hook +popup-buffer-mode-hook) +;; (defun +tabs-disable-centaur-tabs-mode-maybe-h () +;; "Disable `centaur-tabs-mode' in current buffer." +;; (when (centaur-tabs-mode-on-p) +;; (centaur-tabs-local-mode)))) +;; ) ;; ruby diff --git a/ext/doom/init.el b/ext/doom/init.el index 833aaf5..e3abe72 100644 --- a/ext/doom/init.el +++ b/ext/doom/init.el @@ -44,7 +44,7 @@ ;;neotree ; a project drawer, like NERDTree for vim ophints ; highlight the region an operation acts on (popup +defaults) ; tame sudden yet inevitable temporary windows - ;; tabs ; a tab bar for Emacs + tabs ; a tab bar for Emacs treemacs ; a project drawer, like neotree but cooler ;;unicode ; extended unicode support for various languages (vc-gutter