branch: externals/do-at-point
commit b9d8db8218a05acc1ad1018f303deeeef87fea9a
Author: Philip Kaludercic <[email protected]>
Commit: Philip Kaludercic <[email protected]>

    Add transposition actions
---
 do-at-point.el | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/do-at-point.el b/do-at-point.el
index 4911af81e9..f6719d251a 100644
--- a/do-at-point.el
+++ b/do-at-point.el
@@ -123,12 +123,20 @@ of this variable.")
      (?* "Calc" ,(lambda () (calc-embedded '(t)))))
     (word
      (?$ "Spell check" ,(lambda () (ispell-word)))
-     (?d "Dictionary" ,#'dictionary-search))
+     (?d "Dictionary" ,#'dictionary-search)
+     (?t "Transpose" ,(lambda () (transpose-words 1))))
     (symbol
      (?. "Xref" ,#'xref-find-definitions)
      (?o "Occur" ,(lambda (str)
                     (occur (concat "\\_<\\(" (regexp-quote str) "\\)\\_>")))))
-    (string) (sexp) (line) (paragraph (?$))
+    (string)
+    (sexp
+     (?t "Transpose" ,(lambda () (transpose-sexps 1))))
+    (line
+     (?t "Transpose" ,(lambda () (transpose-lines 1))))
+    (paragraph
+     (?$)
+     (?t "Transpose" ,(lambda () (transpose-paragraphs 1))))
     (defun
         (?e "Evaluate" ,(lambda () (eval-defun nil)))))
   "Association of things and their respective actions.

Reply via email to