[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/embark e86ffc0f62 3/3: Add keymap to org-export a regio
From: |
ELPA Syncer |
Subject: |
[elpa] externals/embark e86ffc0f62 3/3: Add keymap to org-export a region in place |
Date: |
Fri, 6 May 2022 22:57:29 -0400 (EDT) |
branch: externals/embark
commit e86ffc0f6250351d1e20140f8883d8eb0fe91997
Author: Omar Antolín <omar.antolin@gmail.com>
Commit: Omar Antolín <omar.antolin@gmail.com>
Add keymap to org-export a region in place
These commands sound super useful in LaTeX or HTML buffers, since Org
syntax is so much nicer.
---
embark-org.el | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/embark-org.el b/embark-org.el
index 502557f145..1d065cbb86 100644
--- a/embark-org.el
+++ b/embark-org.el
@@ -328,5 +328,18 @@ also the whole target.")
(add-to-list 'embark-keymap-alist '(org-src-block . embark-org-src-block-map))
+;;; "Encode" region using Org export in place
+
+(embark-define-keymap embark-org-export-in-place-map
+ "Keymap for actions which replace the region by an exported version."
+ ("m" org-md-convert-region-to-md)
+ ("h" org-html-convert-region-to-html)
+ ("a" org-ascii-convert-region-to-ascii)
+ ("l" org-latex-convert-region-to-latex))
+
+(fset 'embark-org-export-in-place-map embark-org-export-in-place-map)
+
+(define-key embark-encode-map "o" 'embark-org-export-in-place-map)
+
(provide 'embark-org)
;;; embark-org.el ends here