all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Jim Porter <jporterbugs@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 72721@debbugs.gnu.org, gautier@gautierponsinet.xyz
Subject: bug#72721: 31.0.50; Visual-wrap-prefix-mode breaks Magit log buffers
Date: Sun, 25 Aug 2024 09:26:12 -0700	[thread overview]
Message-ID: <5209fe94-6999-ae56-2b6e-27f8c37c8b1d@gmail.com> (raw)
In-Reply-To: <86r0adkqlp.fsf@gnu.org>

[-- Attachment #1: Type: text/plain, Size: 606 bytes --]

On 8/25/2024 12:29 AM, Eli Zaretskii wrote:
> I made the change to use Fget_char_property and installed the
> changeset on the master branch.  Please note that overlays can be
> window-specific, and the changes I installed are supposed to handle
> that, but I didn't test that too much.  Please test with
> window-specific overlays and see if it works correctly; if not, I'd
> appreciate a test case for looking into the failure.

Thanks for merging. Everything looks correct to me. I've added a few 
more test cases to exercise window-specific overlays and they all work 
the way I'd expect. See attached.

[-- Attachment #2: test-cases.el --]
[-- Type: text/plain, Size: 2647 bytes --]

(progn
  ;; Should look like:
  ;; 12345
  ;; 678     90
  (switch-to-buffer "simple")
  (erase-buffer)
  (insert "12345\n67890")
  (redisplay)
  (put-text-property
   7 10 'display '((min-width (8)))))


(progn
  ;; Should look like:
  ;; 12345
  ;; 67  89  0
  (switch-to-buffer "consecutive")
  (erase-buffer)
  (insert "12345\n67890")
  (redisplay)
  (put-text-property
   7 9 'display '((min-width (4))))
  (put-text-property
   9 11 'display '((min-width (4)))))


(progn
  ;; Should look like:
  ;; 12345
  ;; hi  890
  (switch-to-buffer "nested")
  (erase-buffer)
  (insert "12345\n67890")
  (redisplay)
  (put-text-property
   7 9 'display
   (propertize "hi" 'display '((min-width (4))))))


(progn
  ;; Should look like:
  ;; 12345         |
  ;; 678     90    |X
  (switch-to-buffer "overlay")
  (erase-buffer)
  (insert "12345\n67890")
  (set-window-margins (selected-window) 0 1)
  (redisplay)
  (setq o (make-overlay 8 9))
  (overlay-put o 'before-string
               (propertize "o" 'display '((margin right-margin) "X")))
  (put-text-property
   7 10 'display '((min-width (8)))))


(progn
  ;; Should look like:
  ;; 12345
  ;; 678     90
  (switch-to-buffer "overlay-min-width")
  (erase-buffer)
  (insert "12345\n67890")
  (set-window-margins (selected-window) 0 1)
  (redisplay)
  (setq o (make-overlay 7 10))
  (overlay-put o 'display '((min-width (8)))))


(progn
  ;; Should look like:
  ;; 12345         |
  ;; 678     90    |X
  (switch-to-buffer "overlay-multi")
  (erase-buffer)
  (insert "12345\n67890")
  (set-window-margins (selected-window) 0 1)
  (redisplay)
  (setq o1 (make-overlay 7 10))
  (overlay-put o1 'display '((min-width (8))))
  (setq o2 (make-overlay 8 9))
  (overlay-put o2 'before-string
               (propertize "o" 'display '((margin right-margin) "X"))))


(progn
  ;; Should look like:
  ;; 12345
  ;; 678     90
  ;; ====================
  ;; 12345
  ;; 67890
  (switch-to-buffer "overlay-window")
  (split-window-below)
  (erase-buffer)
  (insert "12345\n67890")
  (redisplay)
  (setq o (make-overlay 7 10))
  (overlay-put o 'display '((min-width (8))))
  (overlay-put o 'window (selected-window)))


(progn
  ;; Should look like:
  ;; 12345
  ;; 678     90
  ;; ====================
  ;; 12345
  ;; 67   890
  (switch-to-buffer "overlay-window-multi")
  (split-window-below)
  (erase-buffer)
  (insert "12345\n67890")
  (redisplay)
  (setq o1 (make-overlay 7 10))
  (overlay-put o1 'display '((min-width (8))))
  (overlay-put o1 'window (selected-window))
  (setq o2 (make-overlay 7 9))
  (overlay-put o2 'display '((min-width (5))))
  (overlay-put o2 'window (car (last (window-list)))))

  reply	other threads:[~2024-08-25 16:26 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-19 21:39 bug#72721: 31.0.50; Visual-wrap-prefix-mode breaks Magit log buffers Gautier Ponsinet
2024-08-20  0:46 ` Jim Porter
2024-08-20 11:53   ` Eli Zaretskii
2024-08-20 17:33     ` Jim Porter
2024-08-20 19:01       ` Eli Zaretskii
2024-08-21  3:15         ` Jim Porter
2024-08-21  5:18           ` Jim Porter
2024-08-21 19:12             ` Jim Porter
2024-08-22 12:54               ` Eli Zaretskii
2024-08-22  9:59             ` Eli Zaretskii
2024-08-22  9:53           ` Eli Zaretskii
2024-08-22 16:19             ` Jim Porter
2024-08-25  7:29               ` Eli Zaretskii
2024-08-25 16:26                 ` Jim Porter [this message]
2024-08-25 17:39                   ` Eli Zaretskii
2024-08-25 18:41                     ` Jim Porter
2024-08-29 11:47                       ` Eli Zaretskii
2024-08-30  5:01                         ` Jim Porter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5209fe94-6999-ae56-2b6e-27f8c37c8b1d@gmail.com \
    --to=jporterbugs@gmail.com \
    --cc=72721@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=gautier@gautierponsinet.xyz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.