[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: prevent inserting \n symbol in the end of lines in emacs po-mode
From: |
pelzflorian (Florian Pelz) |
Subject: |
Re: prevent inserting \n symbol in the end of lines in emacs po-mode |
Date: |
Sat, 13 Apr 2019 19:53:00 +0200 |
User-agent: |
NeoMutt/20180716 |
On Sat, Apr 13, 2019 at 04:45:21PM +0000, address@hidden wrote:
> When editing .po file in emacs po-mode and inserting two lines into
> msgstr, emacs adds "n" symbol.
>
> And it breaks the logic here:
>
> #. type: Plain text
> #: doc/contributing.texi:141
> msgid ""
> "@dots{} and for a REPL (@pxref{Using Guile Interactively,,, guile, Guile "
> "Reference Manual}):"
> msgstr ""
> "@dots{} и для REPL (@pxref{Using Guile Interactively,,, guile, Guilen"
> "Reference Manual}):"
>
> http://0x0.st/zNAS.png (http://0x0.st/zNAS.png)
>
> I think link to Guile Reference manual will not work with n in the
> middle of it.
>
This \n is printed in place of a newline character. I believe you
have wrapped the paragraph to multiple lines when it must be on a
single line. Normally I press Ctrl+J to copy the original msgid and
adapt it without adding newlines.
> I've enabled long-line-mode as described here
> https://www.emacswiki.org/emacs/PoMode
> (https://www.emacswiki.org/emacs/PoMode) (and including longlines.el
> into .emacs)
>
> So I can create long-long lines and they are displaying convenient
> way. And I've compared french translation does not follow the same
> line length rule as in original po file: http://0x0.st/zNmQ.png
>
When you open the French PO file and start editing the msgstr in
emacs’ po-mode, you will see it has no line wrapping any more. The
paragraph that was a single line must be on a single line when editing
it in emacs’ po-mode.
> But nevertheless is it necessary to insert translation messages
> strings with line breaks but without emacs insert 'n' in the end of
> line?
I do not know emacs well enough. Maybe there is a way to print long
lines more nicely, but I just go with an ugly long line. A single
line must remain a single line for the po-mode logic.
Regards,
Florian