summaryrefslogtreecommitdiff
path: root/corfu.el
diff options
context:
space:
mode:
authorDaniel Mendler <mail@daniel-mendler.de>2025-01-20 18:30:56 +0100
committerDaniel Mendler <mail@daniel-mendler.de>2025-01-20 18:30:56 +0100
commit40d8000d5f09cd9c31b799095fae4202dae383cd (patch)
tree773bcfd400e4af3f1eab0439d5ff4072d0f06333 /corfu.el
parent9dc2f900ef58fdd75b4804039848da732f56465c (diff)
Take window-tab-line-height into account on Emacs < 31
Diffstat (limited to 'corfu.el')
-rw-r--r--corfu.el3
1 files changed, 2 insertions, 1 deletions
diff --git a/corfu.el b/corfu.el
index 7473c45..5908519 100644
--- a/corfu.el
+++ b/corfu.el
@@ -1065,7 +1065,8 @@ A scroll bar is displayed from LO to LO+BAR."
(border (alist-get 'internal-border-width corfu--frame-parameters))
(x (max 0 (min (+ (car edge) (- (or (car pos) 0) ml (* cw off) border))
(- (frame-pixel-width) width))))
- (yb (+ (cadr edge) (window-tab-line-height) (or (cdr pos) 0) lh))
+ (yb (+ (cadr edge) (or (cdr pos) 0) lh
+ (static-if (< emacs-major-version 30) (window-tab-line-height) 0)))
(y (if (> (+ yb (* corfu-count ch) lh lh) (frame-pixel-height))
(- yb height lh border border)
yb))