Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/ddc_vim/deps.ts>fn.shiftwidth

Dark deno-powered completion framework for neovim/Vim
Go to Latest
function fn.shiftwidth
import { fn } from "https://deno.land/x/ddc_vim@v4.0.2/deps.ts";
const { shiftwidth } = fn;

Returns the effective value of 'shiftwidth'. This is the 'shiftwidth' value unless it is zero, in which case it is the 'tabstop' value. This function was introduced with patch 7.3.694 in 2012, everybody should have it by now (however it did not allow for the optional {col} argument until 8.1.542).

When there is one argument {col} this is used as column number for which to return the 'shiftwidth' value. This matters for the 'vartabstop' feature. If the 'vartabstop' setting is enabled and no {col} argument is given, column 1 will be assumed.

Can also be used as a method:

GetColumn()->shiftwidth()

Parameters

denops: Denops
optional
col: unknown

Returns

Promise<number>