Skip to content
zdia edited this page Jan 10, 2012 · 12 revisions

Here you will find some hints if you would like to participate in developing Password Gorilla

Gettext

Create gorilla.pot

A potential new translator needs as base for his translation the catalog template file gorilla.pot which he will edit and save to his locale.po

The template file gorilla.pot is constructed by two templates which are concatenated by msgcat.

The file source.pot is created by typing:

cd <Path-To-Gorilla>/sources
xgettext -kmc -o source.pot -L Tcl gorilla.tcl viewhelp.tcl

For adding or modifying menuitems edit menuitems.pot manually.

Finally concatenate the two files typing:

msgcat -o gorilla.pot menuitems.pot source.pot 

Creating and updating locale catalogue files for Password Gorilla

A new lang.po file will be by principle just a copy of gorilla.pot
Just make a initial call to create a header:

msginit -l <lang> -o <lang>.po -i gorilla.pot

To avoid issues the header should contain charset=UTF-8

The existing message file has to be prepared thus:

msgmerge --update <lang>.po --backup=simple gorilla.pot" 

This will add the new untranslated messages to .po and mark the deprecated
and fuzzy ones.

Subsequently the updated catalogue file can be edited with an specialized editor like Poedit or with any text editor.

They deprecated ones are marked like this:

#~ msgid “Exit”
#~ msgstr “Beenden”

Creating Tcl .msg files

msgfmt --tcl -l<lang> -d <path-to-msgs-dir> <lang>.po
mcset2mcmset.tcl <list of .msg files>

V 1.5.3.6 short description format

Since version 1.5.3.6 a new short description management for msgcat entries has been added. Each msgcat entry will have the following format:

[mc CATEGORY-SubCategory-identifier-?string?-...]

The master file en.po will translate the short description to the final message text. Translators will take it as a base for their translation.

Custom Icons For Win32 Starpacks

See also Tcl/Tk Wiki #10922

To change the program icons inside a Windows *.exe file you have to work inside the Windows environment with Angus Johnson’s utility Resource Hacker (http://www.angusj.com/resourcehacker). Version 3.60 supports also 64bit executables.

  1. create a starpack: tclkit sdx.kit wrap gorilla.exe -runtime .exe
  2. start the Windows program Resource Hacker and open gorilla.exe
  3. Search "Icon groups → Tk → 1033, rightclick the group and choose “Replace Resource …”
  4. click “Open file with new icon …” and choose as source sources/pics/gorilla.ico in Gorilla’s installation directory
  5. edit “Version Info”
  6. save