1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-11-21 06:55:35 +00:00

org-fold-core-style: Use 'overlays in Emacs >=29

* lisp/org-fold-core.el (org-fold-core-style): Set default value to
'overlays in newer Emacs versions.  Newer Emacs does not have
performance issues with overlays and using text-properties there is
not beneficial due to numerous issues with most of Emacs code and
third-party packages that assume overlay-based folding.
This commit is contained in:
Ihor Radchenko 2024-02-02 14:21:31 +01:00
parent 614d534a9d
commit 62c6d5668d
No known key found for this signature in database
GPG Key ID: 6470762A7DA11D8B

View File

@ -280,12 +280,13 @@
;;; Customization
(defcustom org-fold-core-style 'text-properties
(defcustom org-fold-core-style (if (version< emacs-version "29")
'text-properties
'overlays)
"Internal implementation detail used to hide folded text.
Can be either `text-properties' or `overlays'.
The former is faster on large files, while the latter is generally
less error-prone with regard to third-party packages that haven't yet
adapted to the new folding implementation.
The former is faster on large files in Emacs <29, while the latter is
generally less error-prone with regard to third-party packages.
Important: This variable must be set before loading Org."
:group 'org