Closed FOSSilizedDaemon closed 1 year ago
The only major thing I need help with is determining how to actually set the value of the status bar in vis.
You can edit /usr/local/share/vis/vis-std.lua
file or create a plugin and load it from your visrc.
Here's a small example. Note the subscribing to an event:
local function my_stl(win)
local stl = ' '
if win.file.name ~= nil then
stl = stl .. win.file.name
else
stl = stl .. '(no filename)'
end
if win.file.modified then
stl = stl .. ' (modified)'
end
if vis.recording then
stl = stl .. ' (recording)'
end
win:status(stl)
end
vis.events.subscribe(vis.events.WIN_STATUS, my_stl)
This seems like the question was answered, doesn't it?
Hello,
I have been reading over the vis editor lua API documentation in hopes of porting my custom neovim statusline to
vis
. While I think I generally understand what I need to do, I can't help but run into issues figuring out how to actually set things into the status bar. For example, I am trying to write a simple "hello world" status that displays the text "hello world" on the left side of the status bar. To do this I have:I know this is likely wrong, but I can not for the life of me find any examples of basic status bars for
vis
. Do any of you guys have some examples or did I miss something in the documentation?Update
I have done a bit more research and was able to port a good bit of my old neovim statusline to one that works with vis. The only major thing I need help with is determining how to actually set the value of the status bar in
vis
.