Subject: [bug#31500] [PATCH 09/20] gnu: Add emacs-google-translate.

From: Pierre Neidhardt <[email-masked]>
Date: Tue, 22 May 2018 12:41:22 +0200

* gnu/packages/emacs.scm (emacs-google-translate): New variable.
---
 gnu/packages/emacs.scm | 37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index d546ee555..595be5bbf 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -10717,3 +10717,40 @@ A screenshot is taken for every user action.  Call
 @code{gif-screencast-stop} (<f9> by default) to finish recording and create
 the GIF result.")
     (license license:gpl3+)))
+
+(define-public emacs-google-translate
+  (package
+    (name "emacs-google-translate")
+    (version "20170713.119")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append
+             "https://melpa.org/packages/google-translate-"
+             version
+             ".tar"))
+       (sha256
+        (base32
+         "19v9xajksn0idq31jy3spcgajvqpab73bs2gcfgri2q882l0xyg0"))))
+    (build-system emacs-build-system)
+    (home-page "https://github.com/atykhonov/google-translate")
+    (synopsis "Emacs interface to Google Translate")
+    (description
+     "Setup:
+@code{
+(require 'google-translate)
+(require 'google-translate-default-ui)
+(global-set-key \"\\C-ct\" 'google-translate-at-point)
+(global-set-key \"\\C-cT\" 'google-translate-query-translate)}
+
+or
+
+@code{(require 'google-translate)
+(require 'google-translate-smooth-ui)
+(global-set-key \"\\C-ct\" 'google-translate-smooth-translate)}
+
+The difference between these configurations is in UI which will be used:
+Default UI or Smooth UI.  Please read the source of
+@code{google-translate-default-ui.el} and @code{google-translate-smooth-ui.el}
+for more details.")
+    (license license:gpl3+)))
-- 
2.17.0