all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Mark Oteiza <mvoteiza@udel.edu>
To: emacs-devel@gnu.org
Subject: tabulated-list breakage
Date: Thu, 5 Oct 2017 10:08:06 -0400	[thread overview]
Message-ID: <20171005140806.hf3etzflkjbbt67u@logos.localdomain> (raw)

Hi,

Something in the last several commits, 3d8df4d636..c625fb645a,
has changed calls to tabulated-list-print-entry.  The calling convention
was changed in order to account for display-line-numbers, but the added
optional INDENT is supposed to be a no-op when line numbers aren't in
use, and was correctly null before.  However, now the argument is 0 here
when line numbers are off and it is breaking things.

The following patch demonstrates the issue.

diff --git a/lisp/simple.el b/lisp/simple.el
index 5ef511ce0a..0685863bd6 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -3911,6 +3911,11 @@ process-menu-mode-map
     (define-key map [?d] 'process-menu-delete-process)
     map))
 
+(defun process-menu-print-entry (id cols)
+  (tabulated-list-print-entry id cols)
+  ;; (do other stuff)
+  )
+
 (define-derived-mode process-menu-mode tabulated-list-mode "Process Menu"
   "Major mode for listing the processes called by Emacs."
   (setq tabulated-list-format [("Process" 15 t)
@@ -3921,6 +3926,7 @@ process-menu-mode
 			       ("Command"  0 t)])
   (make-local-variable 'process-menu-query-only)
   (setq tabulated-list-sort-key (cons "Process" nil))
+  (setq tabulated-list-printer #'process-menu-print-entry)
   (add-hook 'tabulated-list-revert-hook 'list-processes--refresh nil t))
 
 (defun process-menu-delete-process ()



             reply	other threads:[~2017-10-05 14:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-05 14:08 Mark Oteiza [this message]
2017-10-05 14:59 ` tabulated-list breakage Eli Zaretskii
2017-10-05 15:14   ` Mark Oteiza

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=20171005140806.hf3etzflkjbbt67u@logos.localdomain \
    --to=mvoteiza@udel.edu \
    --cc=emacs-devel@gnu.org \
    /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.