kachick / dotfiles

๐Ÿคคโœ‚๐ŸŒณ
MIT License
9 stars 0 forks source link

Make it possible to display non ASCII even on Linux console #667

Open kachick opened 1 month ago

kachick commented 1 month ago

No kmscon as written in https://github.com/kachick/dotfiles/issues/660, the Linux console displays Japanese file names as Tofu.

https://wiki.archlinux.org/title/Fbterm https://salsa.debian.org/debian/fbterm/-/tree/master https://qiita.com/Pseudonym/items/12e447557a5234bb265b https://github.com/ruo91/jfbterm

kachick commented 1 month ago

How about using bdf fonts or converting ttf to bdf and psf?

M+ BITMAP FONTS

https://github.com/coz-m/MPLUS_FONTS/issues/47 https://github.com/coz-m/MPLUS_FONTS/blob/c47fd4ff0a604d1517625a0f3d67e6d64e12d585/obsolete/mplus_bitmap_fonts-2.2.4.tar.gz https://ja.osdn.net/projects/mplus-fonts/releases/p880 https://www.ipsj.or.jp/magazine/9faeag000000zezt-att/IPSJ-MGN601108.pdf https://codeberg.org/50aec97c/mplus_bitmap_fonts https://www.xmisao.com/2013/08/17/mplus-unicode-font.html

Converting

https://github.com/NixOS/nixpkgs/pull/9576 https://www.reddit.com/r/linuxquestions/comments/7st7hz/any_way_to_convert_ttf_files_to_psf_files/ https://github.com/NixOS/nixpkgs/blob/b521675c515be29b61d78194db97563c380a7574/pkgs/data/fonts/gohufont/default.nix#L29 https://qiita.com/chimorium/items/bf94293b38080583b8e6

kachick commented 1 month ago

Viewing https://github.com/emurenMRz/bdf_view for largest size of https://github.com/coz-m/MPLUS_FONTS/blob/c47fd4ff0a604d1517625a0f3d67e6d64e12d585/obsolete/mplus_bitmap_fonts-2.2.4.tar.gz mplus_j12r.bdf, it is much little ๐Ÿค”

image

kachick commented 1 month ago

http://jikasei.me/font/kh-dotfont/ https://devforum.play.date/t/japanese-pixel-fonts-with-kanji-support/1807/5

ใƒ“ใƒƒใƒˆใƒžใƒƒใƒ—้ขจ ใ“ใ‚Œใ‚‰ใฏใ™ในใฆ TrueType ๅฝขๅผ

Not actual Bitmap Font... :cry:

kachick commented 3 weeks ago

:open_mouth:

https://github.com/ners/trilby/blob/7dd41d0704ebf75f8f705da066184f5ed6168441/modules/overlays/termify.nix#L3-L7 https://github.com/ners/trilby/blob/7dd41d0704ebf75f8f705da066184f5ed6168441/modules/profiles/console.nix#L4-L8

kachick commented 3 weeks ago

:eye:

https://wiki.archlinux.jp/index.php/%E3%83%95%E3%82%A9%E3%83%B3%E3%83%88#.E3.83.93.E3.83.83.E3.83.88.E3.83.9E.E3.83.83.E3.83.97

Unifont โ€“ 8ร—16ใ€16ร—16 (Unicode ใฎใ‚ซใƒใƒผ็Ž‡ใŒๆœ€ใ‚‚้ซ˜ใ„ใƒ•ใ‚ฉใƒณใƒˆ) (bdf-unifontAUR)

https://unifoundry.com/unifont/index.html

PSF: A specialized PSF 1 console frame buffer font consisting of 512 glyphs for use with APL, A Programming Language, in console mode (single-user mode on GNU/Linux, etc.), mainly to support GNU APL: Unifont-APL8x16-15.1.05.psf.gz (4 kbytes)

kachick commented 3 weeks ago

https://wiki.osdev.org/PC_Screen_Font

The other advantage is that PSF fonts can store the whole UNICODE character set, although consolefonts have maximum 512 glyphs usually.

Ah... I didn't know, this looks like a PSF restriction...?

So converting cannot resolve this problem. And if I want to completely avoid Tofu, I should remove non English and emojis...

kachick commented 3 weeks ago

https://manpages.ubuntu.com/manpages/trusty/man1/bdf2psf.1.html

They also have to have either 256 or 512 glyphs.