From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.33) id 1CFE2I-0007jx-LG for mharc-grub-devel@gnu.org; Wed, 06 Oct 2004 11:49:02 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CFE2H-0007jm-ER for grub-devel@gnu.org; Wed, 06 Oct 2004 11:49:01 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CFE2G-0007jS-Rx for grub-devel@gnu.org; Wed, 06 Oct 2004 11:49:01 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CFE2G-0007jI-Od for grub-devel@gnu.org; Wed, 06 Oct 2004 11:49:00 -0400 Received: from [145.74.66.11] (helo=mail-cn.han.nl) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CFDvN-0008SP-7F for grub-devel@gnu.org; Wed, 06 Oct 2004 11:41:53 -0400 Received: from localhost (charlie.han.nl [145.74.66.9]) by mail-cn.han.nl (Postfix) with ESMTP id 8387587C7 for ; Wed, 6 Oct 2004 17:41:52 +0200 (CEST) Received: from mail-cn.han.nl ([145.74.66.11]) by localhost (charlie.han.nl [145.74.66.9]) (amavisd-new, port 10024) with ESMTP id 06768-03 for ; Wed, 6 Oct 2004 17:41:50 +0200 (CEST) Received: from mail1.han.nl (mail1.han.nl [145.74.103.11]) by mail-cn.han.nl (Postfix) with ESMTP id 46CCC86CE for ; Wed, 6 Oct 2004 17:41:48 +0200 (CEST) Received: from marco.marco-g.com (mgerards.xs4all.nl [82.92.27.129]) by mail1.han.nl (Postfix) with ESMTP id AA3BCC081 for ; Wed, 6 Oct 2004 17:41:34 +0200 (CEST) Mail-Copies-To: metgerards@student.han.nl To: The development of GRUB 2 References: <200410060329.44046.tim.lists@majoroak.f2s.com> <200410061055.38925.okuji@enbug.org> <200410061618.45255.tim.lists@majoroak.f2s.com> From: Marco Gerards Date: Wed, 06 Oct 2004 15:41:48 +0000 In-Reply-To: <200410061618.45255.tim.lists@majoroak.f2s.com> (Timothy Baldwin's message of "Wed, 6 Oct 2004 16:18:39 +0100") Message-ID: <87brff97lv.fsf@marco.marco-g.com> User-Agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by amavisd-new@vscan-cn.han.nl Subject: Re: [patch] Widening terminal coordinates, and reading terminal size. 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: Wed, 06 Oct 2004 15:49:01 -0000 Timothy Baldwin writes: >> I agree with your idea, but the name `getsizexy' is not very good, since >> the return values are not coordinates. getsize or getgeometry might be >> better. What do you think? > > grub_getsize is ambiguous (size of what?) and grub_getgeometry suggests a > function to get the geometry of a GUI window, grub_get_term_size is better. > What do you think? How about getdimensions? That is the term that is used in the Hurd. > Would it be better for grub_getxy and grub_getsizexy (or whatever it is > called) to handle the case of null pointers, rather than the terminal > drivers? The case of null pointers? I think when you have a nullpointer this is a bug, no? > (grub_getxy): Returns via pointers to unsigned, instead of packed > into a 16-bit value, all callers updated. > (struct grub_term): Added a new member `grub_getsizexy', arguments > to `grub_gotoxy' changed to unsigned, `grub_getxy' returns values > via pointers to unsigned as above. As above is very confusing. In that case I would do: (grub_getxy): Returns via pointers to unsigned, instead of packed into a 16-bit value, all callers updated. (grub_getxy): Likewise. (struct grub_term): Likewise for `grub_getxy'. Added a new member `grub_getsizexy', arguments to `grub_gotoxy' changed to unsigned, `grub_getxy'. So you can better reorder things or duplicate the text IMHO. -- Marco