Add explicit support for the built-in completion-preview-mode faces

We want to do this because completion-preview-exact hardcodes a colour
value, which does not work for our purposes.

Thanks to Kevin Fleming for asking me about this in issue 178:
<https://github.com/protesilaos/modus-themes/issues/178>.
This commit is contained in:
Protesilaos Stavrou 2025-11-18 12:38:20 +02:00
parent f79684961e
commit 3ddb82b37b
No known key found for this signature in database
GPG key ID: 99BD6459CD5CA3EA
3 changed files with 47 additions and 41 deletions

View file

@ -4882,6 +4882,7 @@ have lots of extensions, so the "full support" may not be 100% true…
• column-enforce-mode
• company-mode*
• compilation-mode
• completion-preview [ Part of 5.2.0-dev. ]
• completions
• consult
• corfu
@ -7264,47 +7265,47 @@ Node: Determine what counts as a Modus theme205936
Node: Create convenience commands to load a derivative theme209346
Node: Face coverage211563
Node: Supported packages212025
Node: Indirectly covered packages217841
Node: Notes on individual packages219197
Node: Note on calendarel weekday and weekend colors220299
Node: Note on git-gutter in Doom Emacs221449
Node: Note on php-mode multiline comments223951
Node: Note on underlines in compilation buffers224713
Node: Note on inline Latex in Org buffers225587
Node: Note on dimmerel226199
Node: Note on display-fill-column-indicator-mode227686
Node: Note on highlight-parenthesesel229139
Node: Note on mmm-modeel background colors235218
Node: Note for prism237572
Node: Note on company-mode overlay pop-up240786
Ref: Note on company-mode overlay pop-up-Footnote-1241516
Ref: Note on company-mode overlay pop-up-Footnote-2241583
Node: Note on ERC escaped color sequences241638
Ref: Note on ERC escaped color sequences-Footnote-1243068
Node: Note on powerline or spaceline243178
Node: Note on SHR colors243594
Node: Note on SHR fonts244016
Node: Note on Ement colors and fonts244705
Node: Note on pdf-tools link hints246211
Node: Note on the Notmuch logo248669
Node: Note on goto-address-mode faces249203
Node: Frequently Asked Questions250323
Node: Is the contrast ratio about adjacent colors?250954
Node: What does it mean to avoid exaggerations?252463
Node: Why are colors mostly variants of blue magenta cyan?254313
Node: What is the best setup for legibility?258647
Node: Are these color schemes?261289
Node: Port the Modus themes to other platforms?264943
Node: Contributing267777
Node: Sources of the themes268176
Node: Issues you can help with269072
Node: Patches require copyright assignment to the FSF270464
Node: Acknowledgements272686
Node: GNU Free Documentation License277296
Node: Indices302459
Node: Function index302638
Node: Variable index306833
Node: Concept index311196
Node: Indirectly covered packages217891
Node: Notes on individual packages219247
Node: Note on calendarel weekday and weekend colors220349
Node: Note on git-gutter in Doom Emacs221499
Node: Note on php-mode multiline comments224001
Node: Note on underlines in compilation buffers224763
Node: Note on inline Latex in Org buffers225637
Node: Note on dimmerel226249
Node: Note on display-fill-column-indicator-mode227736
Node: Note on highlight-parenthesesel229189
Node: Note on mmm-modeel background colors235268
Node: Note for prism237622
Node: Note on company-mode overlay pop-up240836
Ref: Note on company-mode overlay pop-up-Footnote-1241566
Ref: Note on company-mode overlay pop-up-Footnote-2241633
Node: Note on ERC escaped color sequences241688
Ref: Note on ERC escaped color sequences-Footnote-1243118
Node: Note on powerline or spaceline243228
Node: Note on SHR colors243644
Node: Note on SHR fonts244066
Node: Note on Ement colors and fonts244755
Node: Note on pdf-tools link hints246261
Node: Note on the Notmuch logo248719
Node: Note on goto-address-mode faces249253
Node: Frequently Asked Questions250373
Node: Is the contrast ratio about adjacent colors?251004
Node: What does it mean to avoid exaggerations?252513
Node: Why are colors mostly variants of blue magenta cyan?254363
Node: What is the best setup for legibility?258697
Node: Are these color schemes?261339
Node: Port the Modus themes to other platforms?264993
Node: Contributing267827
Node: Sources of the themes268226
Node: Issues you can help with269122
Node: Patches require copyright assignment to the FSF270514
Node: Acknowledgements272736
Node: GNU Free Documentation License277346
Node: Indices302509
Node: Function index302688
Node: Variable index306883
Node: Concept index311246

End Tag Table

View file

@ -4714,6 +4714,7 @@ have lots of extensions, so the "full support" may not be 100% true…
+ column-enforce-mode
+ company-mode*
+ compilation-mode
+ completion-preview [ Part of {{{development-version}}}. ]
+ completions
+ consult
+ corfu

View file

@ -4859,6 +4859,10 @@ FG and BG are the main colors."
`(compilation-mode-line-fail ((,c :inherit modus-themes-bold :foreground ,modeline-err)))
`(compilation-mode-line-run ((,c :inherit modus-themes-bold :foreground ,modeline-warning)))
`(compilation-warning ((,c :inherit modus-themes-bold :foreground ,warning)))
;;;;; completion-preview
`(completion-preview ((,c :foreground ,fg-dim)))
`(completion-preview-common ((,c :inherit completion-preview :underline t)))
`(completion-preview-exact ((,c :inherit completion-preview :foreground ,accent-0 :underline ,accent-0)))
;;;;; completions
`(completions-annotations ((,c :inherit modus-themes-slant :foreground ,docstring)))
`(completions-common-part ((,c :inherit modus-themes-completion-match-0)))