diff --git a/ChangeLog b/ChangeLog index 108f66a6..c653fb45 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,25 @@ +2026-03-08 Bob Weiner + +* hsys-org.el (org-version): Fix to test if version< "9.6" not "6". + hywiki.el (hywiki-maybe-highlight-region): Add for rehighlighting in a region + after edits are made to a buffer. + (hywiki-word-add-completion-at-point): Make 'indent-for-tab-command' + by default bound to {TAB} complete HyWiki references by setting + 'tab-always-complete' to 'complete. + (hywiki-word-remove-completion-at-point): Restore user's customized + setting of 'tab-always-complete'. + 2026-03-07 Bob Weiner +* man/hyperbole.texi (HyWikiWords): Fix key binding for Org None option for + the Action Key. + +* hsys-org-roam.el (require 'package): + hyrolo.el (require 'package): + hui-treemacs.el (require 'package): + hsys-org.el (require 'package): Ensure this is always the first require + to avoid the need to add a (package-activate) call. + * hywiki.el (hywiki-mode-disable): Move global hook disables to this new function from 'hywiki-word-dehighlight-buffers'. Call only when 'hywiki-mode' is set to nil. This fixes an issue where new HyWiki pages diff --git a/README.md.html b/README.md.html index dbd04d7a..1be051fb 100644 --- a/README.md.html +++ b/README.md.html @@ -14,6 +14,7 @@ +

Articles

+

Summary

GNU Hyperbole (pronounced Ga-new Hi-per-bo-lee), or just Hyperbole, is like Markdown for hypertext. Hyperbole @@ -234,6 +271,7 @@

Invocation

initialization. A long video demonstrating many of HyControl's features is available at https://youtu.be/M3-aMh1ccJk.

+

Hyperbole Manual

