summaryrefslogtreecommitdiff
path: root/corfu.el
diff options
context:
space:
mode:
Diffstat (limited to 'corfu.el')
-rw-r--r--corfu.el21
1 files changed, 7 insertions, 14 deletions
diff --git a/corfu.el b/corfu.el
index 5c20ec9..790bddb 100644
--- a/corfu.el
+++ b/corfu.el
@@ -375,6 +375,7 @@ FRAME is the existing frame."
(set-frame-parameter frame 'corfu--hide-timer nil))
(let* ((window-min-height 1)
(window-min-width 1)
+ (inhibit-redisplay t)
(x-gtk-resize-child-frames
(let ((case-fold-search t))
(and
@@ -418,18 +419,8 @@ FRAME is the existing frame."
;; Mark window as dedicated to prevent frame reuse (#60)
(set-window-dedicated-p win t))
(set-frame-size frame width height t)
- (if (frame-visible-p frame)
- ;; XXX HACK Avoid flicker when frame is already visible.
- ;; Redisplay, wait for resize and then move the frame.
- (unless (equal (frame-position frame) (cons x y))
- (redisplay 'force)
- (sleep-for 0.01)
- (set-frame-position frame x y))
- ;; XXX HACK: Force redisplay, otherwise the popup sometimes does not
- ;; display content.
- (set-frame-position frame x y)
- (redisplay 'force)
- (make-frame-visible frame))
+ (set-frame-position frame x y)
+ (make-frame-visible frame)
(redirect-frame-focus frame parent)
frame))
@@ -827,14 +818,16 @@ AUTO is non-nil when initializing auto completion."
(corfu--candidates
(corfu--candidates-popup beg)
(corfu--preview-current beg end)
- (redisplay 'force)) ;; XXX HACK Ensure that popup is redisplayed
+ ;;(redisplay 'force)) ;; XXX HACK Ensure that popup is redisplayed
+ )
;; 3) No candidates & corfu-quit-no-match & initialized => Confirmation popup.
((pcase-exhaustive corfu-quit-no-match
('t nil)
('nil corfu--input)
('separator (seq-contains-p (car corfu--input) corfu-separator)))
(corfu--popup-show beg 0 8 '(#("No match" 0 8 (face italic))))
- (redisplay 'force)) ;; XXX HACK Ensure that popup is redisplayed
+ ;;(redisplay 'force)) ;; XXX HACK Ensure that popup is redisplayed
+ )
;; 4) No candidates & auto completing or initialized => Quit.
((or auto corfu--input) (corfu-quit)))))