Skip to main content
Module

x/ddc_vim/deps.ts>fn.getbufinfo

Dark deno-powered completion framework for neovim/Vim8
Go to Latest
function fn.getbufinfo
import { fn } from "https://deno.land/x/ddc_vim@v0.0.13/deps.ts";
const { getbufinfo } = fn;

Get information about buffers as a List of Dictionaries. Without an argument information about all the buffers is returned. When the argument is a Dictionary only the buffers matching the specified criteria are returned. The following keys can be specified in {dict}: buflisted include only listed buffers. bufloaded include only loaded buffers. bufmodified include only modified buffers. Otherwise, {expr} specifies a particular buffer to return information for. For the use of {expr}, see |bufname()| above. If the buffer is found the returned List has one item. Otherwise the result is an empty list. Each returned List item is a dictionary with the following entries: bufnr buffer number. changed TRUE if the buffer is modified. changedtick number of changes made to the buffer. hidden TRUE if the buffer is hidden. lastused timestamp in seconds, like |localtime()|, when the buffer was last used. {only with the |+viminfo| feature} listed TRUE if the buffer is listed. lnum current line number in buffer. loaded TRUE if the buffer is loaded. name full path to the file in the buffer. signs list of signs placed in the buffer. Each list item is a dictionary with the following fields: id sign identifier lnum line number name sign name variables a reference to the dictionary with buffer-local variables. windows list of |window-ID|s that display this buffer popups list of popup |window-ID|s that display this buffer Examples: for buf in getbufinfo() echo buf.name endfor for buf in getbufinfo({'buflisted':1}) if buf.changed .... endif endfor To get buffer-local options use: getbufvar({bufnr}, '&option_name')

Parameters

denops: Denops
optional
expr: unknown

Returns

Promise<unknown>

Parameters

denops: Denops
optional
dict: unknown

Returns

Promise<unknown>