From 079331dc5421a1be7f4f4d1e6abcf345eb8194a2 Mon Sep 17 00:00:00 2001 From: Andrea Ciceri Date: Tue, 12 Dec 2023 01:27:27 +0100 Subject: [PATCH] Fix `vertico-posframe` in CLI --- flake.nix | 6 ++++++ init.el | 12 +++++------- packages/packages.nix | 2 +- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/flake.nix b/flake.nix index 049dbdd..9d843c5 100644 --- a/flake.nix +++ b/flake.nix @@ -33,6 +33,12 @@ url = "github:firmart/notmuch-notify"; flake = false; }; + # TODO: use from MELPA when v0.7.5 reaches it + # https://github.com/tumashu/vertico-posframe/issues/36 + extra-package-vertico-posframe = { + url = "github:tumashu/vertico-posframe"; + flake = false; + }; }; outputs = inputs @ {flake-parts, ...}: diff --git a/init.el b/init.el index e6f8dc3..ba6c69c 100644 --- a/init.el +++ b/init.el @@ -341,16 +341,14 @@ :config (vertico-posframe-mode +1) :custom + (vertico-multiform-commands + '((t + posframe + (vertico-posframe-poshandler . posframe-poshandler-frame-center) + (vertico-posframe-fallback-mode . vertico-buffer-mode)))) (vertico-posframe-min-height 0) (vertico-posframe-min-width 80) (vertico-posframe-parameters '((alpha-background . 80))) - ;; I'm globally enabling vertico-posframe-mode in spite of being advised against it by the README - ;; It seems to work - ;;(vertico-multiform-commands - ;; '((t - ;; posframe - ;; (vertico-posframe-poshandler . posframe-poshandler-frame-center) - ;; (vertico-posframe-fallback-mode . vertico-buffer-mode)))) ) (use-package marginalia diff --git a/packages/packages.nix b/packages/packages.nix index cfae2bb..b848d89 100644 --- a/packages/packages.nix +++ b/packages/packages.nix @@ -7,6 +7,7 @@ with epkgs; let chatgpt = [polymode]; copilot = [editorconfig dash s]; notmuch-notify = [alert notmuch]; + vertico-posframe = [posframe vertico]; }; overrideAttrsPerPackage = { @@ -93,7 +94,6 @@ with epkgs; let consult-org-roam pass password-store-otp - vertico-posframe eldoc-box go-translate notmuch