Changeset main,18 for main


Ignore:
Timestamp:
06/06/2020 01:04:16 AM (4 years ago)
Author:
David Owen <dsowen@…>
branch-nick:
main
revision id:
dsowen@fugue88.ws-20200606010416-6ms2uo9nin6axt19
Message:

Switch to overlay for marking

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/org-autofocus.el

    r17 r18  
    7575(defun org-af--mark (point)
    7676  "Mark the task at POINT."
    77   (add-text-properties point (1+ point) '(category org-af-marked)))
     77  (let ((o (make-overlay point (1+ point))))
     78    (overlay-put o 'category org-af-marked)))
    7879
    7980(defun org-af--unmark (point)
    8081  "Unmark the task at POINT."
    81   (remove-text-properties point (1+ point) '(category org-af-marked)))
     82  (remove-overlays point (1+ point) org-af-marked t))
    8283
    8384(defun org-af--marked-p (point)
    8485  "Test whether the task at POINT is marked."
    85   (get-text-property point 'org-af-marked))
     86  (get-char-property point 'org-af-marked))
    8687
    8788
Note: See TracChangeset for help on using the changeset viewer.