all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#32177: Current line number shifts one column to the left.
@ 2018-07-16 17:36 Keith David Bershatsky
  2018-07-16 18:20 ` Eli Zaretskii
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Keith David Bershatsky @ 2018-07-16 17:36 UTC (permalink / raw
  To: 32177

1.  Launch a newly built GUI version of Emacs master branch (07/16/2018).

2.  WINDOWS XP -- GUI Emacs:  From the *GNU Emacs* welcome screen, type M-: and evaluate the following:

    (progn
      (switch-to-buffer (get-buffer-create "foo"))
      (setq header-line-format "foo")
      (display-line-numbers-mode 1)
      (setq bidi-display-reordering nil)
      (dotimes (i 57)
        (insert "\n"))
      (recenter 1)
      (sit-for 1)
      (insert "@"))

[OR]

2.  OSX 10.6.8 GUI Emacs:  From the *GNU Emacs* welcome screen, type M-: and evaluate the following:

    (progn
      (switch-to-buffer (get-buffer-create "foo"))
      (setq header-line-format "foo")
      (display-line-numbers-mode 1)
      (setq bidi-display-reordering nil)
      (dotimes (i 50)
        (insert "\n"))
      (recenter 1)
      (sit-for 1)
      (insert "@"))

3.  Observe that line number 58 (on Windows XP), or line number 51 (on OSX 10.6.8), shifts one column to the left of where it should be.  Here is a link to a screenshot depicting the bug with both versions of Emacs (Windows / OSX):

https://www.lawlist.com/images/bug_07_16_2018.png

A modification of the current line is necessary to reproduce this bug.  In my case, I notice the bug a few times each day when I place an overlay on the current line.  The bug is rather elusive and requires just the right circumstances to see it happen.  For example, if I _first_ kill the *GNU Emacs* buffer, then the code above in Step #2 is insufficient to reproduce the bug.

On OSX 10.6.8, my build configuration is:

CFLAGS='-O0 -g3' ./configure \
--with-ns \
--enable-checking='yes,glyphs' \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo

On Windows XP, my build configuration is:

CFLAGS='-O0 -g3' ./configure \
--prefix=/c/docume~1/admini~1/desktop/trunk \
--enable-checking='yes,glyphs' \
--enable-check-lisp-object-type \
--without-compress-install \
--without-makeinfo \
--with-gnutls=no \
--with-mailutils \
--without-makeinfo





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 17:36 bug#32177: Current line number shifts one column to the left Keith David Bershatsky
@ 2018-07-16 18:20 ` Eli Zaretskii
  2018-07-16 18:40   ` Eli Zaretskii
  2018-07-16 20:33 ` Keith David Bershatsky
  2018-07-16 22:16 ` Keith David Bershatsky
  2 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2018-07-16 18:20 UTC (permalink / raw
  To: Keith David Bershatsky; +Cc: 32177

> Date: Mon, 16 Jul 2018 10:36:12 -0700
> From: Keith David Bershatsky <esq@lawlist.com>
> 
> 1.  Launch a newly built GUI version of Emacs master branch (07/16/2018).
> 
> 2.  WINDOWS XP -- GUI Emacs:  From the *GNU Emacs* welcome screen, type M-: and evaluate the following:
> 
>     (progn
>       (switch-to-buffer (get-buffer-create "foo"))
>       (setq header-line-format "foo")
>       (display-line-numbers-mode 1)
>       (setq bidi-display-reordering nil)
>       (dotimes (i 57)
>         (insert "\n"))
>       (recenter 1)
>       (sit-for 1)
>       (insert "@"))
> 
> [OR]
> 
> 2.  OSX 10.6.8 GUI Emacs:  From the *GNU Emacs* welcome screen, type M-: and evaluate the following:
> 
>     (progn
>       (switch-to-buffer (get-buffer-create "foo"))
>       (setq header-line-format "foo")
>       (display-line-numbers-mode 1)
>       (setq bidi-display-reordering nil)
>       (dotimes (i 50)
>         (insert "\n"))
>       (recenter 1)
>       (sit-for 1)
>       (insert "@"))
> 
> 3.  Observe that line number 58 (on Windows XP), or line number 51 (on OSX 10.6.8), shifts one column to the left of where it should be.  Here is a link to a screenshot depicting the bug with both versions of Emacs (Windows / OSX):
> 
> https://www.lawlist.com/images/bug_07_16_2018.png

Actually, the screenshot shows that line number 57 is to the right of
where it should have been.

In any case, I cannot reproduce this here, not in "emacs -Q", not on
master and not on the emacs-26 branch.

Why did you need to turn off bidi-display-reordering?  Does the
problem go away when you don't do that?





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 18:20 ` Eli Zaretskii
@ 2018-07-16 18:40   ` Eli Zaretskii
  2018-07-21 10:34     ` Eli Zaretskii
  0 siblings, 1 reply; 7+ messages in thread
