Quellcode durchsuchen

Experimental implement of translate-popup-at-point

pull/15/head
10sr vor 8 Jahren
Ursprung
Commit
13204f6a08
1 geänderte Dateien mit 9 neuen und 0 gelöschten Zeilen
  1. +9
    -0
      emacs.el

+ 9
- 0
emacs.el Datei anzeigen

@@ -1858,4 +1858,13 @@ This mode is a simplified version of `adoc-mode'.")
(add-to-list 'auto-mode-alist
'("\\.adoc\\'" . adoc-simple-mode)))

(when (safe-require-or-eval 'google-translate)
(add-to-list 'google-translate-translation-directions-alist
'("en" . "ja"))
(defun translate-popup-at-point ()
"Translate popup at point."
(interactive)
(let ((google-translate-output-destination 'popup))
(google-translate-translate "en" "ja" (current-word t t)))))

;;; emacs.el ends here

Laden…
Abbrechen
Speichern