From ef2584585b095fff1e045e58673d2a7c8f9af799 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?El=C3=ADas=20Gabriel=20P=C3=A9rez?= Date: Sat, 8 Nov 2025 20:04:30 +0200 Subject: [PATCH] hideshow: Rework previous changes * lisp/progmodes/hideshow.el: Set default values of buffer-local variables. (hs-inside-comment-p): Restore. (hs--set-variable): Rename from 'hs--get-mode-value'. (hs-grok-mode-type): Rework. * lisp/nxml/nxml-mode.el: * lisp/progmodes/f90.el: * lisp/progmodes/fortran.el: * lisp/progmodes/icon.el: * lisp/progmodes/lua-mode.el: * lisp/progmodes/python.el: * lisp/progmodes/verilog-mode.el: * lisp/progmodes/vhdl-mode.el: * lisp/textmodes/mhtml-mode.el: * lisp/textmodes/sgml-mode.el: * lisp/treesit.el (treesit-major-mode-setup): Rename 'hs-forward-sexp-func' to 'hs-forward-sexp-function', 'hs-adjust-block-beginning' to 'hs-adjust-block-beginning-function', 'hs-find-block-beginning-func' to 'hs-find-block-beginning-function', 'hs-find-next-block-func' to 'hs-find-next-block-function', 'hs-looking-at-block-start-p-func' to 'hs-looking-at-block-start-predicate', 'hs-inside-comment-p-func' to 'hs-inside-comment-predicate'. --- lisp/nxml/nxml-mode.el | 2 +- lisp/progmodes/f90.el | 2 +- lisp/progmodes/fortran.el | 4 +- lisp/progmodes/hideshow.el | 284 ++++++++++++++------------------- lisp/progmodes/icon.el | 2 +- lisp/progmodes/lua-mode.el | 2 +- lisp/progmodes/python.el | 12 +- lisp/progmodes/verilog-mode.el | 2 +- lisp/progmodes/vhdl-mode.el | 2 +- lisp/textmodes/mhtml-mode.el | 4 +- lisp/textmodes/sgml-mode.el | 2 +- lisp/treesit.el | 18 +-- 12 files changed, 148 insertions(+), 188 deletions(-) diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index 08c6c1b2fac..9b780a91721 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -535,7 +535,7 @@ Many aspects this mode can be customized using (setq-local hs-block-start-regexp "<[^/>]*?") (setq-local hs-block-end-regexp "]*[^/]>") (setq-local hs-c-start-regexp "