From: Eli Zaretskii @ 2018-07-16 18:40 UTC (permalink / raw
  To: esq; +Cc: 32177

> Date: Mon, 16 Jul 2018 21:20:04 +0300
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 32177@debbugs.gnu.org
> 
> In any case, I cannot reproduce this here, not in "emacs -Q", not on
> master and not on the emacs-26 branch.

I succeeded in reproducing this, but only if I enlarge the frame so it
is taller than the default.





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 17:36 bug#32177: Current line number shifts one column to the left Keith David Bershatsky
  2018-07-16 18:20 ` Eli Zaretskii
@ 2018-07-16 20:33 ` Keith David Bershatsky
  2018-07-17  2:30   ` Eli Zaretskii
  2018-07-16 22:16 ` Keith David Bershatsky
  2 siblings, 1 reply; 7+ messages in thread
From: Keith David Bershatsky @ 2018-07-16 20:33 UTC (permalink / raw
  To: Eli Zaretskii; +Cc: 32177

Thank you, Eli, for looking into issue #32177.  I was happy to hear that you were eventually able to reproduce the bug on your end.

I was able to reproduce the issue on my end with bidi-display-reordering set to a non-nil value of t, but it will take some time to come up with an emacs -Q recipe.

Although it is not often very that I need to inspect the undo-tree history file, setting bidi-display-reordering to a nil value of t gives a tremendous enhancement to movements within that buffer.  Without setting bidi-display-reordering to nil, movements with arrow keys up/down and so forth is unbearably s-l-o-w.  Occasionally, I have to inspect the desktop save file and that too has some very long lines where I think setting bidi-display-reordering may help.  Here is a little snippet written by Noam Postavsky that produces a line matching the format of the undo-tree history file.

    (require 'cl-lib)

    (defun make-deep-object (depth)
      (let ((obj 1))
        (while (> (cl-decf depth) 0)
          (setq obj (vector (list obj))))
        obj))

    (setq print-circle t)

    (let ((buf (get-buffer-create "*test*")))
      (with-current-buffer buf
        (insert (prin1-to-string (make-deep-object 4964))))
      (switch-to-buffer buf))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

DATE:  [07-16-2018 11:20:04] <16 Jul 2018 21:20:04 +0300>
FROM:  Eli Zaretskii <eliz@gnu.org>
> 
> * * *
> 
> Why did you need to turn off bidi-display-reordering?  Does the
> problem go away when you don't do that?





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 17:36 bug#32177: Current line number shifts one column to the left Keith David Bershatsky
  2018-07-16 18:20 ` Eli Zaretskii
  2018-07-16 20:33 ` Keith David Bershatsky
@ 2018-07-16 22:16 ` Keith David Bershatsky
  2 siblings, 0 replies; 7+ messages in thread
From: Keith David Bershatsky @ 2018-07-16 22:16 UTC (permalink / raw
  To: Eli Zaretskii; +Cc: 32177

I take back (in part) what I said below.  It turned out that one of the settings in the org-mode buffer I am using is (setq bidi-paragraph-direction 'left-to-right), which _also_ can be used to reproduce issue 32177.  So it looks like we can use either bidi-paragraph-direction or bidi-display-reordering to reproduce issue 32177.

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

DATE:  [07-16-2018 13:33:03] <16 Jul 2018 13:33:03 -0700>
FROM:  Keith David Bershatsky <esq@lawlist.com>
> 
> * * *
> 
> I was able to reproduce the issue on my end with bidi-display-reordering set to a non-nil value of t, but it will take some time to come up with an emacs -Q recipe.
> 
> * *





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 20:33 ` Keith David Bershatsky
@ 2018-07-17  2:30   ` Eli Zaretskii
  0 siblings, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2018-07-17  2:30 UTC (permalink / raw
  To: Keith David Bershatsky; +Cc: 32177

> Date:  Mon, 16 Jul 2018 13:33:03 -0700
> From:  Keith David Bershatsky <esq@lawlist.com>
> Cc:  32177@debbugs.gnu.org
> 
> Although it is not often very that I need to inspect the undo-tree history file, setting bidi-display-reordering to a nil value of t gives a tremendous enhancement to movements within that buffer.  Without setting bidi-display-reordering to nil, movements with arrow keys up/down and so forth is unbearably s-l-o-w.  Occasionally, I have to inspect the desktop save file and that too has some very long lines where I think setting bidi-display-reordering may help.  Here is a little snippet written by Noam Postavsky that produces a line matching the format of the undo-tree history file.

You should know that setting that variable to nil is not supported, so
you are playing with fire, that's all.





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

* bug#32177: Current line number shifts one column to the left.
  2018-07-16 18:40   ` Eli Zaretskii
@ 2018-07-21 10:34     ` Eli Zaretskii
  0 siblings, 0 replies; 7+ messages in thread
From: Eli Zaretskii @ 2018-07-21 10:34 UTC (permalink / raw
  To: esq; +Cc: 32177

> Date: Mon, 16 Jul 2018 21:40:29 +0300
> From: Eli Zaretskii <eliz@gnu.org>
> Cc: 32177@debbugs.gnu.org
> 
> > Date: Mon, 16 Jul 2018 21:20:04 +0300
> > From: Eli Zaretskii <eliz@gnu.org>
> > Cc: 32177@debbugs.gnu.org
> > 
> > In any case, I cannot reproduce this here, not in "emacs -Q", not on
> > master and not on the emacs-26 branch.
> 
> I succeeded in reproducing this, but only if I enlarge the frame so it
> is taller than the default.

And I no longer can reproduce this, so a more reliable recipe is
needed.

Thanks.





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

end of thread, other threads:[~2018-07-21 10:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-16 17:36 bug#32177: Current line number shifts one column to the left Keith David Bershatsky
2018-07-16 18:20 ` Eli Zaretskii
2018-07-16 18:40   ` Eli Zaretskii
2018-07-21 10:34     ` Eli Zaretskii
2018-07-16 20:33 ` Keith David Bershatsky
2018-07-17  2:30   ` Eli Zaretskii
2018-07-16 22:16 ` Keith David Bershatsky

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.