I want to trigger a function while newline appears.
But I can't find a way to trigger it while open and closeing folds
Additional context:
To solve the problem that signs are too slow. So only place signs that canbe seen.
export def Render(bufnr: number = bufnr()): void var sy: Signify = bufnr->getbufvar('sy', null_object) if sy == null_object return endif sign_unplace('Signify', {buffer: bufnr}) var signlist = sy.signs if empty(signlist) return endif var winid = bufnr->bufwinid() if winid == -1 return endif var wininfo = winid->getwininfo()[0] var botline: number = wininfo.botline + 1 # botline should +1 for wraped line var priority: number = get(g:, 'signify_priority', 10) var lnum: number = wininfo.topline - 1 while lnum < botline ++lnum var end = foldclosedend(lnum) if end != -1 lnum = end continue endif var name = signlist->get(lnum, null_string) if name != null_string sign_place(0, 'Signify', name, bufnr, {lnum: lnum, priority: priority}) endif endwhile enddef
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
I don't think it cleanly maps to WinScrolled. If this was changed, then many other functions which change buffer display would also and it would explode in complexity, opinions, etc.
Rather add FoldOpen, FoldClose autocmd.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
I don't think it cleanly maps to
WinScrolled. If this was changed, then many other functions which change buffer display would also and it would explode in complexity, opinions, etc.
FoldChanged is well too. I choose WinScrolled just because it is triggered while some line is hidden and some line is shown.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()
FoldChanged -> v:event could tell name of fold, open/closed etc.
I like that.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications, keep track of coding agent tasks and review pull requests on the go with GitHub Mobile for iOS and Android. Download it today!
You are receiving this because you are subscribed to this thread.![]()