From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1HyTkx-0005GU-Ox for mharc-grub-devel@gnu.org; Wed, 13 Jun 2007 10:23:31 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HyTkv-0005GB-VJ for grub-devel@gnu.org; Wed, 13 Jun 2007 10:23:29 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HyTkt-0005Fz-Av for grub-devel@gnu.org; Wed, 13 Jun 2007 10:23:28 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HyTkt-0005Fw-6E for grub-devel@gnu.org; Wed, 13 Jun 2007 10:23:27 -0400 Received: from aybabtu.com ([69.60.117.155]) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1HyTks-0004H5-Ng for grub-devel@gnu.org; Wed, 13 Jun 2007 10:23:26 -0400 Received: from [192.168.10.6] (helo=aragorn) by aybabtu.com with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.63) (envelope-from ) id 1HyTkh-0002gY-N9 for grub-devel@gnu.org; Wed, 13 Jun 2007 16:23:16 +0200 Received: from rmh by aragorn with local (Exim 4.63) (envelope-from ) id 1HyTlU-00053f-9X for grub-devel@gnu.org; Wed, 13 Jun 2007 16:24:04 +0200 Date: Wed, 13 Jun 2007 16:24:04 +0200 From: Robert Millan To: The development of GRUB 2 Message-ID: <20070613142404.GA13859@aragorn> References: <466E8A36.7000104@raulete.net> <20070612143444.GD1754@aragorn> <466EAADB.60209@raulete.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <466EAADB.60209@raulete.net> Organization: free as in freedom X-Message-Flag: Microsoft discourages use of Outlook. X-Debbugs-No-Ack: true User-Agent: Mutt/1.5.13 (2006-08-11) X-detected-kernel: Genre and OS details not recognized. Subject: Re: Pager does work from a menu? 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, 13 Jun 2007 14:23:30 -0000 On Tue, Jun 12, 2007 at 04:16:59PM +0200, adrian15 wrote: > > > >Can you ellaborate? From the code you pasted, I just see that when > >"interactive" is set to 0, this has the same effect as pager being set to > >the "0" string. > > That's what I mean. I think that interactive for grub2 means being in > the grub2 shell (not in a menu). If you are in a menu (non interactive) > then there is no stop between pages. Ah, yes. Sounds like it. Not sure if there was a reason for this, maybe the ChangeLog shows something? > But you know I am a bit lazy. I should at last try to do a grub.cfg and > test it on my test floppy and see if I am right or not. Btw, do you know grub-emu? It can probably help you with testing (rather than grabbing to a floppy and reboot). Ah, and there's also qemu (building a floppy image should be much easier now, with grub-mkrescue). > > > > grub_printf ("--MORE--"); > > grub_setcolorstate (GRUB_TERM_COLOR_STANDARD); > > > > key = grub_getkey (); > > > >What do you find wrong in this code? AFAICS, the message is printed and > >then > >we use grub_getkey to block untill a key is pressed. Sounds like normal > >pager-ish behaviour to me.. > > The code is ok. What I do not find ok is that the screen pause happens > in a function which works it is to put a character on the screen. > I do not quite understand why a function that only has to print a > character on the screen has also to deal with the screen by screen stop > problem. > > In my opinion this screen by screen stop problem should be solved in > another part of the source code but so far I do not know where. You can move the code that handles screen stops somewhere else, but it's still the code that prints something that has to trigger it, since screen stops happen precisely when '\n' is printed. What would basicaly change is that instead of getkey() you call something else (e.g. pause()). You can also move it to a lower layer (grub_cur_term->putchar), but then you have to duplicate code (which is bad). -- Robert Millan My spam trap is honeypot@aybabtu.com. Note: this address is only intended for spam harvesters. Writing to it will get you added to my black list.