From eea0b9654e7dd5e2a374c6ea54767a3678edf82b Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Thu, 21 Jul 2022 16:31:12 +0200 Subject: [PATCH 01/15] Doc strings within 80 char limit for kview.el --- ChangeLog | 10 ++++-- kotl/kview.el | 94 +++++++++++++++++++++++++++++++-------------------- 2 files changed, 65 insertions(+), 39 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2d6924e5..be8fd573 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2022-10-07 Mats Lidell + +* hui-mouse.el: +* hvar.el: +* hyrolo.el: Shorten docs strings to be within 80 char limit. + 2022-10-06 Bob Weiner * test/hibtypes-tests.el (ibtypes::pathname-path-variable-test): Remove @@ -29,9 +35,7 @@ 2022-10-03 Mats Lidell -* hui-mouse.el: -* hvar.el: -* hyrolo.el: +* kotl/kview.el: * hypb.el: * hycontrol.el: * hui-select.el: diff --git a/kotl/kview.el b/kotl/kview.el index 127917bd..e985122b 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -3,7 +3,7 @@ ;; Author: Bob Weiner ;; ;; Orig-Date: 6/30/93 -;; Last-Mod: 29-Aug-22 at 00:15:19 by Bob Weiner +;; Last-Mod: 3-Oct-22 at 22:22:09 by Mats Lidell ;; ;; Copyright (C) 1993-2022 Free Software Foundation, Inc. ;; See the "../HY-COPY" file for license information. @@ -51,7 +51,7 @@ Labels are padded with spaces on the left. Default value is 4." :group 'hyperbole-koutliner) (defcustom kview:default-label-separator ". " - "*Default string of characters to insert between label and contents of a koutline cell. + "*Characters to insert between label and contents of a koutline cell. Default value is \". \"." :type 'string :group 'hyperbole-koutliner) @@ -60,7 +60,7 @@ Default value is \". \"." "Koutline view `outline-regexp' value that handles all label formats.") (defcustom kview:default-label-type 'alpha - "*Default label-type to use for new koutlines. Default value is 'alpha. + "*Default label-type to use for new koutlines. Default value is `alpha'. It must be one of the following symbols: alpha for `1b3' full alphanumeric labels id for `027' permanent idstamp labels @@ -121,7 +121,7 @@ Return t unless no such cell." (kproperty:get (kcell-view:plist-point pos) 'kcell)) (defun kcell-view:cell-from-ref (cell-ref) - "Return a kcell referenced by CELL-REF, a cell label, id string or integer idstamp. + "Return a kcell referenced by CELL-REF, a cell label, id string or idstamp. Trigger an error if CELL-REF is not a string or is not found." (if (or (stringp cell-ref) (integerp cell-ref)) @@ -193,7 +193,7 @@ a cell's label and the start of its contents." (kcell-view:expand pos lbl-sep-len t)) (defun kcell-view:invisible-p (&optional pos lbl-sep-len) - "Return t if cell at optional POS or point is entirely invisible within the current view. + "Return t if cell at optional POS or point is entirely invisible in current view. Optional LBL-SEP-LEN is the length of the separation between a cell's label and the start of its contents. @@ -222,7 +222,8 @@ Any cell that is invisible is also collapsed as indicated by a call to "\\1" (buffer-substring start end))))) (defun kcell-view:create (kview cell contents level idstamp klabel &optional no-fill sibling-p) - "Insert into KVIEW at point, CELL with CONTENTS at LEVEL (1 = first level) with IDSTAMP and KLABEL. + "Insert into KVIEW at point, CELL with CONTENTS at LEVEL with IDSTAMP and KLABEL. +First level is 1. If the current view displays klabels, then KLABEL should be inserted prior to this call, with point following it. @@ -417,7 +418,7 @@ Return t unless no next cell." t)) (defun kcell-view:next-invisible-p (&optional _pos lbl-sep-len) - "Return t if there is a next cell after optional POS or point and it is invisible." + "Return t if next cell is after optional POS or point and it is invisible." (save-excursion (and (kcell-view:next nil lbl-sep-len) (kcell-view:invisible-p (point) lbl-sep-len)))) @@ -464,11 +465,13 @@ Return t unless no previous cell." (kcell:plist (kcell-view:cell pos))) (defun kcell-view:plist-point (&optional pos) - "Return buffer position of attributes associated with cell at optional POS or point." + "Return buffer position of attributes associated with cell. +Cell is at optional POS or point." (save-excursion (1+ (kcell-view:to-label-end pos)))) (defun kcell-view:to-label-end (&optional pos) - "Move point from optional POS to the end of the current cell's label (before the label separator) and return point. + "Move point from optional POS to end of current cell's label and return point. +Point is set at end of cell's label but before the label separator. If between kcells, move to the previous one. The current cell may be hidden." (when pos (goto-char pos)) (if (save-excursion @@ -488,7 +491,7 @@ If between kcells, move to the previous one. The current cell may be hidden." (error "(kcell-view:to-label-end): Can't find end of current cell's label"))))) (defun kcell-view:absolute-reference (&optional pos) - "Return a klink to the kcell at optional POS or point; return nil if not in a kcell. + "Return a klink to kcell at optional POS or point; return nil if not in a kcell. The reference is a string of the form, \"\" where cell-ref is as described in the documentation for `kcell:ref-to-id'. Kcell-file is an absolute path to the current @@ -499,7 +502,7 @@ Koutline file." (kcell-view:label pos) (kcell-view:idstamp pos))))) (defun kcell-view:reference (&optional pos relative-dir) - "Return a klink to the kcell at optional POS or point; return nil if not in a kcell. + "Return a klink to kcell at optional POS or point; return nil if not in a kcell. The reference is a string of the form, \"\" where cell-ref is as described in the documentation for `kcell:ref-to-id'. Kcell-file is made relative to optional @@ -511,7 +514,8 @@ or is nil), before it is returned." (kcell-view:label pos) (kcell-view:idstamp pos))))) (defun kcell-view:remove-attr (attribute &optional pos) - "Remove ATTRIBUTE, if any, for current cell or cell at optional POS. Return the modified cell." + "Remove ATTRIBUTE, if any, for cell and return the modified cell. +Cell is current or at optional POS." (interactive "*SAttribute to remove: ") (unless (eq attribute 'idstamp) ;; Can't remove idstamp (let (mod-cell) @@ -525,7 +529,8 @@ or is nil), before it is returned." mod-cell))) (defun kcell-view:set-attr (attribute value &optional pos) - "Set ATTRIBUTE's VALUE for current cell or cell at optional POS and return the modified cell. + "Set ATTRIBUTE's VALUE for cell and return the modified cell. +Cell is current or at optional POS. Use 0 for POS to set top cell's attributes." (unless (and (eq pos 0) (eq attribute 'idstamp)) ;; top cell idstamp set when Koutline is created (save-excursion @@ -561,7 +566,8 @@ With optional VISIBLE-P, consider only visible siblings." (or lbl-sep-len (kview:label-separator-length kview))))) (defun kcell-view:to-visible-label-end (&optional pos) - "Move point to the end of the current visible cell's label (before the label separator). + "Move point to end of the visible cell's label. +Cell is current or at optional POS. Point is set before the label separator. If between kcells, move to the previous one. Return final point location." (when pos (goto-char pos)) @@ -633,9 +639,11 @@ level." label-type level-indent label-separator label-min-width blank-lines levels-to-show lines-to-show) "Return a new kview for BUFFER-NAME. -Optional ID-COUNTER is the maximum permanent id previously given out in this -outline. Optional LABEL-TYPE, LEVEL-INDENT, LABEL-SEPARATOR, LABEL-MIN-WIDTH, -BLANK-LINES, LEVELS-TO-SHOW, and LINES-TO-SHOW may also be given, otherwise default values are used. +Optional ID-COUNTER is the maximum permanent id previously given +out in this outline. Optional LABEL-TYPE, LEVEL-INDENT, +LABEL-SEPARATOR, LABEL-MIN-WIDTH, BLANK-LINES, LEVELS-TO-SHOW, +and LINES-TO-SHOW may also be given, otherwise default values are +used. See documentation of: `kview:default-label-type' for LABEL-TYPE, @@ -718,7 +726,9 @@ this function is called." (set-marker opoint nil))) (defun kview:first-invisible-point (&optional pos) - "Return the first point following optional POS that is followed by an invisible character, else the end point of the cell contents. + "Return the first point that is followed by an invisible character. +Start from point or optional POS. If none are found return the +end point of the cell contents. Value may be the character immediately after point." (unless pos (setq pos (point))) @@ -732,8 +742,8 @@ Value may be the character immediately after point." (or pos end))) (defun kview:first-visible-point (&optional pos) - "Return the first point following optional POS that is followed by a visible character, else (point-max). -Value may be the character immediately after point." + "Return the first point that is followed by a visible character. +Start from point or optional POS. If none are found return (point-max)." (unless pos (setq pos (point))) (while (and pos (kview:char-invisible-p pos)) @@ -745,7 +755,9 @@ Value may be the character immediately after point." (or pos (point-max))) (defun kview:get-cells-status (kview start end) - "In the current buffer's KVIEW, between START and END, return a coded list of status of each visible cell. + "In current buffer's KVIEW, return a coded list of status of each visible cell. +Return the list between START and END. + Status is returned as: 0 if all the lines of the cell are visible and it has no hidden branches; a positive count of the lines displayed in the cell if it has no hidden branches; otherwise, a negative count of @@ -764,7 +776,8 @@ the lines displayed, since it has hidden branches." kview t start end)) (defun kview:goto-cell-id (idstamp-or-string) - "Move point to start of cell with permanent IDSTAMP-OR-STRING and return t, else nil." + "Move point to start of cell with permanent IDSTAMP-OR-STRING. +On success return t, else nil." (let* ((idstamp (if (integerp idstamp-or-string) idstamp-or-string (string-to-number idstamp-or-string))) @@ -791,7 +804,8 @@ the lines displayed, since it has hidden branches." (kcell-view:label)))) (defun kview:insert-contents (kcell contents no-fill fill-prefix) - "Insert KCELL's CONTENTS into view at point and fill resulting paragraphs, unless NO-FILL is non-nil. + "Insert KCELL's CONTENTS into view at point and fill resulting paragraphs. +Do not fill if NO-FILL is non-nil. FILL-PREFIX is the indentation string for the current cell. If CONTENTS is nil, get contents from the cell at point. Return contents inserted (this value may differ from the value passed in) due to @@ -847,7 +861,8 @@ filling." (kview:get-attr kview 'kotl))) (defun kview:label (klabel-function prev-label child-p) - "Return label string to display for current cell computed from KLABEL-FUNCTION, PREV-LABEL and CHILD-P." + "Return label string to display for current cell. +Label is computed from KLABEL-FUNCTION, PREV-LABEL and CHILD-P." (funcall klabel-function prev-label child-p)) (defun kview:label-function (kview) @@ -887,7 +902,8 @@ See documentation for kview:default-level-indent." (kview:get-attr kview 'level-indent))) (defun kview:map-branch (func kview &optional first-p visible-p) - "Apply FUNC to the sibling trees from point forward within KVIEW and return results as a list. + "Apply FUNC to the sibling trees from point forward within KVIEW. +Return results as a list. With optional FIRST-P non-nil, begins with first sibling in current branch. With optional VISIBLE-P, considers only those sibling cells that are visible in the view. @@ -958,7 +974,8 @@ See also `kview:map-tree', `kview:map-branch’, and ‘kview:map-siblings’." (t (error "(kview:map-region): No region or invalid start and end positions"))))))) (defun kview:map-siblings (func kview &optional first-p visible-p) - "Apply FUNC to the sibling cells from point forward within KVIEW and return results as a list. + "Apply FUNC to the sibling cells from point forward within KVIEW. +Return results as a list. With optional FIRST-P non-nil, begins with first sibling in current branch. With optional VISIBLE-P, considers only those sibling cells that are visible in the view. @@ -991,7 +1008,8 @@ See also `kview:map-branch' and `kview:map-tree'." (nreverse results))))) (defun kview:map-expanded-tree (func kview &optional top-p) - "Temporarily expand the tree at point, apply FUNC to the tree in the KVIEW and return results as a list. + "Temporarily expand the tree at point, apply FUNC to the tree in the KVIEW. +Return results as a list. This is for a FUNC that requires all cells in the tree be fully visible and expanded before operating upon it. If this is not the case, use `kview:map-tree' instead. FUNC may not change the number of or the order of @@ -1048,7 +1066,7 @@ See also `kview:map-region', `kview:map-branch' and `kview:map-siblings'." (nreverse results))))) (defun kview:map-tree (func kview &optional top-p visible-p) - "Apply FUNC to the tree starting at point within KVIEW and return results as a list. + "Apply FUNC to the tree starting at point within KVIEW, return results as a list. With optional TOP-P non-nil, maps over all of kview's cells. With optional VISIBLE-P, considers only those cells that are visible in the view. @@ -1087,7 +1105,8 @@ See also `kview:map-region', `kview:map-branch' and `kview:map-siblings'." (defun kview:move (from-start from-end to-start from-indent to-indent &optional copy-p fill-p) - "Move tree between FROM-START and FROM-END to TO-START, changing FROM-INDENT to TO-INDENT. + "Move tree between FROM-START and FROM-END to TO-START. +Changes indentation from FROM-INDENT to TO-INDENT. Copy tree if optional COPY-P is non-nil. Refill cells if optional FILL-P is non-nil. Leave point at TO-START." (let ((region (buffer-substring from-start from-end)) @@ -1157,7 +1176,8 @@ FILL-P is non-nil. Leave point at TO-START." (set-marker new-start nil))) (defun kview:previous-visible-point (&optional pos) - "Return the first point preceding optional POS that is followed by a visible character, else (point-min). + "Return the first preceding point that is followed by a visible character. +Start from point or optional POS. If none are found return (point-min). Value may be the character immediately after point." (unless pos (setq pos (point))) @@ -1181,7 +1201,8 @@ Value may be the character immediately after point." (error "(kview:set-buffer): Invalid kview argument"))) (defun kview:set-cells-status (kview start end cell-status-list) - "In the current buffer's KVIEW, between START and END, use CELL-STATUS-LIST to restore each cell's status. + "Use CELL-STATUS-LIST to restore each cell's status. +Set status in the current buffer's KVIEW, between START and END. Status is: 0 if all the lines of the cell are visible and it has no hidden branches; a positive count of the lines displayed in the cell if it has no hidden branches; otherwise, a negative count of the lines @@ -1240,12 +1261,12 @@ valid values of NEW-TYPE." (kvspec:update t)))) (defun kview:top-cell (kview) - "Return KVIEW's invisible top cell with idstamp 0 or nil if argument is not a kview." + "Return KVIEW's invisible top cell with idstamp 0 or nil if not a kview." (when (kview:is-p kview) (kview:get-attr kview 'top-cell))) (defun kview:valid-position-p (&optional pos) - "Return non-nil iff point or optional POS is at a position where editing may occur. + "Return non-nil iff point or optional POS is where editing may occur. The read-only positions between cells and within cell indentations are invalid." (when (cond ((null pos) (>= (current-column) (kcell-view:indent))) @@ -1274,7 +1295,7 @@ or marker, `%s'" pos)) (cadr (memq attribute (cadr (memq 'plist obj))))) (defun kcell-view:next-kcell (&optional visible-p lbl-sep-len) - "Move to the point holding the kcell property within the next cell of the current kview. + "Move to point holding the kcell property within next cell of the current kview. With optional VISIBLE-P, consider only visible cells. Return t unless no next cell." (let* ((opoint (point)) @@ -1287,7 +1308,7 @@ unless no next cell." (progn (goto-char pos) t)))) (defun kcell-view:previous-kcell (&optional visible-p lbl-sep-len) - "Move to the point holding the kcell property within the previous cell of the current kview. + "Move to point holding the kcell property within previous cell of current kview. With optional VISIBLE-P, consider only visible cells. Return t unless no previous cell." (when (not (kview:valid-position-p)) @@ -1324,7 +1345,8 @@ unless no previous cell." (kview:set-attr kview 'label-parent (klabel-type:parent label-type))) (defun kview:set-label-separator (label-separator &optional set-default-p) - "Set the LABEL-SEPARATOR (a string) between labels and cell contents for the current kview. + "Set the LABEL-SEPARATOR between labels and cell contents for the current kview. +The LABEL-SEPARATOR is a string. With optional prefix arg SET-DEFAULT-P, the default separator value used for new outlines is also set to this new value." (interactive From eb051d47c3e7e5e7ddea73e6202dc9ab892591d2 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Wed, 5 Oct 2022 20:16:05 +0200 Subject: [PATCH 02/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index e985122b..bc7b50bf 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -51,7 +51,7 @@ Labels are padded with spaces on the left. Default value is 4." :group 'hyperbole-koutliner) (defcustom kview:default-label-separator ". " - "*Characters to insert between label and contents of a koutline cell. + "*Default characters to insert between label and contents of a kcell. Default value is \". \"." :type 'string :group 'hyperbole-koutliner) From 1288ad268d1606ab3aa10037c817bbe0a87e77c3 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Wed, 5 Oct 2022 20:16:52 +0200 Subject: [PATCH 03/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index bc7b50bf..bce9b0b2 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -418,7 +418,7 @@ Return t unless no next cell." t)) (defun kcell-view:next-invisible-p (&optional _pos lbl-sep-len) - "Return t if next cell is after optional POS or point and it is invisible." + "Return t if next cell after optional POS or point exists and is invisible." (save-excursion (and (kcell-view:next nil lbl-sep-len) (kcell-view:invisible-p (point) lbl-sep-len)))) From 9af2a7e4260e282be5ac3865d97f17cfac5fda13 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Wed, 5 Oct 2022 20:22:28 +0200 Subject: [PATCH 04/15] Update kview.el Revert single quote change. Defer resolution to later. --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index bce9b0b2..5a49baa6 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -60,7 +60,7 @@ Default value is \". \"." "Koutline view `outline-regexp' value that handles all label formats.") (defcustom kview:default-label-type 'alpha - "*Default label-type to use for new koutlines. Default value is `alpha'. + "*Default label-type to use for new koutlines. Default value is `alpha. It must be one of the following symbols: alpha for `1b3' full alphanumeric labels id for `027' permanent idstamp labels From ca6901eb48fb0e910a26f1b1651acf770ded968e Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Wed, 5 Oct 2022 20:24:09 +0200 Subject: [PATCH 05/15] Update kview.el Use the right single quote --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index 5a49baa6..d6770ec6 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -60,7 +60,7 @@ Default value is \". \"." "Koutline view `outline-regexp' value that handles all label formats.") (defcustom kview:default-label-type 'alpha - "*Default label-type to use for new koutlines. Default value is `alpha. + "*Default label-type to use for new koutlines. Default value is 'alpha. It must be one of the following symbols: alpha for `1b3' full alphanumeric labels id for `027' permanent idstamp labels From 5323dba933886d9197d5353764ee752623249826 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 20:48:43 +0200 Subject: [PATCH 06/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index d6770ec6..9af7e24a 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -727,7 +727,7 @@ this function is called." (defun kview:first-invisible-point (&optional pos) "Return the first point that is followed by an invisible character. -Start from point or optional POS. If none are found return the +Start from point or optional POS. If none are found, return the end point of the cell contents. Value may be the character immediately after point." (unless pos From bf33bfca9155998054cf4a43dbc2b0fb5549a2c1 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 20:48:55 +0200 Subject: [PATCH 07/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/kotl/kview.el b/kotl/kview.el index 9af7e24a..a9e8b17a 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -639,11 +639,10 @@ level." label-type level-indent label-separator label-min-width blank-lines levels-to-show lines-to-show) "Return a new kview for BUFFER-NAME. -Optional ID-COUNTER is the maximum permanent id previously given -out in this outline. Optional LABEL-TYPE, LEVEL-INDENT, -LABEL-SEPARATOR, LABEL-MIN-WIDTH, BLANK-LINES, LEVELS-TO-SHOW, -and LINES-TO-SHOW may also be given, otherwise default values are -used. +Optional ID-COUNTER is the maximum permanent id previously utilized in this outline. +Optional LABEL-TYPE, LEVEL-INDENT, LABEL-SEPARATOR, LABEL-MIN-WIDTH, +BLANK-LINES, LEVELS-TO-SHOW, and LINES-TO-SHOW may also be given; +otherwise, default values are used. See documentation of: `kview:default-label-type' for LABEL-TYPE, From 497438c3b350f49b9f09ae5b65b5d160ab0cf951 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 20:49:11 +0200 Subject: [PATCH 08/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index a9e8b17a..cc82a0bb 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -742,7 +742,7 @@ Value may be the character immediately after point." (defun kview:first-visible-point (&optional pos) "Return the first point that is followed by a visible character. -Start from point or optional POS. If none are found return (point-max)." +Start from point or optional POS. If not found, return (point-max)." (unless pos (setq pos (point))) (while (and pos (kview:char-invisible-p pos)) From b8b846275de17415147e9e0db845a9a108db11c7 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 20:49:28 +0200 Subject: [PATCH 09/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index cc82a0bb..66168abb 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -776,7 +776,7 @@ the lines displayed, since it has hidden branches." (defun kview:goto-cell-id (idstamp-or-string) "Move point to start of cell with permanent IDSTAMP-OR-STRING. -On success return t, else nil." +On success, return t, else nil." (let* ((idstamp (if (integerp idstamp-or-string) idstamp-or-string (string-to-number idstamp-or-string))) From a1f6cc043fd1d9215c5f32fa1c751b12f85293bb Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 20:49:39 +0200 Subject: [PATCH 10/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index 66168abb..7f657f0a 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -1176,7 +1176,7 @@ FILL-P is non-nil. Leave point at TO-START." (defun kview:previous-visible-point (&optional pos) "Return the first preceding point that is followed by a visible character. -Start from point or optional POS. If none are found return (point-min). +Start from point or optional POS. If not found, return (point-min). Value may be the character immediately after point." (unless pos (setq pos (point))) From f2b8f1c0354afc336d0778c0cc3e9c89b50f5ed3 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Fri, 7 Oct 2022 21:52:20 +0200 Subject: [PATCH 11/15] Sync ChangeLog with master --- ChangeLog | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index be8fd573..aa845319 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,8 +1,6 @@ 2022-10-07 Mats Lidell -* hui-mouse.el: -* hvar.el: -* hyrolo.el: Shorten docs strings to be within 80 char limit. +* kotl/kview.el: Shorten docs strings to be within 80 char limit. 2022-10-06 Bob Weiner @@ -35,7 +33,9 @@ 2022-10-03 Mats Lidell -* kotl/kview.el: +* hui-mouse.el: +* hvar.el: +* hyrolo.el: * hypb.el: * hycontrol.el: * hui-select.el: From accdd6b94b9f18dc1c201ef9c52b24d371c0dc23 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Sun, 9 Oct 2022 18:16:15 +0200 Subject: [PATCH 12/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 1 + 1 file changed, 1 insertion(+) diff --git a/kotl/kview.el b/kotl/kview.el index 7f657f0a..69df8501 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -122,6 +122,7 @@ Return t unless no such cell." (defun kcell-view:cell-from-ref (cell-ref) "Return a kcell referenced by CELL-REF, a cell label, id string or idstamp. + If an idstamp, it must be an integer. Trigger an error if CELL-REF is not a string or is not found." (if (or (stringp cell-ref) (integerp cell-ref)) From c2b8f01d3bc58ade5a9dce43bec4f7fae7bbea4c Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Sun, 9 Oct 2022 18:16:29 +0200 Subject: [PATCH 13/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index 69df8501..7c33f252 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -1066,7 +1066,7 @@ See also `kview:map-region', `kview:map-branch' and `kview:map-siblings'." (nreverse results))))) (defun kview:map-tree (func kview &optional top-p visible-p) - "Apply FUNC to the tree starting at point within KVIEW, return results as a list. + "Apply FUNC to the tree starting at point within KVIEW; return results as a list. With optional TOP-P non-nil, maps over all of kview's cells. With optional VISIBLE-P, considers only those cells that are visible in the view. From 97eb0487e55cf27b213d636d75220c1d7fa67f2e Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Sun, 9 Oct 2022 18:16:45 +0200 Subject: [PATCH 14/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kotl/kview.el b/kotl/kview.el index 7c33f252..c5ba8e0f 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -1106,7 +1106,7 @@ See also `kview:map-region', `kview:map-branch' and `kview:map-siblings'." (defun kview:move (from-start from-end to-start from-indent to-indent &optional copy-p fill-p) "Move tree between FROM-START and FROM-END to TO-START. -Changes indentation from FROM-INDENT to TO-INDENT. +Also change indentation from FROM-INDENT to TO-INDENT. Copy tree if optional COPY-P is non-nil. Refill cells if optional FILL-P is non-nil. Leave point at TO-START." (let ((region (buffer-substring from-start from-end)) From 93457f07a30f6e98a6f4e7c0df7161a1d06216e2 Mon Sep 17 00:00:00 2001 From: Mats Lidell Date: Sun, 9 Oct 2022 18:17:03 +0200 Subject: [PATCH 15/15] Update kotl/kview.el Co-authored-by: Robert Weiner --- kotl/kview.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kotl/kview.el b/kotl/kview.el index c5ba8e0f..055bb22e 100644 --- a/kotl/kview.el +++ b/kotl/kview.el @@ -1201,8 +1201,8 @@ Value may be the character immediately after point." (error "(kview:set-buffer): Invalid kview argument"))) (defun kview:set-cells-status (kview start end cell-status-list) - "Use CELL-STATUS-LIST to restore each cell's status. -Set status in the current buffer's KVIEW, between START and END. + "Restore each cell's status in current buffer's KVIEW between START and END. +Set each cell status from CELL-STATUS-LIST. Status is: 0 if all the lines of the cell are visible and it has no hidden branches; a positive count of the lines displayed in the cell if it has no hidden branches; otherwise, a negative count of the lines