all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#33363: 26.1; display problem with mode-line turned off on terminal
@ 2018-11-13  3:40 Nick Helm
  2018-11-17 12:44 ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Nick Helm @ 2018-11-13  3:40 UTC (permalink / raw)
  To: 33363

Running Emacs in a terminal and setting mode-line-format to nil can 
cause incorrect display of buffer contents.

emacs -Q -nw
M-: (setq mode-line-format nil)
C-x C-f lisp/org/org.el.gz ;for example
RET RET RET... DEL DEL DEL... ;add and delete white-space

Note the second-to-last row in the window, which formerly held the
mode-line, does not display the buffer contents correctly and any buffer
line that moves through the last row (when back-spacing) appears blank
further up the window.

I mainly observe this in emacs-lisp-mode and org-mode. The problem 
doesn't seem to occur when:

+ in fundamental-mode, c-mode or text-mode, or
+ visual-line-mode is active, or
+ the frame contains more than one window (v or h split), or
+ avoiding display of each line (e.g. C-u 10 RET C-u 10 DEL).


In GNU Emacs 26.1 (build 1, x86_64-apple-darwin14.5.0, NS appkit-1348.17 Version 10.10.5 (Build 14F2511))
 of 2018-05-31 built on builder10-10.porkrind.org
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.

Configured using:
 'configure --with-ns '--enable-locallisppath=/Library/Application
 Support/Emacs/${version}/site-lisp:/Library/Application
 Support/Emacs/site-lisp' --with-modules'

Configured features:
NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS MODULES THREADS

Important settings:
  value of $LANG: en_NZ.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny seq byte-opt gv
bytecomp byte-compile cconv cl-loaddefs cl-lib dired dired-loaddefs
format-spec rfc822 mml easymenu mml-sec password-cache epa derived epg
epg-config gnus-util rmail rmail-loaddefs mm-decode mm-bodies mm-encode
mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047
rfc2045 ietf-drums mm-util mail-prsvr mail-utils term/xterm xterm
time-date elec-pair tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/ns-win ns-win ucs-normalize mule-util
term/common-win tool-bar dnd fontset image regexp-opt fringe
tabulated-list replace newcomment text-mode elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow isearch timer select
scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite charscript charprop case-table epa-hook jka-cmpr-hook
help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote kqueue cocoa ns multi-tty make-network-process emacs)

Memory information:
((conses 16 208462 9630)
 (symbols 48 20166 1)
 (miscs 40 34 154)
 (strings 32 29167 1089)
 (string-bytes 1 765466)
 (vectors 16 32985)
 (vector-slots 8 673123 13352)
 (floats 8 52 452)
 (intervals 56 197 0)
 (buffers 992 12))






^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#33363: 26.1; display problem with mode-line turned off on terminal
  2018-11-13  3:40 bug#33363: 26.1; display problem with mode-line turned off on terminal Nick Helm
@ 2018-11-17 12:44 ` Eli Zaretskii
  2018-11-19 18:16   ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2018-11-17 12:44 UTC (permalink / raw)
  To: Nick Helm; +Cc: 33363

> From: Nick Helm <nick@tenpoint.co.nz>
> Date: Tue, 13 Nov 2018 16:40:23 +1300
> 
> Running Emacs in a terminal and setting mode-line-format to nil can 
> cause incorrect display of buffer contents.

Right.  And it's a very old bug.

> emacs -Q -nw
> M-: (setq mode-line-format nil)
> C-x C-f lisp/org/org.el.gz ;for example
> RET RET RET... DEL DEL DEL... ;add and delete white-space
> 
> Note the second-to-last row in the window, which formerly held the
> mode-line, does not display the buffer contents correctly and any buffer
> line that moves through the last row (when back-spacing) appears blank
> further up the window.

The immediate cause of this is that we miscalculate the number of
lines in the window in this case, and then instruct the terminal to
delete the wrong line.  I'm debating how best to fix this; stay tuned.

> I mainly observe this in emacs-lisp-mode and org-mode. The problem 
> doesn't seem to occur when:
> 
> + in fundamental-mode, c-mode or text-mode, or
> + visual-line-mode is active, or
> + the frame contains more than one window (v or h split), or
> + avoiding display of each line (e.g. C-u 10 RET C-u 10 DEL).

The offending code is a redisplay optimization, and is used only under
very specific conditions.  That's why it doesn't rear its ugly head in
many situations.

Thanks.





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#33363: 26.1; display problem with mode-line turned off on terminal
  2018-11-17 12:44 ` Eli Zaretskii
