Skip to content

Commit

Permalink
fix(float): Set filetype for capture window
Browse files Browse the repository at this point in the history
Fixes #832
  • Loading branch information
kristijanhusak committed Dec 6, 2024
1 parent 956897b commit 94894f3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lua/orgmode/utils/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -417,7 +417,7 @@ end
function utils.open_tmp_org_window(height, split_mode, border, on_close)
local prev_winnr = vim.api.nvim_get_current_win()
utils.open_window(vim.fn.tempname() .. '.org', height or 16, split_mode, border)
vim.cmd([[setlocal bufhidden=wipe nobuflisted nolist noswapfile nofoldenable]])
vim.cmd([[setlocal filetype=org bufhidden=wipe nobuflisted nolist noswapfile nofoldenable]])
local bufnr = vim.api.nvim_get_current_buf()

if on_close then
Expand Down Expand Up @@ -476,7 +476,6 @@ function utils.open_float(name, opts)
height = height,
row = row,
col = col,
style = 'minimal',
border = opts.border,
})
end
Expand Down

0 comments on commit 94894f3

Please sign in to comment.