• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

MakefileH A D26-Dec-2018821 4533

READMEH A D26-Dec-20182.1 KiB8453

ast.poH A D26-Dec-201846.3 KiB2,4251,851

be.poH A D26-Dec-201866.4 KiB2,4261,852

bg.poH A D26-Dec-201845.5 KiB2,4261,852

ca.poH A D26-Dec-201850.8 KiB2,4261,852

cs.poH A D26-Dec-201854.6 KiB2,4261,852

da.poH A D26-Dec-201858 KiB2,4281,854

de.poH A D26-Dec-201859.5 KiB2,4281,854

es.poH A D26-Dec-201859.3 KiB2,4291,855

fi.poH A D26-Dec-201844.1 KiB2,4261,852

fr.poH A D26-Dec-201859.6 KiB2,4301,856

gl.poH A D26-Dec-201859.5 KiB2,4291,855

gperiodic.potH A D26-Dec-201842.9 KiB2,4241,850

id.poH A D26-Dec-201844.7 KiB2,4271,853

is.poH A D26-Dec-201858.7 KiB2,4261,852

it.poH A D26-Dec-201858.2 KiB2,4281,854

lt.poH A D26-Dec-201845.3 KiB2,4271,853

ms.poH A D26-Dec-201858.4 KiB2,4261,852

nl.poH A D26-Dec-201858.6 KiB2,4281,854

oc.poH A D26-Dec-201844.4 KiB2,4251,851

pl.poH A D26-Dec-201859.4 KiB2,4301,856

pt.poH A D26-Dec-201853.7 KiB2,4271,853

pt_BR.poH A D26-Dec-201858.5 KiB2,4271,853

ru.poH A D26-Dec-201867 KiB2,4271,853

sr.poH A D26-Dec-201871.8 KiB2,4271,853

sv.poH A D26-Dec-201857.2 KiB2,4271,853

tr.poH A D26-Dec-201858.8 KiB2,4281,854

uk.poH A D26-Dec-201867.4 KiB2,4261,852

zh_CN.poH A D26-Dec-201858.4 KiB2,4251,851

README

1                  Adding a translation to gperiodic
2                  ---------------------------------
3
41) Extract the strings from the source
5--------------------------------------
6In the gperiodic top level directory, create the .po template (.pot):
7
8	xgettext -k_ -kN_ *.c *.h -o po/gperiodic.pot
9
10
112) Update or create .po files
12-----------------------------
13If there are any existing translations, XX.po files, then merge them:
14
15	cd po
16	msgmerge XX.po gperiodic.pot > XX.po.new
17	mv -f XX.po.new XX.po
18
19Or, if this is a new translation, copy the template:
20
21	cd po
22	cp gperiodic.pot XX.po
23
24
253) Add translations
26-------------------
27Edit XX.po to add translations for new strings, fix broken translations,
28and touch up fuzzy translations.
29
30
314) Make and install gperiodic with i18n enabled
32---------------------------------------------
33If make is run from this directory instead of the top level dir, you must
34explicitely enable i18n in all the below examples by adding enable_nls=1
35to the make command:
36
37	make enable_nls=1
38
39And for the install step:
40
41	make install enable_nls=1
42
43i18n will be automatically enabled when make is run from the top level dir.
44
45
46In either case, a make install will for each XX.po file create a XX.mo file
47and copy it to:
48
49	$LOCALEDIR/XX/LC_MESSAGES/gperiodic.mo
50
51If there is no LOCALEDIR environment variable, then the default install
52will be to:
53
54	/usr/share/locale/XX/LC_MESSAGES/gperiodic.mo
55
56
57
58But, if you want a different explicit install directory, do for example:
59
60	make install LOCALEDIR=/usr/local/share/locale
61
62or (for bash)
63	export LOCALEDIR=/usr/local/share/locale
64	make install
65
66Other export lines:
67	sh:  export LOCALEDIR; LOCALEDIR=/usr/local/share/locale
68	csh: setenv LOCALEDIR /usr/local/share/locale
69
70============================================================================
71Using a translation
72-------------------
73
74A user must have localizations enabled for a translation to be used.
75To enable a localization, the LANGUAGE environment variable should be set
76via the command line or the shell login startup files.
77
78For example, to see the Swedish translation, a user should be able to:
79
80From bash:
81	export LANGUAGE=sv
82or from csh
83	setenv LANGUAGE sv
84