public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* console font limits
@ 2007-05-01  4:09 Albert Cahalan
  2007-05-01 11:49 ` Geert Uytterhoeven
                   ` (2 more replies)
  0 siblings, 3 replies; 25+ messages in thread
From: Albert Cahalan @ 2007-05-01  4:09 UTC (permalink / raw)
  To: linux-kernel, aeb, hpa

I'm having problems with a font I just created. It's a rather big one,
intended for a framebuffer console in UTF-8 mode. The strace program
reports that /bin/setfont fails on a KDFONTOP ioctl with EINVAL.
In reading the kernel code, I find this:

vt.c:static int con_font_set(struct vc_data *vc, struct console_font_op *op)
vt.c-{
vt.c-   struct console_font font;
vt.c-   int rc = -EINVAL;
vt.c-   int size;
vt.c-
vt.c-   if (vc->vc_mode != KD_TEXT)
vt.c-           return -EINVAL;
vt.c-   if (!op->data)
vt.c-           return -EINVAL;
vt.c-   if (op->charcount > 512)
vt.c-           return -EINVAL;

Ouch. Why is the old VGA limit being applied to the framebuffer console?
Could this just get removed? I dearly hope we aren't still storing the
framebuffer data as two bytes per character+attribute pair.

I nearly hit the 32-pixel height limit as well, yet another relic from
the VGA hardware. I also nearly hit the 64 KB font size limit.

Currently I'm doing a 15x30 font with 870 glyphs to represent 978
different Unicode code points. This is for a 200 DPI display with
an anti-aliasing filter, so fonts need to be big. I'm considering 15x36
so that I'll have more room for double-accented letters, but clearly
the kernel would block that too.

BTW, the PSF font format documentation seems to suggest that
there is a way to make the kernel handle combining accents:
http://www.win.tue.nl/~aeb/linux/kbd/font-formats-1.html
Does anybody know if that really works? I could sure use that.

^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2007-05-06 23:35 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-01  4:09 console font limits Albert Cahalan
2007-05-01 11:49 ` Geert Uytterhoeven
2007-05-01 12:11   ` Antonino A. Daplas
2007-05-01 15:05     ` H. Peter Anvin
2007-05-01 15:49       ` Albert Cahalan
2007-05-02 18:02         ` Jan Engelhardt
2007-05-03  6:17           ` Albert Cahalan
2007-05-03  7:12             ` Jan Engelhardt
2007-05-03 14:14               ` Albert Cahalan
2007-05-03 14:26                 ` Jan Engelhardt
2007-05-03 15:56                   ` Geert Uytterhoeven
2007-05-03 18:27                     ` Jan Engelhardt
2007-05-03 20:15                       ` H. Peter Anvin
2007-05-03 20:16                         ` Jan Engelhardt
2007-05-04  0:17                           ` Kyle Moffett
2007-05-04  0:39                             ` H. Peter Anvin
2007-05-04  3:58                               ` Daniel Hazelton
2007-05-04  4:59                                 ` Antonino A. Daplas
2007-05-04 15:34                                   ` Jesse Barnes
2007-05-06 23:35                                     ` Daniel Hazelton
2007-05-03  7:19         ` H. Peter Anvin
2007-05-03  7:45           ` Helge Hafting
2007-05-03 10:20           ` Alan Cox
2007-05-01 17:06 ` Ken Moffat
2007-05-03 17:11 ` Andries Brouwer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox