Skip to content

Commit 7b88522

Browse files
committed
fix(ui): fix screen jitter!
Just setting the cursor is enough to scroll the window. There's no need to do anything else. Adding the `zb` just adds jitter occasionally
1 parent 1b4db6b commit 7b88522

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

lua/opencode/ui/ui.lua

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,6 @@ function M.scroll_to_bottom()
1212
local line_count = vim.api.nvim_buf_line_count(state.windows.output_buf)
1313
vim.api.nvim_win_set_cursor(state.windows.output_win, { line_count, 0 })
1414

15-
vim.schedule(function()
16-
vim.api.nvim_win_call(state.windows.output_win, function()
17-
vim.cmd('normal! zb')
18-
end)
19-
end)
20-
2115
-- TODO: shouldn't have hardcoded calls to render_markdown,
2216
-- should support user callbacks
2317
vim.defer_fn(function()

0 commit comments

Comments
 (0)