Skip to content

All cmd does not work in Diffview #147

@ls-devs

Description

@ls-devs

Hi,
When working in Diffview I would like to be able to resize / enable auto resizing of the differents windows (diff files) except the Diffview panel.
Actually when I open Diffview, all the cmd (like FocusEnable FocusAutoresize or FocusMaximise) are not working.
How can I proceed so the Diffview panel is not resized but the diff files are ?

Actual config :

{
	"nvim-focus/focus.nvim",
	event = "VeryLazy",
	opts = {
		enable = true,
		commands = true,
		split = {
			bufnew = false,
			tmux = false,
		},
		autoresize = {
			enable = true,
			width = 0,
			height = 0,
			minwidth = 0,
			minheight = 0,
			height_quickfix = 10,
		},
		ui = {
			number = false,
			relativenumber = false,
			hybridnumber = false,
			absolutenumber_unfocussed = false,

			cursorline = false,
			cursorcolumn = false,
			colorcolumn = {
				enable = false,
			},
			signcolumn = false,
			winhighlight = false,
		},
	},
}

Autocmds related :

				{
					"WinEnter",
					function()
						local ignore_buftypes = { "nofile", "prompt", "popup" }
						if vim.tbl_contains(ignore_buftypes, vim.bo.buftype) then
							vim.b.focus_disable = true
						end
					end,
					description = "Disable focus autoresize for BufType",
				},
				{
					"FileType",
					function()
						local ignore_filetypes = {
							["neo-tree"] = true,
							["dap-repl"] = true,
							SidebarNvim = true,
							Trouble = true,
							terminal = true,
							dapui_console = true,
							dapui_watches = true,
							dapui_stacks = true,
							dapui_breakpoints = true,
							dapui_scopes = true,
							OverseerList = true,
							noice = true,
							DiffviewFiles = true,
						}
						vim.b.focus_disable = ignore_filetypes[vim.bo.filetype]
					end,
					description = "Disable focus autoresize for FileType",
				},

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions