From 5ba977f8656bec5054e7ab7a46c478a4b70f0d5f Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Thu, 9 Jul 2020 18:56:04 -0400 Subject: Fixed display of API documentation in the command entry. --- modules/textadept/command_entry.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'modules') diff --git a/modules/textadept/command_entry.lua b/modules/textadept/command_entry.lua index eb939137..eda71b94 100644 --- a/modules/textadept/command_entry.lua +++ b/modules/textadept/command_entry.lua @@ -250,12 +250,12 @@ events.connect(events.INITIALIZED, function() for key, f in pairs(keys) do if f == textadept.editing.show_documentation then lua_keys[key] = function() - -- Temporarily change _G.buffer since ui.command_entry is the "active" - -- buffer. - local orig_buffer = _G.buffer - _G.buffer = ui.command_entry + -- Temporarily change _G.buffer and _G.view since ui.command_entry is + -- the "active" buffer and view. + local orig_buffer, orig_view = _G.buffer, _G.view + _G.buffer, _G.view = ui.command_entry, ui.command_entry textadept.editing.show_documentation() - _G.buffer = orig_buffer + _G.buffer, _G.view = orig_buffer, orig_view end break end -- cgit v1.2.3