@ 2018-11-19 18:16   ` Eli Zaretskii
  2018-11-19 22:00     ` Nick Helm
  0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2018-11-19 18:16 UTC (permalink / raw)
  To: nick; +Cc: 33363

> Date: Sat, 17 Nov 2018 14:44:26 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 33363@debbugs.gnu.org
> 
> The immediate cause of this is that we miscalculate the number of
> lines in the window in this case, and then instruct the terminal to
> delete the wrong line.  I'm debating how best to fix this; stay tuned.

Should be fixed now on the emacs-26 branch.





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#33363: 26.1; display problem with mode-line turned off on terminal
  2018-11-19 18:16   ` Eli Zaretskii
@ 2018-11-19 22:00     ` Nick Helm
  2018-11-20  3:31       ` Eli Zaretskii
  0 siblings, 1 reply; 5+ messages in thread
From: Nick Helm @ 2018-11-19 22:00 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 33363

On 20/11/2018, at 7:16 AM, Eli Zaretskii <eliz@gnu.org> wrote:
> 
>> Date: Sat, 17 Nov 2018 14:44:26 +0200
>> From: Eli Zaretskii <eliz@gnu.org>
>> Cc: 33363@debbugs.gnu.org
>> 
>> The immediate cause of this is that we miscalculate the number of
>> lines in the window in this case, and then instruct the terminal to
>> delete the wrong line.  I'm debating how best to fix this; stay tuned.
> 
> Should be fixed now on the emacs-26 branch.

Confirmed, the problem is gone on the emacs-26 branch. 

Many thanks for looking at this Eli.





^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#33363: 26.1; display problem with mode-line turned off on terminal
  2018-11-19 22:00     ` Nick Helm
@ 2018-11-20  3:31       ` Eli Zaretskii
  0 siblings, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2018-11-20  3:31 UTC (permalink / raw)
  To: Nick Helm; +Cc: 33363-done

> From: Nick Helm <nick@tenpoint.co.nz>
> Date: Tue, 20 Nov 2018 11:00:35 +1300
> Cc: 33363@debbugs.gnu.org
> 
> On 20/11/2018, at 7:16 AM, Eli Zaretskii <eliz@gnu.org> wrote:
> > 
> >> Date: Sat, 17 Nov 2018 14:44:26 +0200
> >> From: Eli Zaretskii <eliz@gnu.org>
> >> Cc: 33363@debbugs.gnu.org
> >> 
> >> The immediate cause of this is that we miscalculate the number of
> >> lines in the window in this case, and then instruct the terminal to
> >> delete the wrong line.  I'm debating how best to fix this; stay tuned.
> > 
> > Should be fixed now on the emacs-26 branch.
> 
> Confirmed, the problem is gone on the emacs-26 branch. 
> 
> Many thanks for looking at this Eli.

Thanks for testing, I'm closing the bug.





^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-11-20  3:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-13  3:40 bug#33363: 26.1; display problem with mode-line turned off on terminal Nick Helm
2018-11-17 12:44 ` Eli Zaretskii
2018-11-19 18:16   ` Eli Zaretskii
2018-11-19 22:00     ` Nick Helm
2018-11-20  3:31       ` Eli Zaretskii

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.