-
-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ddu screenshots #10
Comments
Thank you! |
ddu-source-rg with |
ddu-vim-ui-select, which replaces Neovim's |
It is good. Note: I think Well, it uses other ddu ui instead? |
Yes, it does not implement new ui. It's intended to use with ui-ff. |
Oh, OK. |
ddu-live-grep.mp4 |
|
Built a ddu setup with several UIs and sources. ddu-floating-split-view.mp4ddu-ui-filer ddu-filter-converter_hl_dir sample codetype DduUiSize = {
winRow: number;
winCol: number;
winWidth: number;
winHeight: number;
previewFloating: boolean;
previewSplit: "vertical" | "horizontal";
previewRow: number;
previewCol: number;
previewHeight: number;
previewWidth: number;
};
async function uiSize(
args: ConfigArguments,
splitRaitio: number,
previewSplit: "horizontal" | "vertical",
): Promise<DduUiSize> {
const denops = args.denops;
const FRAME_SIZE = 2;
const columns = await opt.columns.get(denops);
const lines = await opt.lines.get(denops);
const winRow = -1;
const winCol = 0;
let winHeight!: number;
let winWidth!: number;
let previewRow!: number;
let previewCol!: number;
let previewHeight!: number;
let previewWidth!: number;
if (previewSplit === "horizontal") {
winHeight = Math.floor(lines / splitRaitio);
winWidth = columns - FRAME_SIZE - 1;
previewRow = lines - FRAME_SIZE;
previewCol = 0;
previewHeight = (lines - winHeight) - (FRAME_SIZE * 3);
previewWidth = winWidth;
} else if (previewSplit === "vertical") {
winHeight = lines - FRAME_SIZE - 1;
winWidth = Math.floor(columns / splitRaitio);
previewRow = 0;
previewCol = columns - FRAME_SIZE;
previewHeight = winHeight;
previewWidth = columns - winWidth - (FRAME_SIZE * 3);
}
return {
winRow: winRow,
winCol: winCol,
winWidth: winWidth,
winHeight: winHeight,
previewFloating: true,
previewSplit: previewSplit,
previewRow: previewRow,
previewCol: previewCol,
previewHeight: previewHeight,
previewWidth: previewWidth,
};
}
// examples
export class Config extends BaseConfig {
override async config(args: ConfigArguments): Promise<void> {
args.contextBuilder.patchGlobal({
uiParams: {
filer: {
...{
split: "floating",
splitDirection: "topleft",
floatingBorder: "single",
sort: "filename",
sortTreesFirst: true,
displayRoot: false,
previewFloatingBorder: "single",
previewWindowOptions: [
["&signcolumn", "no"],
["&foldcolumn", 0],
["&foldenable", 0],
["&number", 0],
["&relativenumber", 0],
["&wrap", 0],
],
},
...await uiSize(args, 5, "vertical"),
},
},
})
args.contextBuilder.patchLocal("ripgrep-ff", {
ui: "ff",
uiParams: {
ff: {
...{
startAutoAction: true,
autoAction: {
delay: 0,
name: "preview",
},
autoResize: false,
startFilter: true,
filterFloatingPosition: "top",
},
...await uiSize(args, 3, "horizontal"),
}
},
sources: [
{
name: "rg",
options: {
matchers: [],
volatile: true,
},
},
],
});
args.contextBuilder.patchLocal("git_status-ff", {
ui: "ff",
uiParams: {
ff: {
...{
startAutoAction: true,
autoAction: {
delay: 0,
name: "preview",
},
autoResize: false,
filterFloatingPosition: "bottom",
},
...await uiSize(args, 2, "vertical"),
},
},
sources: [
{
name: "git_status",
},
],
});
return Promise.resolve();
}
} |
Fuzzy Finder: ff UIFile searching: file_external Source (with
|
I want to add the screenshots link in README.
If you have good screenshots for ddu.vim, can you add it in this issue?
The text was updated successfully, but these errors were encountered: