diff options
| author | Ravi R Kiran <aine.marina@gmail.com> | 2020-02-10 12:50:55 (GMT) |
|---|---|---|
| committer | Ravi R Kiran <aine.marina@gmail.com> | 2020-02-10 12:50:55 (GMT) |
| commit | 80d240f0036b0ed4a041f9c65bbe1e23cf344c11 (patch) | |
| tree | a3b31a62ebbf1d779c9301e9430055ca3d04889e /lisp/ravi-init-insertion.el | |
| parent | 41d2d77d5ddc73e6a9b98047d0a262232b876a76 (diff) | |
| download | dotemacs-80d240f0036b0ed4a041f9c65bbe1e23cf344c11.zip dotemacs-80d240f0036b0ed4a041f9c65bbe1e23cf344c11.tar.gz dotemacs-80d240f0036b0ed4a041f9c65bbe1e23cf344c11.tar.bz2 | |
Switch to posframe and pretty-hydra
Diffstat (limited to 'lisp/ravi-init-insertion.el')
| -rw-r--r-- | lisp/ravi-init-insertion.el | 98 |
1 files changed, 53 insertions, 45 deletions
diff --git a/lisp/ravi-init-insertion.el b/lisp/ravi-init-insertion.el index 474e73b..8088273 100644 --- a/lisp/ravi-init-insertion.el +++ b/lisp/ravi-init-insertion.el @@ -127,58 +127,66 @@ ;; To do: enable when moving to emacs 26+ ;; (use-package company-box :hook (company-mode . company-box-mode) :ensure t) - (setq ravi/use-company-box t) - (when ravi/use-company-box - (use-package all-the-icons) - (use-package company-box - :hook (company-mode . company-box-mode) - :config - (setq company-box-icons-unknown (all-the-icons-faicon "question-circle" :height 0.8)) - - (setq company-box-icons-elisp - `(,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8) ;; Function - ,(all-the-icons-faicon "cog" :face font-lock-variable-name-face :height 0.8) ;; Variable - ,(all-the-icons-faicon "cube" :face font-lock-constant-face :height 0.8) ;; Feature - ,(all-the-icons-material "color_lens" :face font-lock-doc-face :height 0.8))) ;; Face - - (setq company-box-icons-yasnippet (all-the-icons-faicon "bookmark" :height 0.8)) - - (setq company-box-icons-lsp - `((1 . ,(all-the-icons-faicon "text-height" :height 0.8)) ;; Text - (2 . ,(all-the-icons-faicon "tags" :face font-lock-function-name-face :height 0.8)) ;; Method - (3 . ,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8)) ;; Function - (4 . ,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8)) ;; Constructor - (5 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Field - (6 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Variable - (7 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Class - (8 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Interface - (9 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Module - (10 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Property - (11 . ,(all-the-icons-material "settings_system_daydream" :height 0.8)) ;; Unit - (12 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Value - (13 . ,(all-the-icons-material "storage" :face font-lock-type-face :height 0.8)) ;; Enum - (14 . ,(all-the-icons-material "closed_caption" :foreground "#009688" :height 0.8)) ;; Keyword - (15 . ,(all-the-icons-material "closed_caption" :height 0.8)) ;; Snippet - (16 . ,(all-the-icons-material "color_lens" :face font-lock-doc-face :height 0.8)) ;; Color - (17 . ,(all-the-icons-faicon "file-text-o" :height 0.8)) ;; File - (18 . ,(all-the-icons-material "refresh" :height 0.8)) ;; Reference - (19 . ,(all-the-icons-faicon "folder-open" :height 0.8)) ;; Folder - (20 . ,(all-the-icons-material "closed_caption" :foreground "#009688" :height 0.8)) ;; EnumMember - (21 . ,(all-the-icons-faicon "square" :face font-lock-constant-face :height 0.8)) ;; Constant - (22 . ,(all-the-icons-faicon "cube" :face font-lock-type-face :height 0.8)) ;; Struct - (23 . ,(all-the-icons-faicon "calendar" :height 0.8)) ;; Event - (24 . ,(all-the-icons-faicon "square-o" :height 0.8)) ;; Operator - (25 . ,(all-the-icons-faicon "arrows" :height 0.8))) ;; TypeParameter - ) - ) + (setq ravi/use-company-box nil) + (if ravi/use-company-box + (progn + (use-package all-the-icons) + (use-package company-box + :hook (company-mode . company-box-mode) + :config + (setq company-box-icons-unknown (all-the-icons-faicon "question-circle" :height 0.8)) + + (setq company-box-icons-elisp + `(,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8) ;; Function + ,(all-the-icons-faicon "cog" :face font-lock-variable-name-face :height 0.8) ;; Variable + ,(all-the-icons-faicon "cube" :face font-lock-constant-face :height 0.8) ;; Feature + ,(all-the-icons-material "color_lens" :face font-lock-doc-face :height 0.8))) ;; Face + + (setq company-box-icons-yasnippet (all-the-icons-faicon "bookmark" :height 0.8)) + + (setq company-box-icons-lsp + `((1 . ,(all-the-icons-faicon "text-height" :height 0.8)) ;; Text + (2 . ,(all-the-icons-faicon "tags" :face font-lock-function-name-face :height 0.8)) ;; Method + (3 . ,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8)) ;; Function + (4 . ,(all-the-icons-faicon "tag" :face font-lock-function-name-face :height 0.8)) ;; Constructor + (5 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Field + (6 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Variable + (7 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Class + (8 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Interface + (9 . ,(all-the-icons-faicon "cube" :foreground "#7C4DFF" :height 0.8)) ;; Module + (10 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Property + (11 . ,(all-the-icons-material "settings_system_daydream" :height 0.8)) ;; Unit + (12 . ,(all-the-icons-faicon "cog" :foreground "#FF9800" :height 0.8)) ;; Value + (13 . ,(all-the-icons-material "storage" :face font-lock-type-face :height 0.8)) ;; Enum + (14 . ,(all-the-icons-material "closed_caption" :foreground "#009688" :height 0.8)) ;; Keyword + (15 . ,(all-the-icons-material "closed_caption" :height 0.8)) ;; Snippet + (16 . ,(all-the-icons-material "color_lens" :face font-lock-doc-face :height 0.8)) ;; Color + (17 . ,(all-the-icons-faicon "file-text-o" :height 0.8)) ;; File + (18 . ,(all-the-icons-material "refresh" :height 0.8)) ;; Reference + (19 . ,(all-the-icons-faicon "folder-open" :height 0.8)) ;; Folder + (20 . ,(all-the-icons-material "closed_caption" :foreground "#009688" :height 0.8)) ;; EnumMember + (21 . ,(all-the-icons-faicon "square" :face font-lock-constant-face :height 0.8)) ;; Constant + (22 . ,(all-the-icons-faicon "cube" :face font-lock-type-face :height 0.8)) ;; Struct + (23 . ,(all-the-icons-faicon "calendar" :height 0.8)) ;; Event + (24 . ,(all-the-icons-faicon "square-o" :height 0.8)) ;; Operator + (25 . ,(all-the-icons-faicon "arrows" :height 0.8))) ;; TypeParameter + ) + )) + (progn + (use-package company-posframe + :config + (company-posframe-mode 1) + :diminish company-posframe-mode)) + ) (unless ravi/use-company-box (use-package company-quickhelp + :disabled t :config (progn (company-quickhelp-mode 1) ;; Enable company-quickhelp only when company-mode is active ;; (unbind-key "M-h" company-quickhelp-mode-map) - (bind-key "M-h" 'company-quickhelp-manual-begin company-active-map))))) + (bind-key "M-h" 'company-quickhelp-manual-begin company-active-map)))) (use-package company-statistics :init |
