213 Commits

Author SHA1 Message Date
Vassilii Khachaturov
018f0ab30b Revert "6926: display genitive/nominative months as needed"
Sorry, my mistake. Committed from the wrong branch!

This reverts commit 0e82e0077ac1cad122f4584d62b54855ca02e4d8.

svn: r23175
2013-09-20 12:41:46 +00:00
Vassilii Khachaturov
6eebd80dfc 6926: display genitive/nominative months as needed
First proof of concept, fixing the original bug for Russian.
Added gramps/gen/datehandler/_datestrings.py, to hold
all the localized strings, with genitive/nominative
context as appropriate.

Remaining TODO:
1) other languages
2) expand the localized string into RE-style
concat via |, so that displayer uses the 1st instance,
and the parser uses the whole RE. Write the corresponding _().
3) same with short names as with long names
4) harmonize with _grampslocale code reading the names from
elsewhere for Julian/Gregorian months
5) expand to other calendars (non-Julian/non-Gregorian)
6) obsolete the public attributes in dd and replace with accessors

svn: r23173
2013-09-20 12:33:00 +00:00
Vassilii Khachaturov
6c6ca1cd20 Revert*2 "5098: refactor code to use User.progress
Revert*2 means re-apply :-)

svn: r23102
2013-09-12 21:22:14 +00:00
Vassilii Khachaturov
85c1a9a0fd Revert "5098: refactor code to use User.progress"
This reverts commit db9a64ef7da5f26c586452c1a84a96675991d9a4.

This was tested with "runtest.sh" only, but turns out things
are broken under GUI. I'll investigate on a private branch,
reverting meanwhile to unblock the affected plugins on trunk.

svn: r23099
2013-09-12 20:39:07 +00:00
Vassilii Khachaturov
92c13a36bf 5098: refactor old code to use User.progress
Now that #7061 is done, all the old code should no longer use
User.begin_.../step_.../end_progress directly any more, preferring
the context manager instead.

svn: r23096
2013-09-12 19:31:06 +00:00
Paul Franklin
6a4a4a3a9c fix string FIXME, add context for translation, as string freeze is over
svn: r22415
2013-05-23 17:20:56 +00:00
Paul Franklin
b0a3666e5a any documentation is better than none
svn: r22283
2013-05-13 22:21:47 +00:00
Paul Franklin
fcd2296461 enable translated output for this report
svn: r22263
2013-05-11 19:22:17 +00:00
Paul Franklin
620ba618c2 defer translation for one more date, and cleanup translation
svn: r22232
2013-05-09 22:27:41 +00:00
Paul Franklin
d8e3e0fb6f enable translated output for this report
svn: r22208
2013-05-09 05:03:52 +00:00
Paul Franklin
612b893956 better PEP-0008 (trans_text_ ==> trans_text)
PEP-0008 reserves the use of a trailing underscore for names
which conflict with Python keywords, which this doesn't.

The goal is to have a permanent name which is unique across
the gramps namespace, since it is defined (in po/genpot.sh
and po/update_po.py) as a keyword to flag strings to be put
into the translation "catalog" file (gramps.pot).

The new keyword "trans_text" is still unique.  (Also "_T_".)


svn: r22201
2013-05-07 18:59:43 +00:00
Paul Franklin
31699972b8 enable translated output for this report
svn: r22197
2013-05-07 17:17:22 +00:00
Benny Malengier
4621d09d4d 6659: Justified paragraph layout does not work in "Custom Book Text" in book report
svn: r22190
2013-05-07 12:35:33 +00:00
Paul Franklin
16dbd437e1 enable translation of the "Endnotes" section header-word for these reports
svn: r22171
2013-05-04 19:30:40 +00:00
Paul Franklin
da72bfbafb disambiguate the local report argument name (vs. the similar global name)
svn: r22154
2013-05-03 19:17:56 +00:00
Benny Malengier
9f61c09829 6641: Complete Individual Report crashes gramps
svn: r22140
2013-05-02 13:26:21 +00:00
Paul Franklin
c3ce490fa2 enable translated output for this report
svn: r22119
2013-04-29 19:26:41 +00:00
Paul Franklin
a831bb0113 enable translated output for this report
svn: r22114
2013-04-28 19:28:42 +00:00
Paul Franklin
f5eae77246 typos
svn: r22095
2013-04-24 01:01:47 +00:00
Paul Franklin
ad6ed26f70 enable translated output for this report
svn: r22093
2013-04-24 00:12:36 +00:00
Paul Franklin
647bd5800c enable translated output for this report
svn: r22084
2013-04-23 04:54:15 +00:00
Paul Franklin
f4cbda07ec enable translated output for this report
svn: r22082
2013-04-23 04:53:15 +00:00
Paul Franklin
346f982b27 enable translated output for this report
svn: r22080
2013-04-23 04:52:08 +00:00
Paul Franklin
6aeb49aefc enable translated output for this report
svn: r22078
2013-04-23 04:51:00 +00:00
Paul Franklin
be53411b39 enable translated output for this report
svn: r22076
2013-04-23 04:48:57 +00:00
Paul Franklin
df431da250 reenable translated report title
svn: r22074
2013-04-22 18:17:45 +00:00
John Ralls
5db0763970 GrampsLocale: Fix 'Foo has no attribute _Foo__get_type' execption
From moving the set_locale function to the superclass. One can get
carried away with enforcing private attributes...

