Commit graph

1663 commits

Author SHA1 Message Date
Dirk Hohndel
dbae888abc Handle dates and a "calculated plural" in translations
This looks like a massive commit mainly because of the line number changes
in the .po files. That sadly hides what really happened here:

- the places where we manually build dates have now been localized
- the one place where we did the English "calculated plural" has been
  modified so that it now can be correctly translated (in English this
  just adds an 's' to the noun if the number is != 1 - in other languages
  this tends to be much more complicated)

I then updated the two German translations to take advantage of the new
constructs. And while I was at it, I changed the translation Trip->Gruppe
to Trip->Reise as that seemed much more appropriate.
I also fixed another error in the German translation where I translated
"dive time" as "Startzeit" - but in the context it was "Dauer".

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-17 01:25:49 -07:00
Henrik Brautaset Aronsen
9c62e223d3 Install all .mo files on all targets
Linux didn't have a locale install target, and Windows didn't install
aliased locale files.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-17 00:04:18 -07:00
Dirk Hohndel
40ae90920a Fix typo and make variable name more logical
[the macos/macosx typo was also found and a patch submitted by
 Henrik Brautaset Aronsen <subsurface@henrik.synth.no>]

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 23:55:35 -07:00
Dirk Hohndel
04c5e65b8c Redoing the Mac bundling
With the right tools in place you can now create a bundle from the
Makefile by calling "make create-macos-bundle"

In the process of this I also moved the locale directory where we stage
our .mo files to share/locale (which is much more logical).

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 21:37:43 -07:00
Henrik Brautaset Aronsen
0d89d511bb Adjust locale path for install-macosx target
gtk-mac-bundler uses Contents/Resources/share/locale, and
the install-macosx target should do the same.

Also quiet down the make process a bit

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 13:11:12 -07:00
Linus Torvalds
8bda0c5047 Minimal Swedish translation update
This doesn't really improve any of the horrible Swedish texts, but
updates it for the message text fuzziness due to the text changes

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 11:43:34 -07:00
Dirk Hohndel
bb7a11e638 Update Dutch translation
The best translations are those maintained by people that don't speak the
language. As I don't speak Dutch I make no promises on the correctness of
this.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 11:15:56 -07:00
jnoel
66276882b9 Update po/fr_FR.po
Update of the french translation file.
Fuzzy mark update with single line.

[Dirk Hohndel: removed Jacco and myself - we didn't do French]

Signed-off-by: Jean-Noël Rouchon <jnoel@sissiou.net>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 11:00:16 -07:00
Henrik Brautaset Aronsen
13cc5afb7f Avoid zero degrees Kelvin in yearly statistics
Maximum and minimum degrees in the yearly statistics were displayed
as -273.1°C if no temperature info was present.

H

From 7d9aad01133bc03980f66a2d109c9ef909e518ad Mon Sep 17 00:00:00 2001
From: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Date: Tue, 16 Oct 2012 18:13:16 +0200
Subject: [PATCH] Avoid zero degrees Kelvin in yearly statistics
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Maximum and minimum degrees in the yearly statistics were displayed
as -273.1°C if no temperature info was present.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 09:19:48 -07:00
Dirk Hohndel
faff4d29dd Update version to 2.1-rc1
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 09:15:03 -07:00
Dirk Hohndel
0e7246b0b4 Fix another bug where we make assumptions about the length of a string
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 09:01:04 -07:00
Dirk Hohndel
bfd6ce0f1f Localization prevents us from from making assumptions about string length
Restructure some code to work around that.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 08:33:03 -07:00
Henrik Brautaset Aronsen
f45285d461 Support for language aliases.
Some languages have identifiers that gettext can't determine
automatically in all OS'es.  An example is Norwegian (no_NO, deprecated)
with its Bokmål (nb_NO) and Nynorsk (nn_NO) form.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 07:30:59 -07:00
Dirk Hohndel
9dc667e883 Renamed the Norwegian .po file
At least on Windows this now will make things work correctly, as the gtk
localization is named nb - so nb_NO.UTF-8 is consistent with that.

MacOS still appears to need some special handling.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 04:30:07 -07:00
Henrik Brautaset Aronsen
f03d29b48b Added a terrible spanish translation.
I don't know any Spanish at all. This translation was made with
Google Translate, perl and sed, and will annoy anyone who knows
Spanish.  Hopefully enough so that they will fix it.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 04:09:22 -07:00
Dirk Hohndel
a9f3655d1a Improved packaging for Windows
This commit adds an install-cross-windows target to the Makefile that
creates a staging directory for us under packaging/windows that contains
the required .mo files. This currently fails for the Norwegian translation
because of the no_NO.UTF-8 vs nb issue - right now we just use the first
component of our own localization filename to find the matching Windows
localization and that fails.

The subsurface.nsi file is updated accordingly and this now appears to
create working installers with sane paths for the localization files.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 04:08:33 -07:00
Lubomir I. Ivanov
5bf6723d26 More fixes in the Bulgarian translation
- Added the missing statistics translations
- Clearer translation in the Dive->View submenu

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 02:25:16 -07:00
Henrik Brautaset Aronsen
ea48829ba5 Updated Norwegian translation
Dirk had some changes in commit f1569a206e

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 02:17:52 -07:00
Lubomir I. Ivanov
cc08e03678 subsurface.nsi: call RMDir for the 'share' and 'locale' subfolders
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-16 02:16:42 -07:00
Dirk Hohndel
fada2f6bc6 Better Windows installer .nsi file
This still requires on carefully staged files in the packaging/windows
directory. Specifically:

- the dll directory (or symlink) points to the installed gtk Windows DLLs
- the mydll directory (or symlink) contains six other DLLs (where the
  cross built DLLs from Fedora for some reason file, but can be
  transparently replaced with the ones from the upstream binary
  package
- the share directory contains the Windows gtk locale files (but only for
  the locales that we support, anyway)

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 21:27:16 -07:00
Jozef Ivanecký
ac3124b8d0 Update Slovak translation
Signed-Off-By: Jozef Ivanecký (dodo.sk@gmail.com)
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 16:34:28 -07:00
Dirk Hohndel
f97f75f961 Set locale under Windows
This is mostly a quick hack to be able to test localization under Windows.
It seems to work fine under Windows 7

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 16:32:11 -07:00
Dirk Hohndel
72c7d7c9c4 Small adjustments to the German translation
Consistently use "Ø" for average.

Use Tauchgruppenleiter and Leiter instead of Tauchgruppenführer and
Führer.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 15:23:16 -07:00
Dirk Hohndel
9b9e36886c Forgot to localize names of months and weekdays
We marked the strings for translation, but then didn't actually call the
translation function on them.

Our dates are still not truely localized as we have hand written code for
the date / time handling that constructs the dates according to US fashion
as [Weekday], [Month] [Day of Month], [Year] [hh:mm]

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 14:37:59 -07:00
Tommi Saviranta
0cee29121d Updated Finnish translation
- Use message context for better translation
- Fixed some strings to form proper sentences

Signed-off-by: Tommi Saviranta <wnd@iki.fi>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 13:34:37 -07:00
Dirk Hohndel
7e703b7a1d Fix incorrect localization of dialog name
The existing code passed a localized copy of a text buffer initialized by
a static string to a function that ended up wanting to modify the buffer.
Unsurprisingly, that doesn't work. This commit restructures the code so
that we initialize the buffer at run time with a localized version of the
default string and then just pass the buffer around.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 13:29:37 -07:00
Lubomir I. Ivanov
dc7a831cde Improved Bulgarian translation
- Shortened long phrases
- Better lowercase/uppercase consistency
- Fixed a couple of typos

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 11:15:10 -07:00
Ivan Habunek
00eb9bde56 Initial Croatian translation.
Signed-off-by: Ivan Habunek <ivan.habunek@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 10:02:44 -07:00
Martin Gysel
da2a0562ab Swiss-High-German translation
Here's the Swiss-(High-)German translation which is mostly based on the
German translation.

Most notable differences are:
- in Switzerland, 'ß' doesn't exist (fortunately)
- keep some English words where the German translation sounds strange or
  unfamiliar (nobody in Switzerland would ever use the word
  Tauchgruppenführer)

Signed-off-by: Martin Gysel <me@bearsh.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 09:42:55 -07:00
Dirk Hohndel
4b9a59a154 Merge branch 'gettext'
Bring all the localization changes into master in preparation for
Subsurface 2.1
2012-10-15 09:37:09 -07:00
Henrik Brautaset Aronsen
ef039c9d32 Support for gettext in MacOSX application bundle
The MacOSX applications bundle needs to be told where to bind the
text domain from.

Also copy the gettext .mo files in the install-macosx target.

[Dirk Hohndel: minor change in main(): move the path declaration to
               the beginning of the function]

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-15 09:36:30 -07:00
jnoel
5c432d3c8a Update po/fr_FR.po
Just a few spelling corrections for fr_FR translation file

Signed-off-by: Jean-Noël Rouchon <jnoel@sissiou.net>
2012-10-15 09:34:37 -07:00
Dirk Hohndel
f1569a206e Improve translations
- fix two missing strings in equipment.c (thanks to Tommi Saviranta for
  pointing this out)

- add context for the translations of the Yearly/monthly statistics. The code
  for this ended up being incredibly ugly, but the gettext infrastructure
  really clashed with the way this is implemented. What I have now at least
  works (tested with the German translation)

- merge the new strings into all the po files. The non-German translations need
  to be updated. Make sure you remove the "# , fuzzy" lines or the current
  Makefile will ignore those additions.

- some minor cleanup of the po files (many listed the wrong language, all of
  them copied my incorrect use of PACKAGE (instead of saying "Subsurface").

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-14 20:47:00 -07:00
Miika Turkia
a3e7a46f12 Change character encoding from iso-8859-1 to UTF8
Finnish translation was with wrong character encoding resulting in
compile error.

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-13 17:04:43 -07:00
Dirk Hohndel
cb4bdfcea1 Improve German translations
The changes were mostly suggested by Lutz, but since he didn't send a
patch, I manually applied them.

Suggested-by: Lutz Vieweg <lvml@5t9.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-13 17:02:58 -07:00
Tommi Saviranta
8cc538ddd3 Add Finnish translation
This translation is partly based on Finnish Divers' Federation's printed
dive log and partly on my best guess. Some of the translated strings
have been (badly) shortened to fit the UI, and many others still neen be
shortened.

Signed-off-by: Tommi Saviranta <wnd@iki.fi>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-13 09:29:09 -07:00
Ďoďo
d27eb4f503 Slovak translation
Also fixed two typos in the German translations.

Signed-Off-By: Jozef Ivanecký (dodo.sk@gmail.com)
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-13 09:01:25 -07:00
Pierre-Yves Chibon
549425a692 Created first french translation of Subsurface
Signed-off-by: Pierre-Yves Chibon <pingou@pingoured.fr>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 12:22:36 -07:00
Henrik Brautaset Aronsen
cfaa5563bf Better gettext build
My previous take at adding gettext to the Makefile wasn't very good,
since it always relinked the subsurface executable.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 12:17:09 -07:00
Linus Torvalds
920c1e58ff Add Swedish translation
This is a horrible mish-mash of the english and norwegian translation
and my random odd swedish translations of them.

It's bad. But it's a starting point. If somebody complains, they
hopefully say things like "That should be xyz" and it can be fixed.

[Dirk Hohndel: minor edit to the .po file to at least no longer claim to
               be Norwegian...]

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 12:37:22 +09:00
Dirk Hohndel
efb1928d51 Add translation files to the Windows installer package
A lot more needs to happen for localization on Windows, but this is the
first step.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 12:33:24 +09:00
Lubomir I. Ivanov
fcb09c8078 Add Bulgarian translation
Some of the exact translations of terminology such as SAC (ППК) might
need a revision by an expert. Also, some of the things ended up being up
2-3 times longer (similar to German), so I'm not sure how this is going to
reflect on the UI.

[Dirk Hohndel: minor fixes to the .po file to make it compile]

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 06:52:12 +09:00
Dirk Hohndel
5801dcf78b Use lang_COUNTRY.po naming convention for translation files
Rename nl.po to nl_NL.po

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 06:39:18 +09:00
Henrik Brautaset Aronsen
134c76ab80 Updated Norwegian translation
Added the missing translations for the File menu et al.

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-12 06:32:26 +09:00
Dirk Hohndel
a68945646d Update German translations for newly added menu strings
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 23:15:08 +09:00
Dirk Hohndel
45e84618f5 Make translations of menu entries explicit
It appears that at least for Norwegian the translations of the stock menu
entries was missing. This patch adds those as explicit strings and merges
those new strings into the .po files.

The translations need to be updated in separate commits.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 23:08:45 +09:00
Jacco van Koll
2a6db9c7ae Add Dutch localization
Signed-off-by: Jacco van Koll <jacco.van.koll@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 22:27:16 +09:00
Dirk Hohndel
d4a3ecedb0 Get divelist headers localized, too
This fixes an oversight in commit 881a2df83616 ("Conversion to gettext to
allow localization") - string literals that are marked with N_ need to be
converted when the corresponding variables are used at runtime. This was
missed for the divelist headers.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 22:03:10 +09:00
Henrik Brautaset Aronsen
f5de37dbcf Basic gettext support when building
Added basic support for building gettext locales in the Makefile.
The po file name should match the target locale.

[Dirk Hohndel: Used git mv to rename the German .po file]

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 21:45:30 +09:00
Henrik Brautaset Aronsen
21dec2a134 More gtk-mac-bundler improvements
Without "-headerpad_max_install_names", gtk-mac-bundler would complain
with "changing install names or rpaths can't be redone for:
/Applications/.subsurface.app/Contents/MacOS/subsurface-bin (for
architecture x86_64) because larger updated load commands do not fit"

Also, libdivecomputer needs to be configured with --with-prefix=/opt/local

Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2012-10-11 21:37:54 +09:00