lumina-desktop / lumina

Lumina Desktop Environment
http://lumina-desktop.org
BSD 3-Clause "New" or "Revised" License
531 stars 116 forks source link

Available languages under Lumina preferences #627

Open dubh-damh opened 5 years ago

dubh-damh commented 5 years ago

Before I start, I'm new here. Please be understanding if the following is a silly question or if I accidentally break some rule. I’ll try my best not to :)

My question is a fairly small one and it relates directly to Lumina but I’ll have to provide some context first. I’ll simplify things as much as I can. I don’t think it relates to an actual bug.

I've been test driving FreeBSD a lot lately to see if I might be able to use it instead of Linux on some of my machines, mainly as a server but also as a desktop. I’m currently motoring around in version 11.2. For now at least, the only desktop I’m interested in running on BSD is Lumina.

My particular needs make the following absolute requirements for console and desktop:

  1. A ga_IE.UTF-8 locale (ga = the Irish language; IE = Ireland).
  2. A keyboard map that provides certain textual characters found in Irish orthography.
  3. Fonts with glyph support for these characters.
  4. Functionality to fully and safely handle files and directories that have names which include these characters.
  5. Functionality to fully and safely handle UTF-8-encoded text files.

Based on testing, point 5 above doesn’t seem to be a problem even in an OOB FreeBSD installation.

Based on more testing, point 4 doesn’t seem to be a problem either, once points 1 to 3 are addressed.

Based on even more testing however, it’s clear that the functionalities of points 1 to 3 aren’t available OOB. Now that’s fine. I wasn’t really expecting them to be. To cut a long story short, I created them for myself by:

  1. Making my own home-brewed ga_IE.UTF-8 locale by copying the existing en_IE.UTF-8 one and translating the English language text strings. I then set this ga_IE.UTF-8 locale as the global default locale on my test machine by adding the following to /etc/login.conf (under default:):

:umask=022:\
:charset=UTF-8:\
:lang=ga_IE.UTF-8:

and running:

cap_mkdb /etc/login.conf

I also added the following to /etc/profile:

LANG=ga_IE.UTF‑8; export LANG
CHARSET=UTF‑8;    export CHARSET
  1. Making a suitable Irish language keyboard map for the vt console, setting vt as the default console and setting the Irish keymap as the default keyboard layout. Basically, I copied the uk.kbd keymap to one named ie.basic.acc.kbd and then modified this, 'overlaying' Irish mappings as appropriate, following the ones used in the Irish keyboard layout of X.Org. I then added the following to INDEX.keymaps in /usr/share/vt/keymaps:

ie.basic.acc.kbd:en:Ireland (accent keys)

and modified the keymap entry in /etc/rc.conf as appropriate.

  1. Taking a Unifont .bdf file, giving it to vtfontcvt to make a vt-compatible .fnt file and then running vidcontrol -f to load it. This was to work around the lack of glyph support in vt’s native fonts for some of the required characters.

With this much done, careful testing indicated that I had all the requisite functionality up and running, as long as I was using vt of course. So before moving on, and wanting to give something back, I submitted the locale and the keymap as patches (228587 and 228588 on bugzilla), both of which are still open at time of writing.

Next, I installed X.Org with:

pkg install xorg

I enabled its Irish keymap by creating a file called keyboard-ie-clo-gaelach.conf in /usr/local/etc/X11/xorg.conf.d and adding the following to it:

Section "Input Class"
Identifier "KeyboardDefaults"
Driver "Keyboard"
MatchIsKeyboard "On"
Option "XkbLayout" "ie"
Option "XkbVariant" "CloGaelach"
EndSection

Testing in xterm (after running startx) indicated that (1) the keymap was enabled and working as intended and (2) X.Org’s own fonts have full requisite glyph support.

So far so good. Now we get to Lumina. I installed this with:

pkg install lumina

Then I tested as follows:

So far and still so good. I just have one problem (that I can see): there’s no mention at all of Irish in the language list under Lumina preferences. Actually, the language is reported as Afrikaans, although I suspect something’s choking and the GUI is just sticking on the first alphabetical entry on the list.

I might very well be missing something basic and obvious. And of course, there might be something wrong with my homebrew. Also, I know there’s other things that need tweaking to make the underlying OS behave more desktop-like. But I’d like to solve this problem before I move on. Should Lumina be able to detect this language setting from the underlying system or is it something that has to be built-in? Can anyone help?

Thanks in advance

q5sys commented 5 years ago

can you link to the patches that include the file you created?

dubh-damh commented 5 years ago

I can sure. This one’s the locale: []https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=228587

And this is the keymap: []https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=228588

NB: for the locale I only submitted the LC_TIME file because this was the only thing I modified. Everything else in:

/usr/share/locale/ga_IE.UTF‑8

was copied unchanged from:

/usr/share/locale/en_IE.UTF‑8