svn: r22062
2013-04-21 17:49:08 +00:00
John Ralls
769203162c GrampsLocale: Wrap locale.format and locale.format_string
To concentrate the locale dependency in grampslocale.py

svn: r22027
2013-04-20 23:09:09 +00:00
Paul Franklin
dc128110bc typos
svn: r22021
2013-04-19 16:58:24 +00:00
Paul Franklin
3a06d7b204 typo
svn: r22017
2013-04-18 20:56:27 +00:00
Paul Franklin
9804301762 give the "ahnentafel" report a user-settable title string
(since many English speakers do not know what "ahnentafel" means)


svn: r22015
2013-04-18 19:08:46 +00:00
Paul Franklin
cceb28c5b9 refactor: move name_format into stdoptions.py
svn: r22009
2013-04-17 20:49:50 +00:00
John Ralls
00aa00fbf5 GrampsLocale: Remove get_translation()
Only one base translation per locale. To set up a different locale
on any axis (locale, domain, directory, or languages) instantiate a
secondary locale by calling GrampsLocale() with the appropriate
arguments.

svn: r21968
2013-04-12 22:32:11 +00:00
John Ralls
56254d4a14 GrampsLocale: Integrate libtranslate functions into GrampsLocale
And remove libtranslate

svn: r21967
2013-04-12 22:27:54 +00:00
John Ralls
665206df85 GrampsLocale: Extract 2 reporting functions
set_translation() to the Report class
Add a new module stdoptions to gen.plug.report with function
add_localization_option(). The intent of stdoptions is to reduce the code-copying among reports; this is the first bit.

svn: r21966
2013-04-12 22:27:44 +00:00
Paul Franklin
25315ceece add person-index entries, for book report
svn: r21953
2013-04-10 21:56:10 +00:00
Paul Franklin
87c11877f4 add TOC and index entries, for book report
svn: r21952
2013-04-10 20:26:35 +00:00
Paul Franklin
d96c766cb1 add TOC entry, for book report
svn: r21949
2013-04-10 19:05:41 +00:00
Peter Landgren
a71e8f5689 Update for spelling of Family Tree.
svn: r21938
2013-04-10 09:34:27 +00:00
Paul Franklin
cf4a3aefbd shorten the report name for easier CLI use
svn: r21552
2013-03-05 04:45:57 +00:00
Paul Franklin
658134e464 6448: Text Reports>Descendant Report gives an AttributeError: 'Sort' object has no attribute by_birthdate
svn: r21357
2013-02-14 23:41:35 +00:00
John Ralls
fd61b21a2d GrampsLocale: Replace locale.strcoll, locale.strxfrm, and conv*_tosrtkey
With GrampsLocale.sort_key (for strxfrm and conv*_tosrtkey) and
GrampsLocale.strcoll.

If ICU is available will use the correct ICU::Collator for the locale,
otherwise falls back to locale.strxfrm -- for which it temporarily
changes the LC_COLLATE locale.

svn: r21275
2013-02-01 22:49:14 +00:00
John Ralls
72051dd488 GrampsLocale: Replace use of get_language_string with GrampsLocale.get_language_dict
Permits sorting by localized language name.
Also hides the language code, which the user doesn't really care about.
Removes get_language_string from libtranslate.py, no longer needed.

svn: r21236
2013-01-27 21:10:17 +00:00
John Ralls
85a082bb6d Descendant Report: Fix changed Sort function name
svn: r21156
2013-01-17 19:48:58 +00:00
John Ralls
ef6892abbd GrampsLocale: Remove ggettext
svn: r21144
2013-01-17 19:46:55 +00:00
John Ralls
d3c2a8a490 Localization: Re-implement localization as a class, GrampsLocale
GrampsLocale is effectively a singleton: An instance is created in
const.py and retrieved everywhere.

Translations are provided via Translations classes, which are derived
from GNUTranslations and NullTranslations to provide extra functions
like sgettext.

svn: r21143
2013-01-17 19:42:11 +00:00
John Ralls
eecf57a0f6 Rename trans.py and mactrans.py to grampslocale.py and maclocale.py
Reflecting discussion on gramps-devel about their affecting more than
just translations.

Provide for a master GrampsLocale instance to be retrieved from
const.py, set by grampsapp.

svn: r21142
2013-01-17 19:41:58 +00:00
Doug Blank
91173ba2a8 Bumped trunk to 4.1, updated plugins, requires setup.py build rather than copy of const.py.in, show svn number in version number
svn: r20919
2012-12-31 22:51:11 +00:00
Peter Landgren
ee2f5a990d Fix for correct unique surname statistics.
svn: r20686
2012-11-21 12:32:46 +00:00
Benny Malengier
8b39b80dc8 2620: GEPS 031: Python 3 support - 3.2
round 2 for python 3 support:
* no more cmp, also not in sort and sorted
* bsddb needs bytestring keys
* gtk does not need utf-8 encoded anymore...


svn: r20658
2012-11-15 08:08:31 +00:00