Tidy: Use compat and newer symbol names
This commit is contained in:
parent
0ab236f95b
commit
c62ff77cd3
3 changed files with 8 additions and 7 deletions
|
|
@ -82,7 +82,7 @@ To be used in, e.g. annotation functions.")
|
|||
(defun org-ql-completing-read-action ()
|
||||
"Default action for `org-ql-completing-read'.
|
||||
Returns (STRING . MARKER) cons for entry at point."
|
||||
(font-lock-ensure (point-at-bol) (point-at-eol))
|
||||
(font-lock-ensure (pos-bol) (pos-eol))
|
||||
(cons (org-link-display-format (org-entry-get nil "ITEM")) (point-marker)))
|
||||
|
||||
(defun org-ql-completing-read-snippet (marker)
|
||||
|
|
@ -155,7 +155,7 @@ single predicate)."
|
|||
(cl-labels (;; (debug-message
|
||||
;; (f &rest args) (apply #'message (concat "ORG-QL-COMPLETING-READ: " f) args))
|
||||
(action ()
|
||||
(font-lock-ensure (point-at-bol) (point-at-eol))
|
||||
(font-lock-ensure (pos-bol) (pos-eol))
|
||||
;; This function needs to handle multiple candidates per
|
||||
;; call, so we loop over a list of values by default.
|
||||
(pcase-dolist (`(,string . ,marker) (funcall action-filter (funcall action)))
|
||||
|
|
|
|||
|
|
@ -302,10 +302,10 @@ SLOT is passed to `display-buffer-in-side-window', which see."
|
|||
(defun org-ql-view-switch ()
|
||||
"Switch to view at point."
|
||||
(interactive)
|
||||
(let ((key (buffer-substring-no-properties (point-at-bol) (point-at-eol))))
|
||||
(let ((key (buffer-substring-no-properties (pos-bol) (pos-eol))))
|
||||
(unless (string-empty-p key)
|
||||
(ov-clear :org-ql-view-selected)
|
||||
(ov (point-at-bol) (1+ (point-at-eol)) :org-ql-view-selected t
|
||||
(ov (pos-bol) (1+ (pos-eol)) :org-ql-view-selected t
|
||||
'face '(:weight bold :inherit highlight))
|
||||
(org-ql-view key))))
|
||||
|
||||
|
|
@ -369,7 +369,7 @@ update search arguments."
|
|||
(defun org-ql-view-customize ()
|
||||
"Customize view at point in `org-ql-view-sidebar' buffer."
|
||||
(interactive)
|
||||
(let ((key (buffer-substring-no-properties (point-at-bol) (point-at-eol))))
|
||||
(let ((key (buffer-substring-no-properties (pos-bol) (pos-eol))))
|
||||
(customize-option 'org-ql-views)
|
||||
(search-forward (concat "Name: " key))))
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
;; Author: Adam Porter <adam@alphapapa.net>
|
||||
;; Url: https://github.com/alphapapa/org-ql
|
||||
;; Version: 0.8-pre
|
||||
;; Package-Requires: ((emacs "26.1") (dash "2.18.1") (f "0.17.2") (map "2.1") (org "9.0") (org-super-agenda "1.2") (ov "1.0.6") (peg "1.0.1") (s "1.12.0") (transient "0.1") (ts "0.2-pre"))
|
||||
;; Package-Requires: ((emacs "26.1") (compat "29.1") (dash "2.18.1") (f "0.17.2") (map "2.1") (org "9.0") (org-super-agenda "1.2") (ov "1.0.6") (peg "1.0.1") (s "1.12.0") (transient "0.1") (ts "0.2-pre"))
|
||||
;; Keywords: hypermedia, outlines, Org, agenda
|
||||
|
||||
;;; License:
|
||||
|
|
@ -43,6 +43,7 @@
|
|||
(require 'seq)
|
||||
(require 'subr-x)
|
||||
|
||||
(require 'compat)
|
||||
(require 'dash)
|
||||
(require 'map)
|
||||
(require 'ts)
|
||||
|
|
@ -1973,7 +1974,7 @@ language. Matching is done case-insensitively."
|
|||
(point)))
|
||||
(contents-end (progn
|
||||
(goto-char (match-end 0))
|
||||
(point-at-bol))))
|
||||
(pos-bol))))
|
||||
(cl-loop for re in regexps
|
||||
do (goto-char contents-beg)
|
||||
always (re-search-forward re contents-end t))))))))))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue