From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1LEoMs-00072k-RC for mharc-grub-devel@gnu.org; Mon, 22 Dec 2008 12:14:58 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LEoMq-00071l-O2 for grub-devel@gnu.org; Mon, 22 Dec 2008 12:14:57 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LEoMo-000718-Ds for grub-devel@gnu.org; Mon, 22 Dec 2008 12:14:55 -0500 Received: from [199.232.76.173] (port=37407 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LEoMn-000711-Ul for grub-devel@gnu.org; Mon, 22 Dec 2008 12:14:54 -0500 Received: from gateway13.websitewelcome.com ([69.93.179.5]:53545) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1LEoMn-0004EX-J2 for grub-devel@gnu.org; Mon, 22 Dec 2008 12:14:53 -0500 Received: (qmail 15918 invoked from network); 22 Dec 2008 17:28:26 -0000 Received: from gator297.hostgator.com (74.53.228.114) by gateway13.websitewelcome.com with SMTP; 22 Dec 2008 17:28:26 -0000 Received: from c-67-185-177-95.hsd1.wa.comcast.net ([67.185.177.95]:55120 helo=localhost) by gator297.hostgator.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.68) (envelope-from ) id 1LEoMg-0007AE-Vs; Mon, 22 Dec 2008 11:14:47 -0600 Date: Mon, 22 Dec 2008 09:14:43 -0800 From: Colin D Bennett To: The development of GRUB 2 Message-ID: <20081222091443.7280e623@gibibit.com> In-Reply-To: <493ADE06.7080001@nic.fi> 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> X-Mailer: Claws Mail 3.6.1 (GTK+ 2.14.5; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/KE_nfHsN7vTz.vuAb7JoK3q"; protocol="application/pgp-signature"; micalg=PGP-SHA1 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - gator297.hostgator.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - gibibit.com X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Cc: 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: Mon, 22 Dec 2008 17:14:57 -0000 --Sig_/KE_nfHsN7vTz.vuAb7JoK3q Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Sat, 06 Dec 2008 22:18:14 +0200 Vesa J=C3=A4=C3=A4skel=C3=A4inen wrote: > Colin D Bennett wrote: > > Update:=20 > >=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. > >=20 > > 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. >=20 > Hi Colin, >=20 > 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? There are two problems with gfxterm now: 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. 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. > Videotest was fine however. (or how fine it can be with just > unifont.bdf) I should look closely at unifont.bdf and the .pf2 conversion and see why GRUB is rendering it weirdly in gfxterm. > After: > loadfont /boot/grub/unifont.pf2 >=20 > lsfonts gives: > Loaded fonts: > Unknown -1 >=20 > Is this expected? 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). --- 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 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. 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. Regards, Colin --Sig_/KE_nfHsN7vTz.vuAb7JoK3q Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) iEYEARECAAYFAklPywYACgkQokx8fzcGbYd3QwCffydqawphg/w6rAi5Tlpg2rzX eCcAn1+ZqT57cGUA0OmWKtpmwER21jEF =unvS -----END PGP SIGNATURE----- --Sig_/KE_nfHsN7vTz.vuAb7JoK3q--