[pacman-dev] [PATCH] Fixed wrong alignment in the italian translation.
Added missing blank spaces in 'Dimensione :' string. Signed-off-by: David Barchiesi <david@barchie.si> --- src/pacman/po/it.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pacman/po/it.po b/src/pacman/po/it.po index bb4fff9..67724a0 100644 --- a/src/pacman/po/it.po +++ b/src/pacman/po/it.po @@ -624,7 +624,7 @@ msgstr "Sostituisce :" #: src/pacman/package.c:170 #, c-format msgid "Download Size :" -msgstr "Dimensione :" +msgstr "Dimensione :" #: src/pacman/package.c:173 #, c-format -- 2.6.1
On 13/10/15 23:23, David Barchiesi wrote:
Added missing blank spaces in 'Dimensione :' string.
Signed-off-by: David Barchiesi <david@barchie.si>
Translations all need done through the Transifex project: https://www.transifex.com/toofishes/archlinux-pacman/ Allan
I don't know if this was previously mentioned, but this alignment issue has been around for a while. Swedish is completely broken. A few other languages I've tried also have issues. I am not sure which would be the sanest choice: * Consider that pacman's output will be stable from now on and fix alignment in every .po. * Move alignment away from .po files. Let pacman compute the max string length and pad spaces accordingly to the description strings upon initialization. -- Pierre Neidhardt An American is a man with two arms and four wheels. -- A Chinese child
On 15/10/15 18:08, Pierre Neidhardt wrote:
I don't know if this was previously mentioned, but this alignment issue has been around for a while. Swedish is completely broken. A few other languages I've tried also have issues.
I am not sure which would be the sanest choice:
* Consider that pacman's output will be stable from now on and fix alignment in every .po.
I have asked for that to be done for at least the last three major releases... Lets assume this will never happen.
* Move alignment away from .po files. Let pacman compute the max string length and pad spaces accordingly to the description strings upon initialization.
That is the preferred solution. There was the start of a patch set at one stage, but it was never finished. Allan
I can give the second solution a try. Link to the patch? -- Pierre Neidhardt I think we're all Bozos on this bus. -- Firesign Theatre
On 15/10/15 20:59, Pierre Neidhardt wrote:
I can give the second solution a try. Link to the patch?
https://patchwork.archlinux.org/patch/1131/ https://patchwork.archlinux.org/patch/1132/ https://patchwork.archlinux.org/patch/1133/ Mostly the last one I think... It has been more than three years since I looked at this. Allan
On 15-10-15 21:11:22, Allan McRae wrote:
https://patchwork.archlinux.org/patch/1131/ https://patchwork.archlinux.org/patch/1132/ https://patchwork.archlinux.org/patch/1133/
Mostly the last one I think... It has been more than three years since I looked at this.
Are you already there, in 2016? :D Jokes aside, I had a look at the code + the patch set. Patch 2 and 3 do some minor refactoring: * Compute 'len' early. I don't see the point, it is less clear and wastes some cycles. * Move some *_display function from util.c to package.c and make them static. This makes the code base less uniform. I don't think that the potential (?) code optimization is worth it. * Rename 'cols' to maxcols'. Why not. * Replace the indentation loop with a printf("%-*s"...). Why not. Patch 4 does more important refactoring. It moves a lot of code out of util.c to the new termio.c. Some functions have been added, which possibly factor some redundant parts. (I would need to study the code a little bit more to make sure of this). The resulting code base is bigger: 240 insertions(+), 154 deletions(-), so I am not sure where the gain is. Now: * I could not see anything related to alighment. I suppose the patch set was laying the ground work for further improvements. * Do you think it is worth basing future work on this patch set? I would say no at first glance. * I can see 2 ways to fix the alignment issue: 1) Remove the (regex) " *:" in every string including .po's and pad spaces dynamically. The current .po maintenance seems rather shallow, and this will keep alignment broken for most locales for a while. (Actually, it will make it worse!) 2) Keep existing strings unchanged, ignore everything that matches " *:" and align from there. This is a bit dirty in the sense that this special case will remain even after the " *:" are gone from the .po. I'd rather go for 1). Do you think it would be easy to batch process all .po's on Transifex? I have absolutely no clue, I've never used it. -- Pierre Neidhardt
I have just sent a patch for title alignment. I tested it on sv_SE.utf8 after removing all the " *:" from sv.po. Note that "Backup Files\n:" was changed to "Backup Files". The '\n' was moved to the format string, which is better design anyways. I've renamed SHA256 to SHA-256 to merge 2 translation strings. Next step would be to adapt all .po files. For now they are even more broken after applying the alignment patch. That's a big call to Transifex, isn't it? -- Pierre Neidhardt Treat your friend as if he might become an enemy. -- Publilius Syrus
participants (3)
-
Allan McRae
-
David Barchiesi
-
Pierre Neidhardt