Users browsing this thread: 1 Guest(s)
(23-08-2021, 07:19 AM)mcol Wrote: A similar area that is largely un-exploited is the framebuffer earlier on during early userspace. This can still be useful on single-user machines, for example if you need to type in a password to decrypt your hard drive. Anyone know of any projects that aim to prettify that sequence?

Because I would love such a tool, too, here's my cents for anyone willing to give a try at doing it :p

Keep in mind that framebuffers have 2 problems:

1) they are not portable. The stuff might be dead simple to use, (I mean it! It's basically doing 3 calls to ioctl and mmap of some memory, then you just write in there) *BSD does not support it. If you want something portable more easily, you need to go on the DRM/KMS route.
2) some drivers do not support them. I only know about NVidia's driver in that case, though.

When you got the framebuffer stuff working, you still need to get user's input, and here I would advise to use libinput: it's pretty clean, and AFAIK portable. Way better than trying to parse /dev stuff yourself.
Of course, it only deals with input, not with input methods (which belongs to my next point).

Last but not least, you'll need to deal with text. And text is some kind of horrible thing to deal with: you got to manage fonts, you likely got to manage UTF-8, you got to manage glyphs which are made from combined codepoints, you got to manage IMEs...

For fonts, I would advise to support the PSF1 and PSF2 formats only, they may be monospace, but it's the format used by the linux kernel itself and for a good reason: it's damn easy to parse those binary formats. Another simple choice is to go the bdf way, which is *not* monospace, but is really opening a (small) can of worm already: it's a text format, which means the files are big, and harder to parse (correctly). It's badly specified, and Xorg adds it's own layer of shit above it. Last choice, which might seem the easier and have the prettiest end-result, is to use fontconfig, but I would not trust this library for anything boot-related: too much failure points, and if you're speaking about luks, then it's a pretty big thing to add to your initrd.

For the other questions... well, UTF-8 is reasonably easy enough to deal with, in appearance (I still know several programs which randomly break when parsing UTF-8). Combined codepoints might not be that much of a problem at first sight, but then I'm using a latin alphabet, writing stuff with it is pretty easy. This might change for Arabic, CJK, Greek, or Cyrillic (and others?) alphabet users. I know of no solution to really work with unicode. And we're in the IME problem already.

Some possibly useful resources:

Messages In This Thread
display managers - by sth - 05-06-2020, 05:30 PM
RE: display managers - by pkal - 05-06-2020, 06:19 PM
RE: display managers - by twee - 06-06-2020, 07:13 AM
RE: display managers - by jkl - 06-06-2020, 07:39 AM
RE: display managers - by wolf - 06-06-2020, 10:36 AM
RE: display managers - by venam - 06-06-2020, 11:01 AM
RE: display managers - by ckester - 06-06-2020, 12:24 PM
RE: display managers - by venam - 12-07-2021, 02:04 AM
RE: display managers - by seninha - 12-07-2021, 11:51 AM
RE: display managers - by twlvscnds - 22-08-2021, 12:20 PM
RE: display managers - by jkl - 23-08-2021, 06:03 AM
RE: display managers - by mcol - 23-08-2021, 07:19 AM
RE: display managers - by freem - 26-08-2021, 08:30 PM
RE: display managers - by VMS - 28-02-2022, 11:42 AM