From xemacs-m  Sat May 31 20:30:39 1997
Received: from jagor.srce.hr (hniksic@jagor.srce.hr [161.53.2.130])
	by xemacs.org (8.8.5/8.8.5) with ESMTP id UAA17293
	for <xemacs-beta@xemacs.org>; Sat, 31 May 1997 20:30:30 -0500 (CDT)
Received: (from hniksic@localhost)
          by jagor.srce.hr (8.8.5/8.8.4)
	  id DAA03786; Sun, 1 Jun 1997 03:30:15 +0200 (MET DST)
To: XEmacs Developers <xemacs-beta@xemacs.org>
Subject: Re: [PATCH] 20.3-b3: new tty frame selected too soon
References: <QQcrzc00937.199706010008@crystal.WonderWorks.COM> 	<kigraenp3xg.fsf@jagor.srce.hr> <QQcrzh01829.199706010116@crystal.WonderWorks.COM>
X-Attribution: Hrv
X-Face: Mie8:rOV<\c/~z{s.X4A{!?vY7{drJ([U]0O=W/<W*SMo/Mv:58:*_y~ki>xDi&N7XG
        KV^$k0m3Oe/)'e%3=$PCR&3ITUXH,cK>]bci&<qQ>Ff%x_>1`T(+M2Gg/fgndU%k*ft
        [(7._6e0n-V%|%'[c|q:;}td$#INd+;?!-V=c8Pqf}3J
X-Antipastobozoticataclysm: Bariumenemanilow
From: Hrvoje Niksic <hniksic@srce.hr>
Date: 01 Jun 1997 03:30:15 +0200
In-Reply-To: Kyle Jones's message of Sat, 31 May 1997 21:16:22 -0400 (EDT)
Message-ID: <kiglo4vp0t4.fsf@jagor.srce.hr>
Lines: 30
X-Mailer: Gnus v5.4.52/XEmacs 20.2

Kyle Jones <kyle_jones@wonderworks.com> writes:

> The patch that I sent definitely isn't the final solution.  But it
> is part of it.  The missing part might involve selection of the
> visible tty frame happening in Fnext_frame.

`Fnext_frame' is a screaming nightmare.

In fact, the nightmare is not in `Fnext_frame', as much as it is in
the functions that use it.

For example, in many places in Lisp (e.g. at `other-frame') next-frame 
is called and asked for the next visible frame.  Since only 1 TTY
frame is visible, `C-x 5 o' did nothing.  So I had to add a
kludgissimo to the situation by making `(next-frame 'visible)' return
TTY frames, even if they are not visible.

This should be cleaned up by using a concept of "selectable" frames,
which `other-frame' would ask for.  A frame is selectable if it is a
visible X frame, or if it is a TTY frame.  Minibuffer-only frames
wouldn't be selectable, etc.  We could even devise options for user to
choose whether 'hidden or iconified frames are selectable.

It's not hard to implement.

-- 
Hrvoje Niksic <hniksic@srce.hr> | Student at FER Zagreb, Croatia
--------------------------------+--------------------------------
You'll notice that perl is not itself written in Perl.
                                                 -- The Perl FAQ

