bug-gettext
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gettext] [bug #50830] PO mode does not find any translatable st


From: Peter Hull
Subject: Re: [bug-gettext] [bug #50830] PO mode does not find any translatable strings when electric-mode is enabled
Date: Wed, 19 Apr 2017 10:49:01 +0100

On Wed, Apr 19, 2017 at 10:27 AM, Bruno Haible <address@hidden> wrote:
> URL:
>   <http://savannah.gnu.org/bugs/?50830>
>
>                  Summary: PO mode does not find any translatable strings when
> electric-mode is enabled
Thanks, Bruno.
The following change fixes it for me (sorry, was not able to attach it
to the bug report) - hopefully will be useful.

--- /usr/share/emacs/site-lisp/gettext/po-mode.el    2016-02-10
12:13:03.000000000 +0000
+++ po-mode.el    2017-04-19 10:38:36.413602789 +0100
@@ -2931,7 +2931,8 @@
 These variables are locally set in source buffer only when not already bound."
   (let ((pair (cond ((string-equal mode-name "AWK")
                      '(po-find-awk-string . po-mark-awk-string))
-                    ((member mode-name '("C" "C++"))
+                    ((let ((major-only (car (split-string mode-name "/"))))
+                       (member major-only '("C" "C++")))
                      '(po-find-c-string . po-mark-c-string))
                     ((string-equal mode-name "Emacs-Lisp")
                      '(po-find-emacs-lisp-string . po-mark-emacs-lisp-string))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]