From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: Emacs (nowindows) get confused about line display Date: Sat, 21 May 2016 09:42:07 +0300 Message-ID: <83zirj7w00.fsf@gnu.org> References: <573F818A.9040604@gmail.com> <86wpmoux68.fsf@student.uu.se> <573FAF95.2060203@gmail.com> <573FB0FE.6080205@gmail.com> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1463812956 17950 80.91.229.3 (21 May 2016 06:42:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 21 May 2016 06:42:36 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat May 21 08:42:31 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1b40cD-0000LV-KE for geh-help-gnu-emacs@m.gmane.org; Sat, 21 May 2016 08:42:25 +0200 Original-Received: from localhost ([::1]:39089 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b40cC-0001b1-Lo for geh-help-gnu-emacs@m.gmane.org; Sat, 21 May 2016 02:42:24 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55149) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b40bp-0001ai-42 for help-gnu-emacs@gnu.org; Sat, 21 May 2016 02:42:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b40bk-0001Cg-Vg for help-gnu-emacs@gnu.org; Sat, 21 May 2016 02:42:00 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:33170) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b40bk-0001Ca-SR for help-gnu-emacs@gnu.org; Sat, 21 May 2016 02:41:56 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4053 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1b40bk-0001U0-5j for help-gnu-emacs@gnu.org; Sat, 21 May 2016 02:41:56 -0400 In-reply-to: (message from John Mastro on Fri, 20 May 2016 18:19:00 -0700) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:110086 Archived-At: > From: John Mastro > Date: Fri, 20 May 2016 18:19:00 -0700 > Cc: "help-gnu-emacs@gnu.org" > > David M. Karr wrote: > > Actually, narrowing it down didn't take very long, but I'd still like to > > understand this better. > > > > The 2-3rd line of my .emacs file has this: > > -------------------------- > > (set-frame-position (selected-frame) 0 0) > > (set-frame-height (selected-frame) 60) > > ---------------- > > > > This is obviously not relevant in a emacs-nw situation, but I copied this > > from my "home" .emacs file. Why would this cause the symptom that I'm > > seeing? > > > > It's easy enough to wrap this with a "(display-graphic-p)" call, but I'd > > like to understand why this is happening. > > It looks like the problem is with the call to `set-frame-height' > specifically. `set-frame-position' has no effect on a tty frame. > > Further, (set-frame-height (selected-frame) (frame-height)) didn't cause > any problems in my experiments; only when I set a wrong frame height did > I get Emacs into a bad state. So it's not that `set-frame-height' > inherently breaks things on a tty. > > However, I don't know whether there are scenarios where it makes sense > to call `set-frame-height' on a tty frame, or if this is just one of > those "well don't do that" situations. I suggest to upgrade to a later version of Emacs, but in general, my advice is not to use set-frame-height in TTY sessions. That function does produce a non-trivial effect on a TTY, but the effect is only useful for debugging Emacs, not for normal usage.