Skip to content

Different highlight groups for titles of search and cmdline #739

Discussion options

You must be logged in to vote

You can specify a view per format.

format = {
  cmdline = { ... , view = "cmdline_normal" },
}

You can create custom views from the examples in noice.config.views, or copy them and modify FloatTitle.

Here is an exmaple for making the cmdline's title highlight Visual:

local cmdline_normal = vim.deepcopy(require('noice.config.views').defaults.cmdline_popup)
cmdline_normal.win_options.winhighlight.FloatTitle = "Visual"
require("noice").setup({
    views = {
        cmdline_normal = cmdline_normal,
    },
    cmdline = {
        -- Default view for other formats
        view = "cmdline_popup",
        format = {
            cmdline = { pattern = "^:", icon = "", lang = "vim", view = "cmdline…

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@JacquesCherbuin
Comment options

@Sam-programs
Comment options

@Sam-programs
Comment options

@JacquesCherbuin
Comment options

Answer selected by JacquesCherbuin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants