Browse Source

Fix region

master
10sr 6 years ago
parent
commit
2f2b03f74f
Signed by: 10sr GPG Key ID: 7BEC428194130EB2
1 changed files with 8 additions and 1 deletions
  1. +8
    -1
      emacs.el

+ 8
- 1
emacs.el View File

@@ -1930,7 +1930,11 @@ DISPLAY non-nil means redisplay buffer as output is inserted."

(defun awk-preview (beg end)
"Run awk and preview result."
(interactive "r")
(interactive (if (use-region-p)
(list (region-beginning)
(region-end))
(list (point-min)
(point-max))))
(when (and awk-preview--env
(awk-preview--env-running-p awk-preview--env))
(error "AWK-Preview already running"))
@@ -2020,6 +2024,9 @@ DISPLAY non-nil means redisplay buffer as output is inserted."
(define-key map (kbd "C-c C-l") 'awk-preview-update-preview)
(define-key map (kbd "C-c C-k") 'awk-preview-abort)
(define-key map (kbd "C-c C-c") 'awk-preview-commit)
;; TODO: Implement
;; Back preview buffer to original content
(define-key map (kbd "C-c C-r") 'awk-preview-clear)
map)
"Keymap for `awk-preview-program-mode'.")



Loading…
Cancel
Save