From: Vojtech Pavlik <vojtech@suse.cz>
To: microcai <microcai@fedoraproject.org>
Cc: Samuel Thibault <samuel.thibault@ens-lyon.org>,
linux-kernel@vger.kernel.org, Alan Cox <alan@lxorguk.ukuu.org.uk>,
linuxconsole-dev@lists.sourceforge.net
Subject: Re: [PATCH] Kernel fbcon UNICODE font support
Date: Sun, 28 Nov 2010 09:15:28 +0100 [thread overview]
Message-ID: <20101128081528.GA20705@suse.cz> (raw)
In-Reply-To: <AANLkTikfS+c93skkUFNLVJNah0DsjAUPE2jFNAQCAnCg@mail.gmail.com>
On Sun, Nov 28, 2010 at 02:50:49PM +0800, microcai wrote:
> 2010/11/27 Samuel Thibault <samuel.thibault@ens-lyon.org>:
> > Hello,
> >
> > Microcai, le Fri 26 Nov 2010 13:53:45 +0800, a écrit :
> >> I know there are most people speaking only English, and never meet
> >> non-ASCII characters on console. But, hey , what about others ?
> >
> > Well, you can't deny that there _is_ some support for non-ASCII. But
> > just at most 512 glyphs and single width, indeed.
> >
> >> The first thing I need to handle is that, currently there is no room
> >> for adding UNICODE font, only 8bit for characters, how can you do?
> >
> > (or 9bit, but no more indeed)
> >
> >> Also , some characters are double-width. So the solution is make an
> >> backing store. 0xFE and 0xFF stands for character value store else
> >> where, and 0xFF means , left-half of the else where character, and 0xFE
> >> means right-half of the else where character.
> >>
> >> This is a basic solution, the best is that making vc->vc_screenbuf
> >> store full UNICODE/attribute value, But changing it may break some
> >> drivers, so , currently I won't try that way.
> >
> > I'd much prefer the full unicode way, however. Trying to hack around
> > with 0xFE/0xFF will just bring hard-to-fix bugs, while it's quite easy
> > to make sure we capture not-up-to-date drivers by changing field names
> > for instance. I'd say we should first do that, and then it'll be
> > easy to move the old vgaposition/glyph translation cruft into the few
> > drivers that need it. Yes, this seems to be the hard way. But that's
> > the short-term hard then mid-term easy way, which is way easier to
> > accept than the short-term easy then mid/long-term tedious way that you
> > propose.
> >
>
> I did more work,and found that , VGA console (non framebuffer) realy
> need 8bit/8bit attrib/char , because that's how text mode VGA cards
> interpreter them. changing to full type will break VGA drivers.
Well, on VGA you could use the 512 glyphs available (9 bit character, 7
bit attribute) and dynamically change the font in the video memory to
always contain the characters that you need on the screen. Chances are
that you won't need all 512 at any single time. The screen isn't that
large in classic VGA mode.
But since VGA is mostly dead these days anyway, it'd be a neat hack, but
probably not worth the effort.
> So, I add an u32 * unichars to con_putcs() parameter list, VGA drivers
> just ignore that parameter , but fbcon can use it instead of unsigned
> short *s as real char value. And allocate an backing store buffer to
> store full UNICODE characters.
> Also , I delete vc_hi_font_mask, VGA hardware that support 512 font
> chars turn to use u32*unichars passed to con_putcs()
>
> Will that acceptable ?
--
Vojtech Pavlik
Director SuSE Labs
next prev parent reply other threads:[~2010-11-28 8:47 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-26 5:53 [PATCH] Kernel fbcon UNICODE font support Microcai
2010-11-27 12:57 ` Samuel Thibault
2010-11-27 16:18 ` microcai
2010-11-27 16:39 ` Samuel Thibault
2010-11-28 6:50 ` microcai
2010-11-28 8:15 ` Vojtech Pavlik [this message]
2010-11-28 8:29 ` Microcai
2010-12-02 13:50 ` James Simmons
2010-12-02 13:59 ` Samuel Thibault
2010-12-02 18:25 ` James Simmons
2010-11-28 8:47 ` Samuel Thibault
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101128081528.GA20705@suse.cz \
--to=vojtech@suse.cz \
--cc=alan@lxorguk.ukuu.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxconsole-dev@lists.sourceforge.net \
--cc=microcai@fedoraproject.org \
--cc=samuel.thibault@ens-lyon.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox