Setting Gramps language to NL while OS language is EN

Ubuntu 22.04 LTS (Pop!_OS to be precise, set to English and it should stay that way)
Gramps 5.2.3
Related: Problem running Gramps in Danish on English OS - #14 by kmikkels

New to Linux so my question may be a bit basic. I want Gramps to always start using Dutch language for the UI, while keeping Linux in English, from the Pop_os! launcher.

What I’ve managed to do so far:

  • I’ve been able to install the Gnome language pack for NL.
  • I can set Gramps to Dutch using LANGUAGE=nl_NL.UTF-8 gramps, however when running Gramps from the Pop!_os launcher it will always be in English.

Gramps doesn’t appear to have a preference/option to set the UI language.

Any tips on how to take the last step? Thanks in advance.

I don’t know your specific OS, or rather its launcher, but I bet that there must be a way to create a new entry in that, or a shortcut on the desktop, that contains the command that you need, like LANGUAGE=nl_NL.UTF-8 gramps

I can do that on Linux Mint, both in the start menu and on the desktop, and the OS is smart enough to understand that, because gramps is in the path.

1 Like

Hello Lemodile,

I had a similar problem with Danish on my English UK Ubuntu 24.04 system. You mention that your system is related to Ubuntu, so you may be able to use my experience.

I have solved my problem for Danish by creating a copy of the standard org.gramps_project.Gramps.desktop (from /usr/share/applications) that is used to start Gramps and putting it in home//.local/share/applications. I then modified this copy, in particular I changed the Exec= line to

Exec=env LANG=da_DK.UTF-8 env LANGUAGE=dk_DK:da env LC_TIME=da_DK.UTF-8 gramps %F

I also changed the name in the Name[da]= and Name[en_GB]= lines to GrampsDK. Finally I changed the filename of the copied and modified file to org.gramps_project.GrampsDK.desktop.

That seems to have done the trick for me. I now have two icons to start Gramps: one called Gramps, which runs Gramps in English, and one called GrampsDK, which runs Gramps in Danish.

I should note that I am not using the flatpak version of Gramps.

HTH

3 Likes

Thanks a lot, this seems very promising. I’ll let you know whether I get it to work.

1 Like

If the short command works in the terminal, it should be enough for shortcuts too, but there is one other thing that you may need, and that’s the Gnome language pack for Dutch.

The reason that you may need that is that Gramps has its own translations for all text that are specific to Gramps or genealogy, but relies on Gnome for standard computer terms.

When you start Gramps in terminal, it will inform you about missing languages, and the text that you see should let you know what it is. Some add-ons may not have translations, and those are not covered by the Gnome language pack.

Thanks, the changes you proposed to the .desktop file worked as intended. I only used nl_NL instead.

2 Likes

Glad you could solve the problem

1 Like