branch: externals/org-translate commit 7d067b4c47b269dfee6f6e6a9fd5f418a7ab50f7 Author: Eric Abrahamsen <e...@ericabrahamsen.net> Commit: Eric Abrahamsen <e...@ericabrahamsen.net>
Disable removal of segmentation characters on export * org-translate.el (org-translate-mode): This doesn't work the way it was intended, and needs some more thought. Disable for now. --- org-translate.el | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/org-translate.el b/org-translate.el index 76e2c66ccf..f03c9dc30a 100644 --- a/org-translate.el +++ b/org-translate.el @@ -366,7 +366,8 @@ By default, just remove it." ogt-source-segment-overlay (make-overlay (point) (point))) (error (org-translate-mode -1) (signal (car err) (cdr err)))) - (cl-pushnew #'ogt-export-remove-segmenters org-export-filter-body-functions) + ;; (cl-pushnew #'ogt-export-remove-segmenters + ;; org-export-filter-body-functions) (overlay-put ogt-source-segment-overlay 'face 'highlight) ;; Doesn't actually delete it, just makes it "inactive" until we @@ -410,6 +411,11 @@ By default, just remove it." (ogt-update-source-location) (ogt-report-progress)))) +;; Two problems with this: it's currently added to the global value of +;; `org-export-filter-body-functions', meaning it will get run on any +;; Org export process the user runs. Second, +;; `ogt-segmentation-character' is buffer-local, and will be nil in +;; the copy of the buffer that Org uses for export. (defun ogt-export-remove-segmenters (body-string _backend _plist) "Remove `ogt-segmentation-character' on export." ;; Is `org-export-filter-body-functions' the right filter to use?