Any way, I think that it may not be necessary to setq-local in your functions because I plan to set it to t in completions by default... it makes sense at least for completions to stay highlighted if the user changes window. Right? On March 20, 2022 7:42:44 PM GMT+01:00, Juri Linkov wrote: >> Actually thinking a bit more on this... You can do the same just doing a >> setq-local in the same command instead of a let or a window parameter... > >Thanks, good idea, I confirm this works nice: > >``` >(defun minibuffer-next-completion (&optional n) > "Run `next-completion' from the minibuffer in its completions window." > (interactive "p") > (with-minibuffer-completions-window > (setq-local cursor-face-highlight-nonselected-window t) > (next-completion n))) >``` > -- Sent from my Android device with K-9 Mail. Please excuse my brevity.