I've discovered a minor problem with the new Visual Line Mode. To
reproduce:
0) emacs -Q
1) Switch to the *scratch* buffer.
2) Select menu item Options/Line Wrapping in this Buffer/Wrap at
Window Edge.
3) Type '-' symbol. Keep typing '-' until the the line is
wrapped. Delete the last symbol (the one which caused
wrapping). The line should now be fully filled with '-'s, and there
should be no wrapping.
4) Hit Enter and repeat 3). There are now 2 fully filled lines one
after another, with no space between them (expected).
5) Select menu item Options/Line Wrapping in this Buffer/Word Wrap
(Visual Line Mode). An empty line between 2 lines has appeared
(unexpected).
I've found the inconsistency while working with horizontally split
Ediff windows, where the probability of wrapping exactly at the line
width is high. Hope the fix is trivial.
I'm ready to provide any additional info,
Andrey Paramonov
In GNU Emacs 23.0.91.1 (i486-pc-linux-gnu, GTK+ Version 2.14.7)
of 2009-03-20 on elegiac, modified by Debian
(emacs-snapshot package, version 1:20090320-1)
Windowing system distributor `The X.Org Foundation', version 11.0.10402000
configured using `configure '--build' 'i486-linux-gnu' '--host' 'i486-linux-gnu' '--prefix=/usr' '--sharedstatedir=/var/lib' '--libexecdir=/usr/lib' '--localstatedir=/var' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--with-pop=yes' '--enable-locallisppath=/etc/emacs-snapshot:/etc/emacs:/usr/local/share/emacs/23.0.91/site-lisp:/usr/local/share/emacs/site-lisp:/usr/share/emacs/23.0.91/site-lisp:/usr/share/emacs/site-lisp' '--with-x=yes' '--with-x-toolkit=gtk' 'build_alias=i486-linux-gnu' 'host_alias=i486-linux-gnu' 'CFLAGS=-DDEBIAN -DSITELOAD_PURESIZE_EXTRA=5000 -g -O2' 'LDFLAGS=-g -Wl,--as-needed' 'CPPFLAGS=''
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: ru_RU.UTF-8
value of $XMODIFIERS: nil
locale-coding-system: utf-8-unix
default-enable-multibyte-characters: t
Major mode: svn-status
Minor modes in effect:
TeX-PDF-mode: t
diff-auto-refine-mode: t
delete-selection-mode: t
show-paren-mode: t
pc-selection-mode: t
pretty-control-l-mode: t
shell-dirtrack-mode: t
tooltip-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
global-auto-composition-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
column-number-mode: t
line-number-mode: t
global-visual-line-mode: t
visual-line-mode: t
transient-mark-mode: t
> 4) Hit Enter and repeat 3). There are now 2 fully filled lines one
> after another, with no space between them (expected).
> 5) Select menu item Options/Line Wrapping in this Buffer/Word Wrap
> (Visual Line Mode). An empty line between 2 lines has appeared
> (unexpected).
This behavior is expected. The word wrap algorithm treats lines that
are too long to wrap using the ordinary line-wrapping rules, and since
overflow-newline-into-fringe is disabled in Visual Line mode, the extra
empty line is used to show the non-overflowed newline character.
After the release, I might look into letting word wrap handle
overflow-newline-into-fringe behavior. I suspect, however, that this
may lead to confusing results in some circumstances.
> After the release, I might look into letting word wrap handle
> overflow-newline-into-fringe behavior. I suspect, however, that this
> may lead to confusing results in some circumstances.
BTW: why is overflow-newline-into-fringe ignored when word-wrap is
non-nil? What kind of confusing results are you thinking of?
Stefan