GNU bug report logs - #61373
Eglot patch: add customization to prefer plaintext for :hover

Previous Next

Package: emacs;

Reported by: JD Smith <jdtsmith <at> gmail.com>

Date: Wed, 8 Feb 2023 21:34:01 UTC

Severity: normal

Done: João Távora <joaotavora <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: JD Smith <jdtsmith <at> gmail.com>
To: 61373 <at> debbugs.gnu.org
Subject: bug#61373: Eglot patch: add customization to prefer plaintext for :hover
Date: Wed, 8 Feb 2023 16:33:16 -0500
[Message part 1 (text/plain, inline)]
Some LSP servers badly mangle their responses to :hover into markdown that gfm-viewmode cannot render.  See this discussion <https://github.com/joaotavora/eglot/discussions/1039>, for example. 

The attached patch adds a new custom option `eglot-prefer-plaintext’ which configures the server to use plaintext for :hover responses, even if Emacs could in principle handle markdown.  Unfortunately, the popular Python LSP server in question (pyright) is not interested in improvement to its generated markdown (since it "works in VS-Code”).  Luckily the plaintext docstrings of most packages are very nicely formatted. 



[Message part 2 (text/html, inline)]
[eglot_plaintext.patch (application/octet-stream, attachment)]
[Message part 4 (text/html, inline)]

This bug report was last modified 2 years and 119 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.