From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1LFCA9-0004dk-D0 for mharc-grub-devel@gnu.org; Tue, 23 Dec 2008 13:39:25 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LFCA7-0004db-CZ for grub-devel@gnu.org; Tue, 23 Dec 2008 13:39:23 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LFCA5-0004dJ-Np for grub-devel@gnu.org; Tue, 23 Dec 2008 13:39:21 -0500 Received: from [199.232.76.173] (port=43773 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LFCA5-0004dG-Im for grub-devel@gnu.org; Tue, 23 Dec 2008 13:39:21 -0500 Received: from mta-out.inet.fi ([195.156.147.13]:59838 helo=kirsi2.inet.fi) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LFCA4-0002BE-NT for grub-devel@gnu.org; Tue, 23 Dec 2008 13:39:21 -0500 Received: from [84.249.165.26] (84.249.165.26) by kirsi2.inet.fi (8.5.014) id 48FC5B8902EA84FF for grub-devel@gnu.org; Tue, 23 Dec 2008 20:39:15 +0200 Message-ID: <49513053.20207@nic.fi> Date: Tue, 23 Dec 2008 20:39:15 +0200 From: =?UTF-8?B?VmVzYSBKw6TDpHNrZWzDpGluZW4=?= User-Agent: Thunderbird 2.0.0.18 (Windows/20081105) MIME-Version: 1.0 To: The development of GRUB 2 References: <20080901092753.3918cf73@gamma.lan> <20081004214640.5ab21f53@gibibit.com> <48E87FB9.8070603@nic.fi> <20081030121106.4efffecc@gibibit.com> <20081030205736.7e080a5e@gibibit.com> <493ADE06.7080001@nic.fi> <20081222091443.7280e623@gibibit.com> In-Reply-To: <20081222091443.7280e623@gibibit.com> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: Quoted-Printable X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Subject: Re: [PATCH] GSoC #10 new font engine (UTF-8 support+bugfix) X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Dec 2008 18:39:23 -0000 Colin D Bennett wrote: > On Sat, 06 Dec 2008 22:18:14 +0200 > Vesa J=C3=A4=C3=A4skel=C3=A4inen wrote: >=20 >> Colin D Bennett wrote: >>> Update:=20 >>> >>> I fixed an error pointed out to me by Y.Volta:=20 >>> In grub_font_get(), if no fonts are loaded, a null pointer is >>> dereferenced. This is fixed in the attached patch. >>> >>> The grub_font_get() function now returns a dummy font object (a >>> statically allocated font object with no characters) so that >>> callers of grub_font_get() can be assured that the return value >>> will never be NULL. If no fonts are loaded, then the "unknown >>> glyph" will be used for all characters, but it will be safe. >> Hi Colin, >> >> I applied this patch against SVN today and tried it out. And noticed >> that gfxterm gets a bit "broken" after this. Was this the thing that I >> promised to look at :) ? Or was my merge just incomplete? >=20 > There are two problems with gfxterm now: >=20 > 1. unifont has problems rendering glyphs: they seem to be rendered > too wide (maybe), and the cursor ends up being drawn after each > character resulting in t_e_x_t_ _t_h_a_t_ _l_o_o_k_s like this. >=20 > 2. With fonts that otherwise work (i.e. "Fixed 10" for me), sometimes > a few random junk characters with weird background/foreground > colors show up in gfxterm -- mainly when it is first set as the > terminal, leading me to think that there is some uninitialized > memory. I think I have workable solution for these now in my local copy. >> Videotest was fine however. (or how fine it can be with just >> unifont.bdf) >=20 > I should look closely at unifont.bdf and the .pf2 conversion and see > why GRUB is rendering it weirdly in gfxterm. Actually what we want is to have improved conversion tool. If I make full conversion it generates ~1.7 MiB font file which does not fit to floppy. Now if we could specify unicode ranges what to put there it would make them smaller. This would be similar to how you specify ranges to old pff converter. I was planning to make such modification to handle near term goal. Actually it would be nice if converter tool would be in C. Then it could be compiled and executed easily during normal compilation process. Viewer application is not so important and it can be external to project . Same time with C implementation it would be easy to add compression there too. >> After: >> loadfont /boot/grub/unifont.pf2 >> >> lsfonts gives: >> Loaded fonts: >> Unknown -1 >> >> Is this expected? >=20 > Yes, since there is no 'POINT_SIZE' or 'FAMILY_NAME' attribute in the > unifont.bdf file. I added these manually, and it then showed up > properly in the lsfonts listing (and can then be specified using the > name/size in GRUB). Perhaps this addition should be moved to GNU Unifont's upstream? > --- gnu-unifont-2008-04-06.bdf 2008-12-22 08:48:00.000000000 > -0800 +++ gnu-unifont-2008-04-06_tagged.bdf 2008-12-22 > 09:10:22.000000000 -0800 @@ -1,5 +1,8 @@ > STARTFONT 2.1 > FONT -gnu-unifont-medium-r-normal--16-160-75-75-c-80-iso10646-1 > +FAMILY_NAME "unifont" > +WEIGHT_NAME "medium" > +POINT_SIZE 100 > SIZE 16 75 75 > FONTBOUNDINGBOX 16 16 0 -2 > STARTPROPERTIES 3 >=20 > The font converter should probably fall back on the file's name and the > font's pixel size if such specifications are missing in the BDF file. >=20 >=20 > Sorry for the delay getting back to you; now that the font patches are > going in, I will be ready to continue work on submitting the graphical > menu system patches. I've received e-mails from a number of people who > have found my project web site and want to try out the graphical menu, > and are asking when it will be merged into GRUB. I'll try to get them in. But I have to make it in way to normal grub operation do not break at same time. Temporary this means probably that toolchain is there in Java form unless you can make quickly the new converter. It can start without compression. What we want is to match functionality of old font converter. Eg. specify ranges and then generate file based on that one. Thanks, Vesa J=C3=A4=C3=A4skel=C3=A4inen