On 30/03/2023 11:13, João Távora wrote: >>> You do need to set eldoc-documentation-strategy to >>> eldoc-documentation-compose though (this should really >>> be the default). >> >> Huh, I wonder why I can see both flymake + eglot in the eldoc doc >> buffer when my eldoc-documentation-strategy is the default value? > > Because Eglot changes eldoc-documentation-strategy automatically. It > shouldn't but the default value is really bad. > > The reason the default value is historic. Previously, there was a > single producer of ElDoc, and only in Emacs Lisp. It would decide > whether to show variable _or_ function doc, even if a given symbol had > more than one meaning. So what's the problem with setting > eldoc-documentation-strategy something like e-d-compose, you ask. > > Well, because of the default value of eldoc-echo-area-use-multiline-p, > people would be seeing "bouncing" in the echo area while editing Elisp, > which is something they are not used to. > > I think a very good solution is to set e-d-strategy to e-d-compose > globally and e-e-a-use-multiline-p to 1 in emacs-lisp-mode. > > I once proposed this in this bug tracker, but the message was garbled by > some side discussion, and I gave up. And ElDoc wasn't so powerful then. Last time I tested Eglot's behavior (recently), Eldoc took away half the window to display the overloads of a function's signature. Screenshot attached. That doesn't look like good behavior to me, no matter the language or IDE package used. And then there's bouncing, yes.