luukvbaal / statuscol.nvim

Status column plugin that provides a configurable 'statuscolumn' and click handlers.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[QUESTION] Not sure how to configure it to use both relative and normal number.

grappas opened this issue · comments

I want to have both relative and just line number in two columns, but I'm confused: how to distinguish between those two?

                    {
                        text = {
                            " ",
                            builtin.lnumfunc,
                            " "
                        },
                        condition = { true, builtin.not_empty },
                        click = "v:lua.ScLa",
                    },
                    {
                        text = {
                            " ",
                            builtin.lnumfunc,
                            " "
                        },
                        condition = { true, builtin.not_empty },
                        click = "v:lua.ScLa",
                    }

It's not supported in builtin.lnumfunc. Simply using %l and %r could get you what you want if you have both 'number' and 'relativenumber' set:

{text = {" %l %=%r "}, click = "v:lua.ScLa"},