Compare commits
10 Commits
master
...
genealogyt
Author | SHA1 | Date | |
---|---|---|---|
|
fe0f125ad6 | ||
|
e8b63987ac | ||
|
461ee4fe5c | ||
|
d571516212 | ||
|
9208b8a3a8 | ||
|
9e013f6781 | ||
|
c460506e4f | ||
|
3fcb9411dc | ||
|
f7a50a0e74 | ||
|
6709d37526 |
@ -46,8 +46,14 @@ from ..menu import NumberOption, TextOption, EnumeratedListOption
|
||||
from ...constfunc import win
|
||||
from ...config import config
|
||||
from ...const import GRAMPS_LOCALE as glocale
|
||||
from ...utils.grampslocale import GrampsLocale
|
||||
_ = glocale.translation.gettext
|
||||
|
||||
LOCALE = GrampsLocale(lang='en')
|
||||
|
||||
LATIN = ['french', 'italian', 'spanish']
|
||||
LANG_SUPPORT = ['danish', 'dutch', 'german', 'swedish'] + LATIN
|
||||
|
||||
#-------------------------------------------------------------------------
|
||||
#
|
||||
# set up logging
|
||||
@ -339,6 +345,14 @@ class TreeDocBase(BaseDoc, TreeDoc):
|
||||
self.write(0, '\\usepackage[%s,%s]{geometry}\n' % (paper, margin))
|
||||
self.write(0, '\\usepackage[all]{genealogytree}\n')
|
||||
self.write(0, '\\usepackage{color}\n')
|
||||
trans = glocale.language[0][:2]
|
||||
lang = LOCALE._get_language_string(trans).lower()
|
||||
if lang in LANG_SUPPORT:
|
||||
self.write(0, '\\gtrset{language=%s}\n' % lang)
|
||||
if lang in LATIN:
|
||||
self.write(0, '\\IfFileExists{lmodern.sty}{\n')
|
||||
self.write(0, ' \\usepackage{lmodern}\n')
|
||||
self.write(0, '}{}\n')
|
||||
self.write(0, '\\begin{document}\n')
|
||||
|
||||
if self.nodecolor == 'preferences':
|
||||
|
Loading…
Reference in New Issue
Block a user