diff options
| author | Daniel Mendler <mail@daniel-mendler.de> | 2021-04-28 18:49:57 +0200 |
|---|---|---|
| committer | Daniel Mendler <mail@daniel-mendler.de> | 2021-04-28 18:49:57 +0200 |
| commit | e5dad6682f5a0e8f4e7ce80a1b39745a01f62b92 (patch) | |
| tree | c0d3d5845217b9d787f66914e2719aca9fd0625f | |
| parent | 9eb9ae67fddb8b12da49b5b5fbd1d5d1aabb0ada (diff) | |
Use internal border
| -rw-r--r-- | corfu.el | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -227,7 +227,7 @@ Set to nil in order to disable confirmation." (height . 0) (line-spacing . 0) (border-width . 0) - (internal-border-width . 0) + (internal-border-width . 1) (left-fringe . 0) (right-fringe . 0) (vertical-scroll-bars . nil) @@ -242,7 +242,9 @@ Set to nil in order to disable confirmation." (minibuffer . nil) (visibility . nil) (no-special-glyphs . t)))) - (set-window-buffer (frame-root-window corfu--frame) buffer)) + (set-window-buffer (frame-root-window corfu--frame) buffer) + (set-face-background 'internal-border (face-attribute 'corfu-border :foreground) corfu--frame) + (redisplay)) ;; force face loading? (set-frame-position corfu--frame x y) (set-frame-size corfu--frame width height t) (make-frame-visible corfu--frame))) @@ -251,11 +253,11 @@ Set to nil in order to disable confirmation." "Show LINES as popup at POS, with CURR highlighted and scrollbar from LO to LO+BAR." (let* ((cw (frame-char-width)) (ch (frame-char-height)) - (bw (* 3 (ceiling cw 5))) - (lborder (corfu--border bw ch 1 'corfu-border 'corfu-background)) - (lborder-curr (corfu--border bw ch 1 'corfu-border 'corfu-current)) - (rborder (corfu--border bw ch -1 'corfu-border 'corfu-background)) - (rborder-curr (corfu--border bw ch -1 'corfu-border 'corfu-current)) + (bw (ceiling cw 1.6)) + (lborder (corfu--border bw ch 0 'corfu-border 'corfu-background)) + (lborder-curr (corfu--border bw ch 0 'corfu-border 'corfu-current)) + (rborder (corfu--border bw ch 0 'corfu-border 'corfu-background)) + (rborder-curr (corfu--border bw ch 0 'corfu-border 'corfu-current)) (rbar-curr (corfu--border bw ch (- (ceiling cw 4)) 'corfu-bar 'corfu-current)) (rbar (corfu--border bw ch (- (ceiling cw 4)) |
