-
Notifications
You must be signed in to change notification settings - Fork 196
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
acm popup menu not align well with cursor on KDE plasma 6 wayland #915
Comments
You can take a look at Line 677 in ac40260
Did you use a centering plugin like olivetti? |
I didn't use `centering plugin like olivetti or writeroom-mode. If I hack (cons (+ x window-left)
(+ y window-top offset-y)) to (cons (+ x window-left 88)
(+ y window-top offset-y)) then the popup menu looks align well... (defun acm-frame-get-popup-position (frame-popup-point &optional line-bias)
(let* ((edges (window-pixel-edges))
(window-left (+ (nth 0 edges)
;; We need adjust left margin for buffer centering module.
(/ (- (window-pixel-width)
(window-body-width nil t))
2)))
(window-top (nth 1 edges))
(pos (posn-x-y (posn-at-point frame-popup-point)))
(x (car pos))
(y (+ (cdr pos) (* (or line-bias 0) (line-pixel-height))))
(offset-y
;; We need move down to skip tab-line and header-line.
(if (version< emacs-version "27.0")
(window-header-line-height)
(+ (window-tab-line-height)
(window-header-line-height)))))
(cons (+ x window-left 88)
(+ y window-top offset-y)))) |
@manateelazycat |
@eval-exec This patch will adjust acm menu position follow option Thanks for feedback |
I am running KDE Plasma 6 on a HiDPI screen with a resolution of 3840x2160. I am using Xwayland to run Emacs, and the completion menu in the lsp-bridge does not align properly with the current cursor position.
lsp-bridge version:
* ac40260 - (HEAD -> master, origin/master, origin/HEAD) Add new option acm-backend-lsp-block-kind-list (18 hours ago) <Andy Stewart>
system:
"x86_64-linux"
host os:
Linux 6.8.6, NixOS, 24.05 (Uakari), 24.05.20240416.5672bc9
DE:
KDE Plasma 6.0.3
WM:
KWin (Wayland)
What environment variables or configurations can affect the position of acm-popup-menu?
What information should I provide to help analyze this issue?
Thank you. 💙
Screencast_20240420_103416.webm
The text was updated successfully, but these errors were encountered: