Problem running Gramps in Danish on English OS - Flatpak

This is my first post here, but I am a long-time user of Gramps, mainly on Windows. However, I am now trying to leave Windows behind and migrating to Ubuntu as best I can.

I have always operated my OSes in UK English, but I have a need to run Gramps in Danish too. In Windows I could do this with a shortcut containing

%comspec% /c set LANG=da_DK.UTF-8 && start grampsw.exe

and in Ubuntu 24.04 I have tried with

/usr/bin/flatpak run --branch=stable --arch=x86_64 --env=LANGUAGE="da_DK:da" --command=gramps --file-forwarding org.gramps_project.Gramps @@ %F @@

This partly works, but there are two problems. The first one is that as soon as Gramps starts it displays a message (in Danish) along the lines

(my translation):
“Gramps found an incomplete GTK installation. GTK translation for the active language (da) is not found. Gramps continues anyway. The GUI will most probably fail, especially for RTL language!”

When I close the message Gramps continues, and I see everything in Danish: the menu at the top, the bar at the left, the standard filters at the right, most of the headings of the add-ins in the bottom bar and the status bar. So far so good, but the warning message worries me.

The second problem is that the sorting order is not Danish. The special letters ĂŠ, Ăž and Ă„ belong at the end of the ASCII alphabet but are sorted amongst the a’s and o’s. Also, the spell checking appears to be English instead of Danish, but the latter for me is less of a problem than the sorting order. This problem may well be related to the GTK problem above, but I don’t know sufficient about these things; I am indeed an inexperienced Ubuntu user.

This is what I have done/tried so far:

  • I have installed the Danish language support in Ubuntu with the Settings application, and I have run Ubuntu in Danish and tested the sorting order in the Files (Nautilus) application. This all appeared OK.

  • When I run Gramps from the standard link installed by flatpak in the Danish version of Ubuntu the menu is in a mixture of English and Danish. The left and right panels as well as the titles in the bottom bar are in Danish, but sorting order and spell checker is still English. There is no GTK warning.

  • When I start Gramps in the Danish version of Ubuntu using the modified flatpak command with LANGUAGE="da_DK:da" I get the same result as above except now the GTK warning appears.

  • Back in the UK English version of Ubuntu I have tried using LANGUAGE=da_DK.UTF-8 in the flatpak command, which made no difference.

  • I have tried using LANG= in place of LANGUAGE= in the flatpak command, which made Gramps run in English.

GRAMPS: 5.2.3
Python: 3.11.9
BSDDB: not found
sqlite: 3.42.0 (2.6.0)
LANG: da_DK.UTF-8
OS: Linux
Distribution: 6.8.0-45-generic

OS Name: Ubuntu 24.04.1 LTS
Firmware Version: 1.5.0
OS Type: 64-bit
GNOME Version: 46
Windowing System: Wayland
Kernel Version: Linux 6.8.0-45-generic

Languages installed are English for United Kingdom, Australia, Canada and United States, as well as Danish.

Thanks in advance for any and all help to get Gramps running also in Danish.

1 Like

This is a bit of a guess, but it looks like it, that if you run Gramps in a flatpak, you also need the flatpak version of the Danish language pack.

And since you’re on Ubuntu, you can just as well install the Debian package from here:

https://www.gramps-project.org/wiki/index.php/Download

The version for 22.04 also works on 24.04.

2 Likes

So Now I got the reply button. Thanks!

You need to install the gnome language packs for danish:
language-pack-gnome-da
language-pack-gnome-da-base

The sorting issues I have noticed for some time, but since it wasn’t important for med, I haven’t done anything.
Now I have created a mantis ticket for this, hopefully it will get resolved some time, but remember we are relying on people who have this as their hobby, so be patient - and nice to them.

The spell checker - make sure that you have installed the aspell and aspell-da, that fixed it for me.
Since I run gramps 5.1.5 on linux mint 21.3 - we may see things differently:
If so let me know, and I wwill set up a test environment similar to yours.

1 Like

I believe a new spell checking package is used for Gramps 5.2 version.

And a bug was patched (PR 1718 on 6 July 2024) where the spellcheck styling (the red underline styling for mis-spelled words) had a conflict with the Note styler (bold, italic, superscript, subscript, colors)

Not sure on the spell package.
Just made a virtualbox installation of mint 21.1 and gramps 5.2.3
Started gramps with my script, which is setting language to danish.
Spell checker didn’t work, installed aspell-da, and everything worked.
Had to install language-pack-gnome-da, to fix the broken GTK issue

1 Like

This is wonderful.

Could you start another thread in dansk which has this information about:

  • creating a virtualbox in Linux Mint,
  • installing a Gramps version (does it need an install option to include the dansk GUI?),
  • your language-choosing startup script, and
  • adding files to support a dansk spellcheck

Note that you can refine (correct errors or add stylings) your postings with the Edit feature.

I can see that thread become a foundation for the other language sections
 and a good reference webpage for your Facebook group’s new members.

Another good thread might be about how to add (temporary) dansk translations to an English-only add-on. Or hacking a bad translation to make more accurate.

Thank you very much to ennoborg, kmikkels and emyoulation. Your contributions have more or less solved my problems. I can now run Gramps from a terminal window with proper sorting order and spell checking in Danish.

I first checked the language packs and spell packs that kmikkels suggested by trying to install them one after another. The only one that was missing was aspell-da. However, this did not change anything.

I then went on to install the .deb version of Gramps for Ubuntu 22.04 as suggested by ennoborg. This gave me what appears to be a completely new installation of Gramps (did not retain settings from flatpak version). Playing in the terminal with settings of LANGUAGE= and LANG= I eventually found that LANG=da_DK.UTF-8 LANGUAGE=dk_DK:da resolved the sorting order, menus and labels in Danish.

Encouraged by this result, I went on to investigate the gspell suggestion by emyoulation. I noticed that in the .deb version the spell checking option was greyed out in both English and Danish version, suggesting that a spell checker was completely missing. After some searching for how to make gspell available I found that I could install libgspell-1-dev. After having done so, I have now also spell checking available in Danish.

So basically my problems are now solved. What now remains for me to do is to copy the Gramps configuration from the flatpak version to the .deb version and create a .desktop file to launch Gramps in Danish, but these are not really Gramps problems.

Thanks again for your help and guidance - much appreciated.

PS: I am sorry I didn’t see the last two replies (from kmikkels and emyoulation), They arrived while I was composing my own reply.

2 Likes

Done - please let me know if you want it to be more elaborate

1 Like

Glad it is working.
Apparently there are differences between the spell checkers in ubuntu and mint.
I would never had guessed that

1 Like

Interesting that sorting is working for you, it doesn’t work for me.
Again probaly differences between ubuntu and mint

I was hoping for a dansk language version for this section. (But I love having an english-version as a reference document for other languages.)

OK, I can make it in Danish.
I am just used to using english for computing :smile:

Me too! :wink:

My thought is that people having technical problems are already frustrated. If they don’t read English well, they will be extra frustrated.

1 Like

OK, a new translated topic.
Again very brief, but hopefully enough to get things going

1 Like

I can understand that you didn’t expect that, but Mint has its own policies, and that’s why I like it so much. And one of those is that Mint 22 still includes flatpak, where Ubuntu 24.04 tries to promote their own thing called snap.