用xwidget来美化lsp-ui-doc

Can you share taht config?

(setq-default lsp-ui-doc-frame-parameters
                '((left . -1)
                  (top . -1)
                  (no-accept-focus . t)
                  (min-width . 0)
                  (width . 0)
                  (min-height . 0)
                  (height . 0)
                  (internal-border-width . 0)
                  (vertical-scroll-bars)
                  (horizontal-scroll-bars)
                  (left-fringe . 0)
                  (right-fringe . 0)
                  (menu-bar-lines . 0)
                  (tool-bar-lines . 0)
                  (line-spacing . 0.1)
                  (unsplittable . t)
                  (undecorated . t)
                  (minibuffer . nil)
                  (visibility . nil)
                  (mouse-wheel-frame . nil)
                  (no-other-frame . t)
                  (cursor-type)
                  (no-special-glyphs . t)))

I seems have same settings as yours by default. Did you changed the face properties? Mine is black as custom theme, but your lsp-ui-doc popup child-frame use different color contrast with custom theme.

是不是你的cutsom.el里有东西覆盖了你的配置?

I double checked, and search over custom.el. Not found any related to that.

看到你用Emacs编译haskell,忍不住插个楼:

请问你用的是haskell-mode吗?如果是的话,在windows下能否正常启动REPL?(如果可以的话,请问你用的是哪个haskell-mode版本?我发现无论是EPLA上的,还是最新github上make出来的版本好像都不行)

多谢~

有截图吗?xwidget是统一设置成白色不受emacs那边的变量控制的,所以不会出现暗色背景的情况

是haskell-mode + lsp-haskell。我一般是单独开个终端stack run的所以没试过在emacs里开REPL

我已经提交了issue,几天了,也不见回复(Github上好多Open Issue。。。)

我已经滚回IDEA,感觉这公司的产品真是稳定。

I setted (setq lsp-ui-doc-use-webkit t).

Here is my config:

(use-package lsp-ui
  ;; :ensure t
  :quelpa (lsp-ui :fetcher github :repo "Jimx-/lsp-ui")
  :defer t
  :after lsp
  :commands lsp-ui-mode
  :hook (lsp-mode . lsp-ui-mode)
  :bind (:map lsp-ui-mode-map
              ([remap xref-find-definitions] . lsp-ui-peek-find-definitions) ; [M-.]
              ([remap xref-find-references] . lsp-ui-peek-find-references)   ; [M-?]
              ("C-c C-j" . lsp-ui-imenu))
  :init (setq lsp-ui-doc-enable nil
              lsp-ui-doc-header nil
              lsp-ui-doc-include-signature t
              lsp-ui-doc-position 'at-point)
  ;; for "Jimx-/lsp-ui" fork has xwebkit support.
  (if (featurep 'xwidget)
      (setq lsp-ui-doc-use-webkit t))
  
  ;; (add-to-list 'lsp-ui-doc-frame-parameters )
  )
1 个赞

(featurep 'xwidget-internal)来判断emacs是否支持xwidget。其实单独写(setq lsp-ui-doc-use-webkit t)就够了,因为lsp-ui里面是带有这个判断的

How to debug this? In upper screenshot seems using child-frame instead of xwidget. And I tried again, seems when set *-use-webkit t and *-use-child-frame t will not show popup. Which API function show I run edebug on?

这个功能主分支合并了没有?

已经合并进主分支了

mac 党表示羡慕

mac 用户表示很着急啊

:joy: 教主在GNU/Linux呼唤你

mac最新开发版本的可以编译webkit了

啥最新版?是官方的,还是魔改的emacsport

emacs-plus,可以编译进去 了,亲测可用