emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v2] Re: Improve the performance of `org-set-tags-command` on larg


From: Christopher M. Miles
Subject: [PATCH v2] Re: Improve the performance of `org-set-tags-command` on large `org-tag-alist`
Date: Mon, 15 May 2023 02:14:35 +0800
User-agent: mu4e 1.10.3; emacs 30.0.50

Ihor Radchenko <yantar92@posteo.net> writes:

> "Christopher M. Miles" <numbchild@gmail.com> writes:
>
>>>> #+begin_src emacs-lisp
>>>> (let ((bound-tags (seq-filter 'cdr temp-fulltable)))
>>>>   (if (length> bound-tags 0)
>>>>       bound-tags
>>>>     (seq-take temp-fulltable 26)))
>>>> #+end_src
>>>
>>> This will unconditionally drop auto-labeled tags when user-bound tags
>>> exist, even if the total number of tags in buffer does not exceed 26.
>>
>> I try to read the source code of `org-fast-tag-selection', but the code is 
>> hard to read.
>
> Yeah. I agree. But we have what we have.
>
>> I don't know how to keep auto-labeled tags. Do you have any suggestions?
>
> You are almost there.
> Just run your code only when (lentgh> fulltable 26).
>
> Of course, 26 should be a defcustom rather than a hard-coded constant.
> And do the same for `org-fast-todo-selection'.

Ok, I added defcustom option, and add cl-case condition on custom option
`org-use-fast-tag-selection'.

Attachment: 0001-org-Improve-the-tags-fast-selection-performance.patch
Description:

-- 

[ stardiviner ]
I try to make every word tell the meaning that I want to express without 
misunderstanding.

Blog: https://stardiviner.github.io/
IRC(libera.chat, freenode): stardiviner, Matrix: stardiviner
GPG: F09F650D7D674819892591401B5DF1C95AE89AC3

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]