stardiviner <> writes:

> I have a large `org-tag-alist` value that contains about ~7000 tags.
> When I press [C-c C-q] `org-set-tags-command`. Emacs suspends a long time.

Indeed. That's because `org-fast-tag-selection' tries to put all those
7k tags into tag selection window.

We can probably limit the maximum number of tags in the quick selection

Can you try the attached simple diff for `org-fast-tag-selection' and
check if it is enough to solve the hang?

diff --git a/lisp/org.el b/lisp/org.el
index c148409d9..d745fd01e 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -11765,7 +11765,7 @@ (defun org-fast-tag-selection (current inherited table &optional todo-table)
 	(org-fast-tag-insert "Current" current c-face "\n\n")
 	(org-fast-tag-show-exit exit-after-next)
 	(org-set-current-tags-overlay current ov-prefix)
-	(setq tbl fulltable char ?a cnt 0)
+	(setq tbl (seq-take fulltable 26) char ?a cnt 0)
 	(while (setq e (pop tbl))
 	   ((eq (car e) :startgroup)
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <>.
Support Org development at <>,
or support my work at <>

Reply via email to