mirror of
https://github.com/neovim/neovim
synced 2025-07-16 01:01:49 +00:00
fix(messages): add append parameter to history entries (#34467)
Problem: The "append" parameter added in abb40ece
is missing from
history entries, resulting in different message formatting
for "g<".
Solution: Add "append" field to message history entries.
Co-authored-by: phanium <91544758+phanen@users.noreply.github.com>
This commit is contained in:
@ -892,7 +892,7 @@ must handle.
|
||||
|
||||
["msg_history_show", entries] ~
|
||||
Sent when |:messages| command is invoked. History is sent as a list of
|
||||
entries, where each entry is a `[kind, content]` tuple.
|
||||
entries, where each entry is a `[kind, content, append]` tuple.
|
||||
|
||||
["msg_history_clear"] ~
|
||||
Clear the |:messages| history.
|
||||
|
@ -420,7 +420,7 @@ function M.msg_ruler(content)
|
||||
set_virttext('last')
|
||||
end
|
||||
|
||||
---@alias MsgHistory [string, MsgContent]
|
||||
---@alias MsgHistory [string, MsgContent, boolean]
|
||||
--- Open the message history in the pager.
|
||||
---
|
||||
---@param entries MsgHistory[]
|
||||
@ -431,7 +431,7 @@ function M.msg_history_show(entries)
|
||||
|
||||
api.nvim_buf_set_lines(ext.bufs.pager, 0, -1, false, {})
|
||||
for i, entry in ipairs(entries) do
|
||||
M.show_msg('pager', entry[2], i == 1, false)
|
||||
M.show_msg('pager', entry[2], i == 1, entry[3])
|
||||
end
|
||||
|
||||
M.set_pos('pager')
|
||||
|
Reference in New Issue
Block a user