The above are the best interactive ways to learn about Hyperbole. Hyperbole also includes the Hyperbole Manual, a full reference manual, not a simple introduction. It is included in the "man/" subdirectory of diff --git a/hsys-org-roam.el b/hsys-org-roam.el index d8914770..f06c74a4 100644 --- a/hsys-org-roam.el +++ b/hsys-org-roam.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 26-Feb-23 at 11:20:15 by Bob Weiner -;; Last-Mod: 5-Jan-25 at 12:06:23 by Bob Weiner +;; Last-Mod: 7-Mar-26 at 22:38:37 by Bob Weiner ;; ;; SPDX-License-Identifier: GPL-3.0-or-later ;; @@ -26,8 +26,8 @@ ;;; Other required Elisp libraries ;;; ************************************************************************ +(require 'package) ;; Always keep this first (require 'hypb) -(require 'package) ;;; ************************************************************************ ;;; Public declarations diff --git a/hsys-org.el b/hsys-org.el index 681da04d..33b329b6 100644 --- a/hsys-org.el +++ b/hsys-org.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 2-Jul-16 at 14:54:14 -;; Last-Mod: 7-Mar-26 at 21:31:49 by Bob Weiner +;; Last-Mod: 7-Mar-26 at 22:39:35 by Bob Weiner ;; ;; SPDX-License-Identifier: GPL-3.0-or-later ;; @@ -30,6 +30,7 @@ ;;; Other required Elisp libraries ;;; ************************************************************************ +(require 'package) ;; Always keep this first (eval-when-compile (require 'hmouse-drv)) (require 'hargs) ;; for `hargs:delimited-p' (require 'hproperty) ;; requires 'hbut @@ -39,7 +40,6 @@ (require 'org-element) (require 'org-fold nil t) (require 'org-macs) -(require 'package) (require 'warnings) (require 'find-func) ;; Avoid any potential library name conflict by giving the load directory. @@ -314,7 +314,7 @@ Return t if Org is reloaded, else nil." (add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode)) t))))) -(if (version< org-version "6") +(if (version< org-version "9.6") ;;; For Org less than 9.6; derived from `org-get-heading' in "org.el" ;;;###autoload (defun hsys-org-format-heading (heading &optional no-tags no-todo no-priority no-comment) diff --git a/hui-treemacs.el b/hui-treemacs.el index 65fbfc5e..b17f8b15 100644 --- a/hui-treemacs.el +++ b/hui-treemacs.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 19-Nov-17 -;; Last-Mod: 13-Nov-24 at 13:09:22 by Mats Lidell +;; Last-Mod: 7-Mar-26 at 22:39:17 by Bob Weiner ;; ;; SPDX-License-Identifier: GPL-3.0-or-later ;; @@ -21,7 +21,7 @@ ;;; Other required Elisp libraries ;;; ************************************************************************ -(require 'package) +(require 'package) ;; Always keep this first (require 'seq) (or (require 'treemacs nil t) @@ -156,4 +156,3 @@ Suitable for use as a value of `action-key-modeline-buffer-id-function'." (provide 'hui-treemacs) ;;; hui-treemacs.el ends here - diff --git a/hyrolo.el b/hyrolo.el index d291a97b..4aad41c5 100644 --- a/hyrolo.el +++ b/hyrolo.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 7-Jun-89 at 22:08:29 -;; Last-Mod: 28-Feb-26 at 23:10:24 by Bob Weiner +;; Last-Mod: 7-Mar-26 at 22:38:55 by Bob Weiner ;; ;; SPDX-License-Identifier: GPL-3.0-or-later ;; @@ -32,6 +32,7 @@ ;;; Other required Elisp libraries ;;; ************************************************************************ +(require 'package) ;; Always keep this first (require 'hversion) (require 'hmail) (require 'hsys-consult) @@ -40,7 +41,6 @@ (eval-when-compile `(hyrolo-install-markdown-mode)) (require 'outline) -(require 'package) (require 'reveal) ;; Avoid any potential library name conflict by giving the load directory. (require 'set (expand-file-name "set" hyperb:dir)) diff --git a/hywiki.el b/hywiki.el index 02899ca8..f64e4479 100644 --- a/hywiki.el +++ b/hywiki.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 21-Apr-24 at 22:41:13 -;; Last-Mod: 7-Mar-26 at 22:10:28 by Bob Weiner +;; Last-Mod: 8-Mar-26 at 20:19:37 by Bob Weiner ;; ;; SPDX-License-Identifier: GPL-3.0-or-later ;; @@ -2546,6 +2546,18 @@ the current page unless they have sections attached." (and (/= (point) (point-max)) (/= (if (char-after) (char-syntax (char-after)) 0) ? )))) +(defun hywiki-maybe-highlight-org-element-backward () + "Highlight HyWikiWords with point at a single closing square/angle bracket. +Dehighlight HyWikiWords when on a double closing square/angle bracket, +since Org mode highlights those." + (hywiki--maybe-de/highlight-org-element-backward #'hywiki-maybe-highlight-sexp)) + +(defun hywiki-maybe-highlight-org-element-forward () + "Highlight HyWikiWords with point at a single opening square/angle bracket. +Dehighlight HyWikiWords when on a double opening square/angle bracket, +since Org mode highlights those." + (hywiki--maybe-de/highlight-org-element-forward #'hywiki-maybe-highlight-sexp)) + ;;;###autoload (defun hywiki-maybe-highlight-reference (&optional on-reference) "Highlight any non-Org link HyWikiWord#section at or one char before point. @@ -2647,18 +2659,6 @@ the current page unless they have sections attached." hywiki--but-end (hproperty:but-end hywiki--buts)) (hproperty:but-delete hywiki--buts))))))))) -(defun hywiki-maybe-highlight-org-element-backward () - "Highlight HyWikiWords with point at a single closing square/angle bracket. -Dehighlight HyWikiWords when on a double closing square/angle bracket, -since Org mode highlights those." - (hywiki--maybe-de/highlight-org-element-backward #'hywiki-maybe-highlight-sexp)) - -(defun hywiki-maybe-highlight-org-element-forward () - "Highlight HyWikiWords with point at a single opening square/angle bracket. -Dehighlight HyWikiWords when on a double opening square/angle bracket, -since Org mode highlights those." - (hywiki--maybe-de/highlight-org-element-forward #'hywiki-maybe-highlight-sexp)) - (defun hywiki-maybe-highlight-references (&optional region-start region-end skip-lookups-update-flag) "Highlight each non-Org link HyWiki page#section in the current buffer/region. With optional REGION-START and REGION-END positions or markers (active @@ -2797,6 +2797,14 @@ whenever `hywiki-mode' is enabled/disabled." (hywiki-maybe-directory-updated)) nil) +(defun hywiki-maybe-highlight-region (start end) + "Rehighlight HyWikiWord references between positions START to END." + (hywiki-maybe-highlight-references start end t) + (unless (hyperb:stack-frame '(hywiki-maybe-highlight-wikiwords-in-frame)) + ;; Rebuild lookup tables if any HyWiki page name has changed + (hywiki-get-referent-hasht) + (hywiki-maybe-directory-updated))) + (defun hywiki-maybe-highlight-sexp (direction-number) "Highlight any HyWikiWord within single square/angle bracket. DIRECTION-NUMBER is 1 for forward scanning and -1 for backward scanning." @@ -4028,6 +4036,9 @@ Completion requires typing at least the two first characters of the completion or no completion candidates are returned. If using `company-mode', you must use the `company-capf' backend for HyWiki completion to work properly." + ;; Make `indent-for-tab-command' by default bound to {TAB} complete HyWiki + ;; references. + (setq tab-always-indent 'complete) (add-hook 'completion-at-point-functions #'hywiki-completion-at-point -90 t) (cond ((bound-and-true-p corfu-mode)) ;; Uses :exit-function in hywiki-c-a-p ((bound-and-true-p company-mode) @@ -4048,8 +4059,9 @@ completion to work properly." (remove-hook 'company-completion-finished-hook #'hywiki-completion-exit-function) (remove-hook 'company-completion-cancelled-hook #'hywiki-completion-exit-function) (advice-remove 'completion--insert #'hywiki-completion-exit-function) - ;; Restore user's customized setting of this option. - (custom-reevaluate-setting 'completion-cycle-threshold)) + ;; Restore user's customized setting of these options. + (custom-reevaluate-setting 'completion-cycle-threshold) + (custom-reevaluate-setting 'tab-always-indent)) (defun hywiki-word-highlight-buffers (buffers) "Setup HyWikiWord auto-highlighting and highlight in BUFFERS." diff --git a/man/hyperbole.html b/man/hyperbole.html index afc485c9..6f5228f3 100644 --- a/man/hyperbole.html +++ b/man/hyperbole.html @@ -4,7 +4,7 @@