unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#72597: 30.0.60; Eglot: MarkedString with embedded Carriage Return
@ 2024-08-13  1:16 Troy Brown
  2024-08-13 11:18 ` Eli Zaretskii
  0 siblings, 1 reply; 19+ messages in thread
From: Troy Brown @ 2024-08-13  1:16 UTC (permalink / raw)
  To: 72597; +Cc: João Távora

With the LSP language server I'm using, it's possible the language
server will return a textDocument/hover response MarkedString
containing "\r" (i.e., carriage return) for the line terminator when
the content contains multiple lines.  An example of a typical response
is as follows:

[jsonrpc] e[19:19:44.606] <-- textDocument/hover[38]
{"jsonrpc":"2.0","id":38,"result":{"contents":[{"language":"gpr","value":"type
Library_Kinds is (\"relocatable\", \"static\",
\"static-pic\");\rLibrary_Kind : Library_Kinds :=
\"static\";"},"gtkada_shared.gpr:37:04"]}}

The font locking is performed correctly (as the highlighting looks
fine), but when the content is placed in the *eldoc* buffer, content
surrounding the carriage return is not placed on separate lines.
Instead it remains on the same line and "^M" is displayed in the
buffer.

This is what I expect:

type Library_Kinds is ("relocatable", "static", "static-pic");
Library_Kind : Library_Kinds := "static";
gtkada_shared.gpr:37:04

This is what I'm observing (single line with embedded ^M):

type Library_Kinds is ("relocatable", "static",
"static-pic");^MLibrary_Kind : Library_Kinds := "static";
gtkada_shared.gpr:37:04





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

end of thread, other threads:[~2024-09-09  0:31 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-13  1:16 bug#72597: 30.0.60; Eglot: MarkedString with embedded Carriage Return Troy Brown
2024-08-13 11:18 ` Eli Zaretskii
2024-08-13 18:32   ` Felician Nemeth
2024-08-13 18:45     ` João Távora
2024-08-13 21:35       ` Troy Brown
2024-08-14  4:37         ` Eli Zaretskii
2024-08-14  5:54           ` Felician Nemeth
2024-08-14  6:37             ` Eli Zaretskii
2024-08-14 11:41               ` Troy Brown
2024-08-31  7:55                 ` Eli Zaretskii
2024-09-01 20:49                   ` Troy Brown
2024-09-02 11:24                     ` Eli Zaretskii
2024-09-02 12:31                       ` João Távora
2024-09-05 21:32                         ` Daniel Pettersson
2024-09-05 21:58                           ` João Távora
2024-09-06  5:44                           ` Eli Zaretskii
2024-09-06 16:00                             ` Daniel Pettersson
2024-09-06 19:31                             ` João Távora
2024-09-09  0:31                               ` Troy Brown

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).